mirror of
https://github.com/django/django.git
synced 2025-07-04 17:59:13 +00:00
magic-removal: Proofread docs/modpython.txt
git-svn-id: http://code.djangoproject.com/svn/django/branches/magic-removal@2783 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
fd70055334
commit
1a3450ce76
@ -31,11 +31,11 @@ Then edit your ``httpd.conf`` file and add the following::
|
||||
<Location "/mysite/">
|
||||
SetHandler python-program
|
||||
PythonHandler django.core.handlers.modpython
|
||||
SetEnv DJANGO_SETTINGS_MODULE myproject.settings
|
||||
SetEnv DJANGO_SETTINGS_MODULE mysite.settings
|
||||
PythonDebug On
|
||||
</Location>
|
||||
|
||||
...and replace ``myproject.settings`` with the Python path to your settings file.
|
||||
...and replace ``mysite.settings`` with the Python path to your settings file.
|
||||
|
||||
This tells Apache: "Use mod_python for any URL at or under '/mysite/', using the
|
||||
Django mod_python handler." It passes the value of ``DJANGO_SETTINGS_MODULE``
|
||||
@ -71,13 +71,13 @@ instance. Just use ``VirtualHost`` for that, like so::
|
||||
<VirtualHost *>
|
||||
ServerName www.example.com
|
||||
# ...
|
||||
SetEnv DJANGO_SETTINGS_MODULE myproject.settings
|
||||
SetEnv DJANGO_SETTINGS_MODULE mysite.settings
|
||||
</VirtualHost>
|
||||
|
||||
<VirtualHost *>
|
||||
ServerName www2.example.com
|
||||
# ...
|
||||
SetEnv DJANGO_SETTINGS_MODULE myproject.other_settings
|
||||
SetEnv DJANGO_SETTINGS_MODULE mysite.other_settings
|
||||
</VirtualHost>
|
||||
|
||||
If you need to put two Django installations within the same ``VirtualHost``,
|
||||
@ -89,13 +89,13 @@ mess things up. Use the ``PythonInterpreter`` directive to give different
|
||||
ServerName www.example.com
|
||||
# ...
|
||||
<Location "/something">
|
||||
SetEnv DJANGO_SETTINGS_MODULE myproject.settings
|
||||
PythonInterpreter myproject
|
||||
SetEnv DJANGO_SETTINGS_MODULE mysite.settings
|
||||
PythonInterpreter mysite
|
||||
</Location>
|
||||
|
||||
<Location "/otherthing">
|
||||
SetEnv DJANGO_SETTINGS_MODULE myproject.other_settings
|
||||
PythonInterpreter myproject_other
|
||||
SetEnv DJANGO_SETTINGS_MODULE mysite.other_settings
|
||||
PythonInterpreter mysite_other
|
||||
</Location>
|
||||
</VirtualHost>
|
||||
|
||||
@ -153,7 +153,7 @@ the ``media`` subdirectory and any URL that ends with ``.jpg``, ``.gif`` or
|
||||
<Location "/">
|
||||
SetHandler python-program
|
||||
PythonHandler django.core.handlers.modpython
|
||||
SetEnv DJANGO_SETTINGS_MODULE myproject.settings
|
||||
SetEnv DJANGO_SETTINGS_MODULE mysite.settings
|
||||
</Location>
|
||||
|
||||
<Location "media">
|
||||
|
Loading…
x
Reference in New Issue
Block a user