Ticket #7714: 7714.url_tag_doc.diff
File 7714.url_tag_doc.diff, 829 bytes (added by , 16 years ago) |
---|
-
django/docs/templates.txt
1168 1168 takes a client ID (here, ``client()`` is a method inside the views file 1169 1169 ``app_views.py``). The URLconf line might look like this:: 1170 1170 1171 ('^client/(\d+)/$', ' app_views.client')1171 ('^client/(\d+)/$', 'project_name.app_name.app_views.client') 1172 1172 1173 1173 If this app's URLconf is included into the project's URLconf under a path 1174 1174 such as this:: … … 1177 1177 1178 1178 ...then, in a template, you can create a link to this view like this:: 1179 1179 1180 {% url app_views.client client.id %}1180 {% url project_name.app_name.app_views.client client.id %} 1181 1181 1182 1182 The template tag will output the string ``/clients/client/123/``. 1183 1183