[web2py] Re: generating svg from controllers

2012-12-26 Thread jonas
Nice. now it works On Wednesday, December 26, 2012 7:11:53 PM UTC, Anthony wrote: > > def index(): > a="" > return a > > If you return a string, web2py does not call a view but returns only that > string. To call a view, you have to return a dict: > > def index(): > return dict(a="")

[web2py] Re: generating svg from controllers

2012-12-26 Thread Derek
Have you tried: a = XML("") ? On Wednesday, December 26, 2012 11:52:54 AM UTC-7, jonas wrote: > > Hi. Is there any way to generate xml svg via controllers? svg can be made > by using declarative syntax, i.e xml instead of javascript. is it possible > to return an string containing svg xml and

[web2py] Re: generating svg from controllers

2012-12-26 Thread Paolo
Hi, this should work: return XML(a) paolo On Wednesday, December 26, 2012 7:52:54 PM UTC+1, jonas wrote: > > Hi. Is there any way to generate xml svg via controllers? svg can be made > by using declarative syntax, i.e xml instead of javascript. is it possible > to return an string containing s

[web2py] Re: generating svg from controllers

2012-12-26 Thread Anthony
def index(): a="" return a If you return a string, web2py does not call a view but returns only that string. To call a view, you have to return a dict: def index(): return dict(a="") Then in the view, to prevent the XML string from being escaped, you have to wrap it in the XML() he