Django CMS Plugins

The module media_tree.contrib.cms_plugins contains a number of plugins for using FileNode objects on pages created with Django CMS.

Installation

For optimum admin functionality when using these plugins, you should put media_tree.contrib.cms_plugins in your installed apps, and run manage.py collectstatic.

If you are not using the staticfiles app, you have to manually copy the contents of the static folder to your static root.

Note

Of course you can also create your own models and plugins using FileNode objects. Please take a look at Fields and forms and How to create custom plugins for more information on how to integrate Media Tree with your own applications.

Plugin: File listing

This plugin allows you to put a file listing on a page, displaying download links for the selected FileNode objects in a folder tree.

The folder tree that is rendered does not have to be identical to the actual tree in your media library. Instead, you can group arbitrary nodes, or output a merged (flat) list.

Installation

To use this plugin, put media_tree.contrib.cms_plugins.media_tree_listing in your installed apps, and run manage.py syncdb.

Template

Override the template cms/plugins/media_tree_listing.html if you want to customize the output. Please take a look at the default template for more information.

Plugin: Image

This plugin allows you to put a single picture on a page, as a figure complete with caption and other metadata.

Installation

To use this plugin, put media_tree.contrib.cms_plugins.media_tree_image in your installed apps, and run manage.py syncdb.

Template

Override the template cms/plugins/media_tree_image.html if you want to customize the output. Please take a look at the default template for more information.

By default, images are rendered to the output using the template media_tree/filenode/includes/figure.html, which includes captions.

Plugin: Slideshow

This plugin allows you to put a slideshow on a page, automatically displaying the selected image files with customizable transitions and intervals.

Installation

To use this plugin, put media_tree.contrib.cms_plugins.media_tree_slideshow in your installed apps, and run manage.py syncdb.

Template

Override the template cms/plugins/media_tree_slideshow.html if you want to customize the output. Please take a look at the default template for more information.

By default, images are rendered to the output using the template media_tree/filenode/includes/figure.html, which includes captions.

Note

The default template requires you to include jQuery in your pages, since it uses the jQuery Cycle Plugin (bundled) for image transitions.