Skip to content
Simple banner application
Python
Latest commit a938825 Jul 21, 2014 @Arvi3d Arvi3d Merge pull request #4 from hecrogon/bannertags
banner_tags as a inclusion tag
Failed to load latest commit information.
src/banner
.gitignore
LICENSE.MIT
MANIFEST.in
README.rst
setup.cfg
setup.py

README.rst

Django simple banner template tag

Link to repository: https://github.com/Arpaso/django-banner-simple

Provides new template tag to display banner uploaded via admin interface.

Banner model and BannerAdmin is added.

Usage

  • You have to use south migrations to update your database:

    python manage.py migrate
    

Note

Banner admin page is provided for adding banner through django admin interface

  • Add application to INSTALLED_APPS in settings.py:

    ...
    'banner',
    ...
    
  • Use template tag in your templates as is:

    {% get_banner 'banner_name' 150 150 %}
    

Note

get_banner(slug, width, height, queryset=Banner.objects.all())

Uses also settings.STATIC_URL to display banner image.

Written by the development team of Arpaso company: http://arpaso.com

Something went wrong with that request. Please try again.