Ok I see the problem now. I actually have
db.table.email.requires=IS_EMAIL(),
I remove the commas that it works!
Thank you!
Pai
On Jan 31, 11:37 am, Massimo Di Pierro <
mdipie...@cs.depaul.edu>
wrote:
> I think in your model you have
>
> db.table.field.requires=(.....)
>
> instead of
>
> db.table.field.requires=[.....]
>
> let me know if that is the case.
>
> On Jan 31, 2008, at 11:32 AM, Pai wrote:
>
>
>
> > new error...
>
> > Traceback (most recent call last):
> > File "gluon\restricted.pyc", line 60, in restricted
> > File "applications/blog2/controllers/default.py", line 63, in
> > <module>
> > File "applications/blog2/controllers/default.py", line 52, in
> > addEditComment
> > File "gluon\sqlhtml.pyc", line 61, in __init__
> > File "gluon\sql.pyc", line 618, in formatter
> > AttributeError: 'tuple' object has no attribute 'reverse'
>
> > 51 db.comment.email.default='
test...@yahoo.com'
> > 52 form=SQLFORM(db.comment,fields=['name','email','text'])
>
> > I tried with and without having the default value declear in the
> > db.py. Still not luck.
>
> > If comment out the line 51, everything works fine.
>
> > Pai
>
> > On Jan 31, 11:19 am, Massimo Di Pierro <
mdipie...@cs.depaul.edu>
> > wrote:
> >> My mistake. I apologize.
>
> >>> 53 db.comment.email.default='
t...@email.com'
> >>> 54 form=SQLFORM(db.comment,fields=['name','email','text'])
>
> >> Massimo
>
> >> On Jan 31, 2008, at 11:15 AM, Pai wrote:
>
> >>> I get this error when I tried to do that..
>
> >>> Traceback (most recent call last):
> >>> File "gluon\restricted.pyc", line 60, in restricted
> >>> File "applications/blog2/controllers/default.py", line 66, in
> >>> <module>
> >>> File "applications/blog2/controllers/default.py", line 54, in
> >>> addEditComment
> >>> File "gluon\sqlhtml.pyc", line 60, in __init__
> >>> AttributeError: 'str' object has no attribute 'default'
>
> >>> 53 db.comment.email='
t...@email.com'