[web2py] Re: adding to head under view

2013-08-02 Thread Niphlod
in recent welcome layout there's a block head just for it. https://github.com/web2py/web2py/blob/master/applications/welcome/views/layout.html#L65 On Friday, August 2, 2013 3:46:27 PM UTC+2, Anthony wrote: > > One option is to use a block: > http://web2py.com/books/default/chapter/29/05/the-views

[web2py] Re: adding to head under view

2013-08-02 Thread Anthony
One option is to use a block: http://web2py.com/books/default/chapter/29/05/the-views#Blocks-in-views Another is something like: {{=globals().get('head_script', '')}} Then have the controller return a 'head_script' variable, or define the variable in the view *before* the {{extend 'layout.html