Skip to main content

A simple mezzanine app which allows the placement of a Mezzanine Gallery within another Mezzanine Page as a slideshow

Project description

mezzanine-slideshows is for use with the Mezzanine CMS. It allows the placement of Mezzanine Galleries within other Mezzanine Pages as slideshows.

Requirements

mezzanine-slideshows requires that the following python apps be installed:

  • Python 3.4

  • Mezzanine 3.1 (and its dependencies)

  • Django 1.7 + (this app uses the django migrations framework)

Installation

The easiest method is to install directly from pypi using pip by running the command below:

$ pip install mezzanine-slideshows

Super Quick Start

These instructions are for instant setup with the Mezzanine demonstration installation and allow you to place Mezzanine Galleries at the end of other Mezzanine Pages as slideshows. If you are using anything other than the standard templates provided with a fresh Mezzanine install or wish to place the galleries at any place other than the end of pages please follow the Regular Setup instructions below.

  1. Create a new Mezzanine project following the official instructions.

  2. Add mezzanine_slideshows to INSTALLED_APPS in settings.py immediately after your Django apps and before your Mezzanine apps:

    INSTALLED_APPS = (
        ...
        "mezzanine_slideshows",
        ...
        )
  3. Add the following to TEMPLATE_CONTEXT_PROCESSORS in settings.py:

    TEMPLATE_CONTEXT_PROCESSORS = (
        ...
        "mezzanine_slideshows.context_processors.get_slideshows"
        )
  4. Run python manage.py migrate mezzanine_slideshows to create the mezzanine-slideshows models.

  5. Start the development server and visit http://127.0.0.1:8000/admin/ to create a slideshow instance.

  6. Navigate to the page on the site to see your gallery displayed after the page text as a slideshow.

Regular Setup

  1. Add mezzanine_slideshows as an app in your project like this:

    INSTALLED_APPS = (
        ...
        "mezzanine_slideshows"
        )
  2. Add the following template context processor in settings.py:

    TEMPLATE_CONTEXT_PROCESSORS = (
        ...
        "mezzanine_slideshows.context_processors.get_slideshows"
        )
  3. Run python manage.py migrate mezzanine_slideshows to create the mezzanine-slideshows models.

  4. In the header of your base.html file after the other css files add the lines

    <link rel="stylesheet" href="{% static "mezzanine/css/magnific-popup.css" %}">
    <link rel="stylesheet" href="{% static "mezzanine-slideshows/css/owl.carousel.css" %}">
    <link rel="stylesheet" href="{% static "mezzanine-slideshows/css/owl.theme.css" %}">
  5. At the end of your base.html file, just after

    {% include "includes/footer_scripts.html" %}

    add the following three lines:

    <script src="{% static "mezzanine-slideshows/js/owl.carousel.js" %}"></script>
    <script src="{% static "mezzanine-slideshows/js/jquery.magnific-popup.js" %}"></script>
  6. This step is key. Without it no slideshows will appear. Add the following code to any place you wish a template to check whether a slideshow should be displayed. If a slideshow is dues to show on that page it will be displayed at that place in the template:

    {% include "includes/mezzanine_slideshows.html" %}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mezzanine-slideshows-0.3.2.tar.gz (26.5 kB view details)

Uploaded Source

File details

Details for the file mezzanine-slideshows-0.3.2.tar.gz.

File metadata

File hashes

Hashes for mezzanine-slideshows-0.3.2.tar.gz
Algorithm Hash digest
SHA256 a5908546690d0e2db0698516fe01ea32b343d90381b5360616862b4074320444
MD5 fe1ec2d337952aacb9f68a80e4b1f291
BLAKE2b-256 36f2275d6e61ad98faef68077cc1939a6d97b75b85f4a505781f27be4c4b9e6f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page