Skip to main content

Simple app for managing small blocks of text/html.

Project description

Installation

  1. Add textblocks and optionally modeltranslation to INSTALLED_APPS

  2. Add an entry for textblocks to your MIGRATION_MODULES (textblocks cannot ship its own migrations because the exact schema depends on your LANGUAGES setting) and create an empty Python module (folder with an empty __init__.py file).

  3. Run ./manage.py makemigrations textblocks and ./manage.py migrate

Usage

  1. Load templatetags {% load textblock_tags %}

  2. Add textblock tags with unique identifiers and format (text/plain or text/html):

    {% textblock "introduction" "text/plain" %}

Text blocks with identifiers that do not exist in the database yet will automatically be created.

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

django-textblocks-0.2.tar.gz (3.5 kB view details)

Uploaded Source

File details

Details for the file django-textblocks-0.2.tar.gz.

File metadata

File hashes

Hashes for django-textblocks-0.2.tar.gz
Algorithm Hash digest
SHA256 ff20be4feefbb248f821d1d4ec7d8b90cad140d128227e8c84271a8ec7012b3c
MD5 49495dc66a92ba28b415eef74fe900a4
BLAKE2b-256 03419dbbbf943a2f7f23de7a6986691f0d1738f344525a07f566944f1e8b8997

See more details on using hashes here.

Supported by

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