#915: layout_params cannot use python variables
------------------------------+---------------------------------------------
Reporter: [EMAIL PROTECTED] | Owner: anonymous
Type: defect | Status: new
Priority: normal | Milestone:
Component: Kid | Version: 0.9a6
Severity: normal | Keywords:
------------------------------+---------------------------------------------
Having had a quick dig through the code, I think this is a TG problem, not
a Kid problem.
What I want is to use passed-in python variables in layout_params, e.g.:
{{{
<!DOCTYPE ..>
<?python
layout_params['foo'] = bar # bar passed in by controller
?>
<html>
}}}
However it barfs if I do this. It looks like the problem is in the
template importing - anything in a <?python ... ?> block '''before'''
<html> is evaluated on import, and because the variables are not available
there, it blows up. Using these variables '''after''' the html tag is
fine.
--
Ticket URL: <http://trac.turbogears.org/turbogears/ticket/915>
TurboGears <http://www.turbogears.org/>
TurboGears front-to-back web development
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears Tickets" 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/turbogears-tickets
-~----------~----~----~----~------~----~------~--~---