Hi guys,
What i want like below:
---
<script type="text/javascript">
alert({{article.title}});
</script>
---
this code block was writen in some.html using jinja2 template, working by
GAE.
it alert nothing, empty content on dialog.
if I take the code below instead,it work fine:(but need pass extra variable
article.title as "title")
---
<script type="text/javascript">
alert({{title}});
</script>
---
so 1. ,jinja/jinja2 could only pass int, bool, and so on(these regular
type), isn't it?
2. if I want pass the instance "article", do I must dump it by json?
3. Is any other way for code like article.title that passing to javascript?
(some times i think this problem may be less relate with javascript.)
thx,
--
You received this message because you are subscribed to the Google Groups
"pocoo-libs" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/pocoo-libs.
For more options, visit https://groups.google.com/d/optout.