[EMAIL PROTECTED] wrote: > ${XML(foo())} works. I'd like to add 'XML(..)' to string returned by foo() > so that I don't need to invoke XML() in Kid all the time. > > When I tried that Kid just interpreted 'XML( ..)' as part of the string and > didn't invoke the XML function. > > Any ideas on that?
Yes, since ${foo()} means execute foo() and insert the result (as a string, not executed one more time). If you want XML to be executed on the return value, you need to define foo() something like that: def foo(): from kid import XML return XML("<a href='http://mysite'>some text</a>") -- Christoph ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ kid-template-discuss mailing list kid-template-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/kid-template-discuss