Added a security section to the foreword and a footnote to the g

variable
This commit is contained in:
Armin Ronacher 2010-04-11 03:41:01 +02:00
parent 4e7aa9e7f7
commit 4671429a50
4 changed files with 48 additions and 3 deletions

View file

@ -313,8 +313,8 @@ Here an example template:
{% endif %}
Inside templates you also have access to the :class:`~flask.request`,
:class:`~flask.session` and :class:`~flask.g` objects as well as the
:func:`~flask.get_flashed_messages` function.
:class:`~flask.session` and :class:`~flask.g` [#]_ objects
as well as the :func:`~flask.get_flashed_messages` function.
Templates are especially useful if inheritance is used. If you want to
know how that works, head over to the :ref:`template-inheritance` pattern
@ -338,6 +338,11 @@ Markup(u'<blink>hacker</blink>')
>>> Markup('<em>Marked up</em> &raquo; HTML').striptags()
u'Marked up \xbb HTML'
.. [#] Unsure what that :class:`~flask.g` object is? It's something you
can store information on yourself, check the documentation of that
object (:class:`~flask.g`) and the :ref:`database-pattern` for more
information.
Accessing Request Data
----------------------