summaryrefslogtreecommitdiff
path: root/docs/narr/urldispatch.rst
diff options
context:
space:
mode:
authorChris McDonough <chrism@agendaless.com>2009-12-27 22:47:08 +0000
committerChris McDonough <chrism@agendaless.com>2009-12-27 22:47:08 +0000
commit8c56ae41b6f0221d72f1a255ce1a3ac467b98d79 (patch)
treed310d7be53ae0f4760e09b437975dcebce52d02b /docs/narr/urldispatch.rst
parentd7b12a30237d51d761cab0b08c5da1163ea534ee (diff)
downloadpyramid-8c56ae41b6f0221d72f1a255ce1a3ac467b98d79.tar.gz
pyramid-8c56ae41b6f0221d72f1a255ce1a3ac467b98d79.tar.bz2
pyramid-8c56ae41b6f0221d72f1a255ce1a3ac467b98d79.zip
- Added manual index entries to generated index.
Diffstat (limited to 'docs/narr/urldispatch.rst')
-rw-r--r--docs/narr/urldispatch.rst30
1 files changed, 30 insertions, 0 deletions
diff --git a/docs/narr/urldispatch.rst b/docs/narr/urldispatch.rst
index 2d74bfbca..728795e7f 100644
--- a/docs/narr/urldispatch.rst
+++ b/docs/narr/urldispatch.rst
@@ -1,3 +1,6 @@
+.. index::
+ single: url dispatch
+
.. _urldispatch_chapter:
URL Dispatch
@@ -53,6 +56,9 @@ error to the user's browser when no routes match.
.. note:: See :ref:`modelspy_project_section` for an example of a
simple root factory callable that will use traversal.
+.. index::
+ single: add_route
+
The ``add_route`` Configurator Method
-------------------------------------
@@ -65,6 +71,9 @@ registry`. Here's an example:
config.add_route('myroute', '/prefix/:one/:two')
+.. index::
+ single: ZCML directive; route
+
Configuring a Route via ZCML
----------------------------
@@ -85,6 +94,9 @@ documentation.
.. note:: The documentation that follows in this chapter assumes that
:term:`ZCML` will be used to perform route configuration.
+.. index::
+ pair: URL dispatch; matchdict
+
The Matchdict
-------------
@@ -95,6 +107,9 @@ matched, a dictionary is placed on the request named ``matchdict``
with the values that match patterns in the ``path`` element. If the
URL pattern does not match, no matchdict is generated.
+.. index::
+ pair: URL dispatch; path pattern syntax
+
.. _route_path_pattern_syntax:
Path Pattern Syntax
@@ -204,6 +219,9 @@ Will generate the following matchdict:
{'traverse':(u'La Pe\xf1a', u'a', u'b', u'c')}
+.. index::
+ triple: ZCML directive; route; examples
+
``<route>`` Statement Examples
------------------------------
@@ -419,6 +437,9 @@ In this case in particular, when a user visits
Article class and it will have an ``article`` attribute with the value
of ``something``.
+.. index::
+ pair: URL dispatch; catching root URL
+
Catching the Root URL
---------------------
@@ -446,6 +467,9 @@ Or provide the literal string ``/`` as the path:
view=".views.root_view"
/>
+.. index::
+ pair: URL dispatch; generating route URLs
+
Generating Route URLs
---------------------
@@ -467,6 +491,9 @@ hostname implied ``http:/example.com``). See the
:func:`repoze.bfg.url.route_url` API documentation for more
information.
+.. index::
+ pair: URL dispatch; slash-redirecting
+
Redirecting to Slash-Appended Routes
------------------------------------
@@ -574,6 +601,9 @@ Then in the ``configure.zcml`` of your package, inject the following:
This will cause the DBSession to be removed whenever the WSGI
environment is destroyed (usually at the end of every request).
+.. index::
+ pair: URL dispatch; security
+
.. _using_security_with_urldispatch:
Using :mod:`repoze.bfg` Security With URL Dispatch