Launch Week Day 5: Introducing Reachability for PHP.Learn More
Socket
Book a DemoSign in
Socket

feincms-richtextplus

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

feincms-richtextplus

RichText Content with TYPE_CHOICES configurability

pipPyPI
Version
1.1.0
Maintainers
1

==================== feincms_richtextplus

feincms_richtextplus is a feincms plugin that copies the functionality of the original RichTextContent, and adds TYPE_CHOICES configuration option

Convenient when you need to render RichText data using different templates which you can pick from admin page

Installation

  • Add "feincms_richtextplus" to your INSTALLED_APPS setting like this::

    INSTALLED_APPS = ( ... 'feincms_richtextplus', )

  • Create RichTextPlusContent for your Page model (or any other Base-derived model) like this::

    from feincms_richtextplus.models import RichTextPlusContent

    ...

    Page.create_content_type(SimpleTableContent, TYPE_CHOICES=( ('default', 'default richtextplus'), ('wrapped', 'wrapped data'), # ... (other TYPE_CHOICES) ))

  • Define templates for every TYPE_CHOICES entry, i.e.:: project_dir/app/templates/content/richtextplus/default.html project_dir/app/templates/content/richtextplus/wrapped.html

  • Migrate Page

FAQs

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts