mirror of
https://github.com/django/django.git
synced 2025-10-23 21:59:11 +00:00
Refs #34140 -- Corrected rst code-block and various formatting issues in docs.
This commit is contained in:
committed by
Mariusz Felisiak
parent
c67ea79aa9
commit
ba755ca131
@@ -127,13 +127,15 @@ You can use the :func:`redirect` function in a number of ways.
|
||||
...
|
||||
return redirect('some-view-name', foo='bar')
|
||||
|
||||
#. By passing a hardcoded URL to redirect to::
|
||||
#. By passing a hardcoded URL to redirect to:
|
||||
::
|
||||
|
||||
def my_view(request):
|
||||
...
|
||||
return redirect('/some/url/')
|
||||
|
||||
This also works with full URLs::
|
||||
This also works with full URLs:
|
||||
::
|
||||
|
||||
def my_view(request):
|
||||
...
|
||||
|
||||
@@ -865,7 +865,9 @@ Secondly, you can include an object that contains embedded namespace data. If
|
||||
you ``include()`` a list of :func:`~django.urls.path` or
|
||||
:func:`~django.urls.re_path` instances, the URLs contained in that object
|
||||
will be added to the global namespace. However, you can also ``include()`` a
|
||||
2-tuple containing::
|
||||
2-tuple containing:
|
||||
|
||||
.. code-block:: text
|
||||
|
||||
(<list of path()/re_path() instances>, <application namespace>)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user