Plugins
File
Allows you to upload a file. A filetype icon will be assigned based on the file extension.
For installation be sure you have the following in the INSTALLED_APPS setting in your project’s settings.py file:
INSTALLED_APPS = (
# ...
'cms.plugins.file',
# ...
)
Flash
Allows you to upload and display a Flash SWF file on your page.
For installation be sure you have the following in the INSTALLED_APPS setting in your project’s settings.py file:
INSTALLED_APPS = (
# ...
'cms.plugins.flash',
# ...
)
GoogleMap
Displays a map of an address on your page.
For installation be sure you have the following in the INSTALLED_APPS setting in your project’s settings.py file:
INSTALLED_APPS = (
# ...
'cms.plugins.googlemap',
# ...
)
The Google Maps API key is also required. You can either put this in a project setting called GOOGLE_MAPS_API_KEY or be sure the template context has a variable with the same name.
Link
Displays a link to an arbitrary URL or to a page. If a page is moved the URL will still be correct.
For installation be sure to have the following in the INSTALLED_APPS setting in your project’s settings.py file:
INSTALLED_APPS = (
# ...
'cms.plugins.link',
# ...
)
Picture
Displays a picture in a page.
For installation be sure you have the following in the INSTALLED_APPS setting in your project’s settings.py file:
INSTALLED_APPS = (
# ...
'cms.plugins.picture',
# ...
)
If you want to resize the picture you can get a thumbnail library. We recommend sorl.thumbnail. In your project template directory create a folder called cms/plugins and create a file called picture.html in there. Here is an example picture.html template:
{% load i18n thumbnail %}
{% spaceless %}
{% if picture.url %}<a href="{{ picture.url }}">{% endif %}
{% ifequal placeholder "content" %}
<img src="{% thumbnail picture.image.name 484x1500 upscale %}" {% if picture.alt %}alt="{{ picture.alt }}" {% endif %}/>
{% endifequal %}
{% ifequal placeholder "teaser" %}
<img src="{% thumbnail picture.image.name 484x1500 upscale %}" {% if picture.alt %}alt="{{ picture.alt }}" {% endif %}/>
{% endifequal %}
{% if picture.url %}</a>{% endif %}
{% endspaceless %}
In this template the picture is scaled differently based on which placeholder it was placed in.
Snippet
Just renders some HTML snippet. Mostly used for development or hackery.
For installation be sure you have the following in the INSTALLED_APPS setting in your project’s settings.py file:
INSTALLED_APPS = (
# ...
'cms.plugins.snippet',
# ...
)
Text
Displays text. If plugins are text-enabled they can be placed inside the text-flow. At this moment the following plugins are text-enabled:
- link
- picture
- file
- snippet
The current editor is Wymeditor. If you want to use TinyMce you need to install django-tinymce. If tinymce is in your INSTALLED_APPS it will be automatically enabled. If you have tinymce installed but don’t want to use it in the cms put the following in your settings.py:
CMS_USE_TINYMCE = False
For installation be sure you have the following in your project’s INSTALLED_APPS setting:
INSTALLED_APPS = (
# ...
'cms.plugins.text',
# ...
)
Questions/Feedback
If you notice errors with this documentation, please open a ticket and let us know!
Please only use the ticket tracker for criticisms and improvements on the docs. For tech support, ask in the IRC channel or post to the django-cms mailing-list.
Index
- Installation
- Configuration
- Plugins
- Custom Plugins
- Navigation
- Internationalization
- Sitemap
- Contribution


