On Thu, Apr 22, 2010 at 11:49 AM, Ferran Fontcuberta <[email protected]> wrote: > Something like this. I want to use $input.name in the template without using > an if construction if there are not defined in input.
Don't pass input into template. Not very safe. Create a custom web.storage object and assign it whatever attribs you need. mydata = web.storage() mydata.name = i.name mydata.surname = i.surname Then in template: $(mydata.name or "You haven't specified a name.") -- Branko Vukelić [email protected] [email protected] Check out my blog: http://www.brankovukelic.com/ Check out my portfolio: http://www.flickr.com/photos/foxbunny/ Registered Linux user #438078 (http://counter.li.org/) I hang out on identi.ca: http://identi.ca/foxbunny -- You received this message because you are subscribed to the Google Groups "web.py" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/webpy?hl=en.
