[web2py] Re: request.vars convenience

2010-04-16 Thread selecta
thanks alot, even though I consider myself quite familiar with python I regularly discover things that I missed guess this is due to my learning by doing and not reading manuals properly :) On Apr 15, 5:08 pm, Jonathan Lundell wrote: > On Apr 15, 2010, at 3:05 AM, Mladen Milankovic wrote: > > > q

[web2py] Re: request.vars convenience

2010-04-15 Thread mdipierro
You can do: q = request.vars.q or None On Apr 15, 5:05 am, Mladen Milankovic wrote: > On Thursday, April 15, 2010 11:23:15 selecta wrote: > > for request.args I can do > > > request.args(0) > > > and will return None if there is no such element, much nicer than > > > request.args[0] if len(reque