django-cms-fragments

Injecting fragments of JavaScript, CSS and HTML in a django-cms plugin
Download

django-cms-fragments Ranking & Summary

Advertisement

  • Rating:
  • License:
  • BSD License
  • Price:
  • FREE
  • Publisher Name:
  • Mauro Bianchi
  • Publisher web site:
  • https://github.com/bianchimro/

django-cms-fragments Tags


django-cms-fragments Description

django-cms-fragments is a django-cms plugin that allows you to include several fragments of JavaScript, CSS and HTML in the context of a cms page. Fragments can be added by uploading a file, providing an external url(for js and css), or writing inline code.The plugin basically adds jss and js to the page, using sekizai tags. It relies on the fact that django-cms requires "js" and "css" blocks to work. The html fragments are rendered within the plugin template.This package is in an alpha stage, don't use it in production. I will hopefully provide a more stable version very soon.I created the project because i didn't want to have to modify my cms installation by adding templates or app_hooks for displaying rich visualizations such as Openlayers Maps or jQplot charts. Another use of the plugin is overriding some css in a particular cms page.Installation Install via pip: pip install django-cms-fragments Add 'cms_fragments' to your INSTALLED_APPS Use 'django.contrib.staticfiles', or copy the static subfolder of django-cms-fragments to your static folderUsageTo use the plugin, you must create some Fragment or FragmentCollection instances with the Django admin. FragmentCollections are a collection of Fragments. Once you have one or more Fragments or FragmentCollections in the DB, you can choose which one to put in a plugin, with the usual django-cms interface.Product's homepage


django-cms-fragments Related Software