diff options
Diffstat (limited to 'docs/ref/contrib')
| -rw-r--r-- | docs/ref/contrib/admin/index.txt | 8 | ||||
| -rw-r--r-- | docs/ref/contrib/gis/tutorial.txt | 3 | ||||
| -rw-r--r-- | docs/ref/contrib/sites.txt | 24 |
3 files changed, 28 insertions, 7 deletions
diff --git a/docs/ref/contrib/admin/index.txt b/docs/ref/contrib/admin/index.txt index 1b47fa8828..3f32d3bce4 100644 --- a/docs/ref/contrib/admin/index.txt +++ b/docs/ref/contrib/admin/index.txt @@ -14,7 +14,13 @@ Django's admin interface. Overview ======== -There are seven steps in activating the Django admin site: +The admin is enabled in the default project template used by +:djadmin:`startproject`. + +.. versionchanged:: 1.6 + In previous versions, the admin wasn't enabled by default. + +For reference, here are the requirements: 1. Add ``'django.contrib.admin'`` to your :setting:`INSTALLED_APPS` setting. diff --git a/docs/ref/contrib/gis/tutorial.txt b/docs/ref/contrib/gis/tutorial.txt index 9efa020e61..56d90c8593 100644 --- a/docs/ref/contrib/gis/tutorial.txt +++ b/docs/ref/contrib/gis/tutorial.txt @@ -115,13 +115,12 @@ In addition, modify the :setting:`INSTALLED_APPS` setting to include and ``world`` (your newly created application):: INSTALLED_APPS = ( + 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', - 'django.contrib.sites', 'django.contrib.messages', 'django.contrib.staticfiles', - 'django.contrib.admin', 'django.contrib.gis', 'world' ) diff --git a/docs/ref/contrib/sites.txt b/docs/ref/contrib/sites.txt index 7e5448b3d3..7eaab5dacf 100644 --- a/docs/ref/contrib/sites.txt +++ b/docs/ref/contrib/sites.txt @@ -247,13 +247,29 @@ To do this, you can use the sites framework. A simple example:: 'http://example.com/mymodel/objects/3/' -Default site and ``syncdb`` -=========================== +Enabling the sites framework +============================ + +.. versionchanged:: 1.6 + In previous versions, the sites framework was enabled by default. + +To enable the sites framework, follow these steps: + +1. Add ``'django.contrib.sites'`` to your :setting:`INSTALLED_APPS` + setting. + +2. Define a :setting:`SITE_ID` setting:: + + SITE_ID = 1 + +3. Run :djadmin:`syncdb`. ``django.contrib.sites`` registers a :data:`~django.db.models.signals.post_syncdb` signal handler which creates a -default site named ``example.com`` with the domain ``example.com``. For -example, this site will be created after Django creates the test database. +default site named ``example.com`` with the domain ``example.com``. This site +will also be created after Django creates the test database. To set the +correct name and domain for your project, you can use an :doc:`initial data +fixture </howto/initial-data>`. Caching the current ``Site`` object =================================== |
