Files
@ a40824531f68
Branch filter:
Location: kallithea/docs/index.rst - annotation
a40824531f68
1.0 KiB
text/prs.fallenstein.rst
controllers: don't pass rendered templates in context variables
Some controllers used the followifng pattern:
- render a data template into a context variable
- for partial (ajax) requests, return the contents of this variable
- for full-page requests, render the full page, which expands the value of
the context variable
Instead, avoid context variables let the controller simply render the full or partial page, and let
the full page template include the partial page.
Remove this context variable for templating and use render exclusively.
From templates, use %include instead of context variables.
This in line with the suggestions in the Pylons documentation:
http://pylons-webframework.readthedocs.org/en/latest/helpers.html#partial-updates-with-ajax
Some controllers used the followifng pattern:
- render a data template into a context variable
- for partial (ajax) requests, return the contents of this variable
- for full-page requests, render the full page, which expands the value of
the context variable
Instead, avoid context variables let the controller simply render the full or partial page, and let
the full page template include the partial page.
Remove this context variable for templating and use render exclusively.
From templates, use %include instead of context variables.
This in line with the suggestions in the Pylons documentation:
http://pylons-webframework.readthedocs.org/en/latest/helpers.html#partial-updates-with-ajax
5f481e4e888b 5f481e4e888b 47d5781bfe8a bdd1ddd05b7c 9da24750f563 9da24750f563 5f481e4e888b 5f481e4e888b 5f481e4e888b 5f481e4e888b 5f481e4e888b 5f481e4e888b 5f481e4e888b d95ea48af67b 64b1a2320bcb d95ea48af67b e69d34136be5 3389f272ece1 8b8edfc25856 bb35ad076e2f bb35ad076e2f bb35ad076e2f bb35ad076e2f bb35ad076e2f bbd499c7b55e c45fb78969a3 fa88997aa421 aa17c7a1b8a5 bbd499c7b55e af371e206ec5 e54ec8211944 4d076981a7b1 aa90719e8520 4d076981a7b1 bb35ad076e2f bb35ad076e2f bb35ad076e2f bb35ad076e2f 8b8edfc25856 bb35ad076e2f 42a87338035a 5f481e4e888b bb35ad076e2f bb35ad076e2f bb35ad076e2f 9da24750f563 bb35ad076e2f b43a121f3137 b43a121f3137 8b8edfc25856 bb35ad076e2f 5f481e4e888b a60cd29ba7e2 5f481e4e888b 5f481e4e888b 5f481e4e888b 5f481e4e888b a60cd29ba7e2 5f481e4e888b 5f481e4e888b 5f481e4e888b 9472a0150bf0 5f481e4e888b a60cd29ba7e2 a60cd29ba7e2 a60cd29ba7e2 8b8edfc25856 | .. _index:
.. include:: ./../README.rst
Users Guide
-----------
**Installation:**
.. toctree::
:maxdepth: 1
installation
upgrade
installation_win
installation_win_old
installation_iis
setup
**Usage**
.. toctree::
:maxdepth: 1
usage/general
usage/git_support
usage/performance
usage/locking
usage/statistics
usage/backup
usage/subrepos
usage/debugging
usage/troubleshooting
**Develop**
.. toctree::
:maxdepth: 1
contributing
changelog
**API**
.. toctree::
:maxdepth: 1
api/api
api/models
Other topics
------------
* :ref:`genindex`
* :ref:`search`
.. _virtualenv: http://pypi.python.org/pypi/virtualenv
.. _python: http://www.python.org/
.. _django: http://www.djangoproject.com/
.. _mercurial: http://mercurial.selenic.com/
.. _bitbucket: http://bitbucket.org/
.. _subversion: http://subversion.tigris.org/
.. _git: http://git-scm.com/
.. _celery: http://celeryproject.org/
.. _Sphinx: http://sphinx.pocoo.org/
.. _vcs: http://pypi.python.org/pypi/vcs
|