Are you saying the content of field.name is actually Python code that you 
want to execute right there within the template? In that case, maybe you 
could use Python eval or exec inside the {{...}}.

Anthony

On Thursday, June 21, 2012 2:27:48 PM UTC-4, RKS wrote:
>
> I have a table defined with some old fashioned fields. When printing the 
> fields in a view I use {{=XML(field.name)}} and so far this works great 
> for all the HTML I've been putting in there all this time. 
>
> Now I've come to a situation where I'm trying to print some python from a 
> field. Might be recursive, but if I have {{=field.name}} it prints that 
> out directly instead of recognizing that it's a call and should go look for 
> the field referenced. The reason I'm doing it this way is that my view is 
> defined for all items of that type. One item has some differences and it 
> should include another HTML file such as {{include "html.html"}} but that 
> just prints instead of trying to find that html and include it.
>
> Hopefully this wasn't so confusing.
>
> So instead of {{=XML(field.name)}} when printing this particular field, 
> what should this be in order to parse the python and html inside? Thanks.
>

-- 



Reply via email to