I'm trying to use session directly in templates, using instructions from cookbook [1] but I can't get it working.
Any help?
Here is the error message:
E:\tomas\projetos\synergie>c:\Python27\python.exe serve.py
Traceback (most recent call last):
File "serve.py", line 5, in <module>
import config
File "E:\tomas\projetos\synergie\config\__init__.py", line 1, in <module>
from config import *
File "E:\tomas\projetos\synergie\config\config.py", line 18, in <module>
view = web.template.render('app/views', base='base', cache=cache, globals={'context': session})
NameError: name 'session' is not defined
1 -
http://webpy.org/cookbook/session_in_template