I've got a simple template:
$def with (content)
<head>
<LINK REL=StyleSheet HREF="static/style.css" TYPE="text/css"
MEDIA=screen>
<title> $content['title'] </title>
</head>
<body>
$:content['body']
</body>
</html>
where content is a dictionary passed from python, but when I try to
load the page I get this error:
<type 'exceptions.KeyError'> at /
'title'
Python templates/layout.html in __template__, line 4
Web GET http://localhost:8080/
If I just use "$content" without an index, I see the dictionary
represented as a string. The tutorial indicates that dictionaries can
be passed: what am I missing?
Thanks in advance
--
You received this message because you are subscribed to the Google Groups
"web.py" 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/webpy?hl=en.