[web2py] Re: Limiting the number of values that could be input in a form field

2021-12-08 Thread mostwanted
Thanks Clemens this worked:
* Field('id_number', requires = IS_MATCH('^\d{9}?$', 
error_message='An ID Number should have exactly 9 digits')), *

On Wednesday, December 8, 2021 at 9:41:45 PM UTC+2 Clemens wrote:

> The right link to the chapter in the web2py documentation is:
> http://web2py.com/books/default/chapter/29/07/forms-and-validators#IS_MATCH
>
> On Wednesday, December 8, 2021 at 8:35:17 PM UTC+1 Clemens wrote:
>
>> I didn't test it, but this should do the job:
>> requires = IS_MATCH('^\w{1,9}$', error_message='must be 1 to 9 
>> characters/digits')
>>
>> For further information about validators with regular expressions have a 
>> look here:
>> http://web2py.com/book/default/chapter/07?search=formstyle#IS_MATCH
>>
>> On Wednesday, December 8, 2021 at 8:23:01 PM UTC+1 mostwanted wrote:
>>
>>> Is there a validator that could be used to limit the number of values 
>>> that could be submitted in a form field? I want users to input their ID 
>>> numbers but they cant be more than 9 characters, how do i achieve this?
>>>
>>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/8da7b091-3719-4152-af0e-61813220bd3cn%40googlegroups.com.


[web2py] IS_NOT_IN_DB( ) exception error

2021-12-08 Thread mostwanted
I'm trying to use the validator IS_NOT_IN_DB( ) but i keep getting the 
error below, what does it mean?

* Validation error, field:policy_N 
* 

MY CODE:
db.define_table('client',
Field('client_name'),
Field('id_number', requires = IS_MATCH('^\d{9}?$', 
error_message='An ID Number should have exactly 9 digits')), 

Field('policy_N'),
Field('date_of_birth', 'date'),
Field('member_only', 'reference 
premium_for_member_only_family_policy'),
format="%(client_name)s"
   )
db.client.policy_N.requires=IS_NOT_IN_DB(db,'db.client'*)*

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/d4ea5ecd-851f-4a4e-9d7c-f874f1e14a84n%40googlegroups.com.


[web2py] Learning Management System (LMS)

2021-12-08 Thread 黄祥
is there any web2py app or example to create Learning Management System 
(LMS) with the exam ?

thanks and best regards,
stifan

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/2fe8ca75-df3a-47fe-ba50-b556d15e3364n%40googlegroups.com.


[web2py] Re: video app

2021-12-08 Thread Dave S
On Tuesday, December 7, 2021 at 10:47:55 PM UTC-8 mauri...@gmail.com wrote:

> Hello.
> Anyone who has a zoom/airmeet app like application / any leads on a such 
> an app  using web2py/p4web?
> Regards
>

There are 2 parts to this, I think.  One involves receiving a stream from a 
server, which seems fairly straightforward.  The other part would be 
receiving notifications. See this answer from 2016:
https://groups.google.com/g/web2py/c/_87LHOJFMR0/m/7ONiuUwABwAJ >

I suspect that this is even easier in py4web, though I'm way behind on 
studying that.

Dave S
/dps

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/940093ba-eacd-4a0a-97af-93947c550697n%40googlegroups.com.


[web2py] Re: Limiting the number of values that could be input in a form field

2021-12-08 Thread Clemens
The right link to the chapter in the web2py documentation is:
http://web2py.com/books/default/chapter/29/07/forms-and-validators#IS_MATCH

On Wednesday, December 8, 2021 at 8:35:17 PM UTC+1 Clemens wrote:

> I didn't test it, but this should do the job:
> requires = IS_MATCH('^\w{1,9}$', error_message='must be 1 to 9 
> characters/digits')
>
> For further information about validators with regular expressions have a 
> look here:
> http://web2py.com/book/default/chapter/07?search=formstyle#IS_MATCH
>
> On Wednesday, December 8, 2021 at 8:23:01 PM UTC+1 mostwanted wrote:
>
>> Is there a validator that could be used to limit the number of values 
>> that could be submitted in a form field? I want users to input their ID 
>> numbers but they cant be more than 9 characters, how do i achieve this?
>>
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/d8e04495-a4b6-4441-811f-e6afc4b419d5n%40googlegroups.com.


[web2py] Re: Limiting the number of values that could be input in a form field

2021-12-08 Thread Clemens
I didn't test it, but this should do the job:
requires = IS_MATCH('^\w{1,9}$', error_message='must be 1 to 9 
characters/digits')

For further information about validators with regular expressions have a 
look here:
http://web2py.com/book/default/chapter/07?search=formstyle#IS_MATCH

On Wednesday, December 8, 2021 at 8:23:01 PM UTC+1 mostwanted wrote:

> Is there a validator that could be used to limit the number of values that 
> could be submitted in a form field? I want users to input their ID numbers 
> but they cant be more than 9 characters, how do i achieve this?
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/686fd13a-9fe7-4a7f-bb95-c296d51738acn%40googlegroups.com.


[web2py] Limiting the number of values that could be input in a form field

2021-12-08 Thread mostwanted
Is there a validator that could be used to limit the number of values that 
could be submitted in a form field? I want users to input their ID numbers 
but they cant be more than 9 characters, how do i achieve this?

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/deaaf00b-90a7-4a63-95d6-1f0aa1015e0cn%40googlegroups.com.