2. Installation

2.1. Dependencies

Make sure to install these packages prior to installation :

The packages below are optionnal but needed for run the full test suite.

Note that all the dependencies will be resolved if you install Zinnia with pip or easy_install, excepting Django.

2.2. Getting the code

You could retrieve the last sources from http://github.com/Fantomas42/django-blog-zinnia and run the installation script

$ python setup.py install

or use pip

$ pip install -e git://github.com/Fantomas42/django-blog-zinnia.git#egg=django-blog-zinnia

For the latest stable version use easy_install

$ easy_install django-blog-zinnia

2.3. Applications

Then register zinnia, and these following applications in the INSTALLED_APPS section of your project’s settings.

  # Your favorite apps

2.4. Template Context Processors

Add these following template context processors if not already present.

  'zinnia.context_processors.version', # Optional

2.5. Media Files

You have to make a symbolic link from zinnia/media/zinnia directory to your media directory or make a copy named zinnia, but if want to change this value, define ZINNIA_MEDIA_URL in the settings.py as appropriate.

And don’t forget to serve this URL.

2.6. URLs

Add the following lines to your project’s urls.py in order to display the blog.

url(r'^weblog/', include('zinnia.urls')),
url(r'^comments/', include('django.contrib.comments.urls')),

Note that the default zinnia URLset is provided for convenient usage, but you can customize your URLs if you want. Here’s how :

url(r'^', include('zinnia.urls.capabilities')),
url(r'^search/', include('zinnia.urls.search')),
url(r'^sitemap/', include('zinnia.urls.sitemap')),
url(r'^trackback/', include('zinnia.urls.trackback')),
url(r'^weblog/tags/', include('zinnia.urls.tags')),
url(r'^weblog/feeds/', include('zinnia.urls.feeds')),
url(r'^weblog/authors/', include('zinnia.urls.authors')),
url(r'^weblog/categories/', include('zinnia.urls.categories')),
url(r'^weblog/discussions/', include('zinnia.urls.discussions')),
url(r'^weblog/', include('zinnia.urls.quick_entry')),
url(r'^weblog/', include('zinnia.urls.entries')),
url(r'^comments/', include('django.contrib.comments.urls')),

Table Of Contents

Previous topic

1. Django Blog Zinnia

Next topic

3. Advanced Configuration

This Page