'mykey' will be available "magically" as a top-level name in the template. Just use it.
On Apr 16, 2011, at 2:19 PM, AwaisMuzaffar <[email protected]> wrote: > Hi Guys, > > When I use the before render event like so: > > from pyramid.events import subscriber > from pyramid.events import BeforeRender > > @subscriber(BeforeRender) > def add_global(event): > event['mykey'] = 'foo' > > How exactly do I call these variables my templates. I can't seem to > find this out from the documentation. > > -- > You received this message because you are subscribed to the Google Groups > "pylons-discuss" 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/pylons-discuss?hl=en. > -- You received this message because you are subscribed to the Google Groups "pylons-discuss" 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/pylons-discuss?hl=en.
