Skip to main content
Python Software Foundation 20th Year Anniversary Fundraiser  Donate today!

A django admin widget to render a text field as beautiful Imperavi WYSIWYG editor

Project description

Django Imperavi editor
Supported versions
Supports Django >=1.8 and Python 2/3

pip install git+

* Add ``imperavi`` to your ``INSTALLED_APPS`` setting.

* Add imperavi URL include to your project's ```` file::

url(r'^imperavi/', include('imperavi.urls')),

cd example/
python migrate
./ shell -c "from django.contrib.auth.models import User; User.objects.create_superuser('admin', '', 'admin')"
python runserver
Then go to []( and try to create post instance

login: admin
password: admin


The quickest way to add rich text editing capabilities to your admin is to use the included ``ImperaviAdmin`` class. For example::

from .models import Category
from imperavi.admin import ImperaviAdmin

class CategotyAdmin(ImperaviAdmin):
pass, CategotyAdmin)

If you want to use it with inline admin models you need to use ``ImperaviStackedInlineAdmin`` class::

from .models import Post
from imperavi.admin import ImperaviStackedInlineAdmin

class PostInline(ImperaviStackedInlineAdmin):
model = Post
extra = 1

Custom settings

Add a ``IMPERAVI_CUSTOM_SETTINGS`` variable to your ```` with custom config::

'resize': true

Full list of settings is here.

Media URL

You can also customize the URL that django-imperavi-widget will look for the Editor media at by adding ``IMPERAVI_UPLOAD_PATH`` to your ```` file like this::

IMPERAVI_UPLOAD_PATH = 'imperavi-uploads/'

The default value is ``'imperavi/'``.

Unique images per model

If you want to serve unique media content for specific model you can add ``unique_media = True`` to your admin class::

from .models import Category
from imperavi.admin import ImperaviAdmin

class CategotyAdmin(ImperaviAdmin):
unique_media = True, CategotyAdmin)

Project details

Download files

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

Files for django-imperavi-widget, version 0.0.3
Filename, size File type Python version Upload date Hashes
Filename, size django-imperavi-widget-0.0.3.tar.gz (159.0 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page