Thank you. I've noticed a lot of differences from the examples and the
current version of web2py. It is very confusing to someone without any
background on web frameworks.

I know it's said somewhere that w2p is always backward compatible, is
there a page I could look at for changes since web2py_manual_cut.pdf
was released?


On May 22, 1:26 pm, mdipierro <mdipie...@cs.depaul.edu> wrote:
> must be a typo in the cookbook, should be
>
>     return dict(message=T('Hello Stranger'), counter=session.counter)
>
> On May 21, 11:54 pm, NikG <nikolai...@gmail.com> wrote:
>
> > Hello everyone. I'm learning web2py on my own by following the
> > cookbook and the "cut" book examples.
>
> > Using web2py version 1.62.3 and following the session counter example,
> > I get an error but I have no idea what's wrong:
>
> > Traceback (most recent call last):
> >   File "/home/vin/web2py/gluon/restricted.py", line 107, in restricted
> >     exec ccode in environment
> >   File "/home/vin/web2py/applications/myapp/compiled/
> > controllers_default_index.py", line 62, in <module>
> >   File "/home/vin/web2py/gluon/globals.py", line 80, in <lambda>
> >     self._caller = lambda f: f()
> >   File "/home/vin/web2py/applications/myapp/compiled/
> > controllers_default_index.py", line 19, in index
> > TypeError: __call__() got an unexpected keyword argument 'counter'
>
> > my default.py:
> > def index():
> >     """
> >     example action using the internationalizaiton operator T and flash
> >     rendered by views/default/index.html or views/generic.html
> >     """
> >     session.counter=session.counter+1 if session.counter else 1
>
> >     response.flash = T('Welcome to web2py')
> >     return dict(message=T('Hello Stranger', counter=session.counter))
>
> > .... <snip>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py Web Framework" group.
To post to this group, send email to web2py@googlegroups.com
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to