Skip to main content

This is a simple app, which supplies a single template tag for markdown markup.

Project description

changelog

This is a simple app, which supplies a single template tag for markdown markup.

Dependencies

django-markdown2 depends on python-markdown2, which can be found at http://code.google.com/p/python-markdown2.

Installation and usage

  • Place django_markdown2 somewhere in your PYTHONPATH.

  • Add django_markdown2 to you INSTALLED_APPS.

  • In any template do:

    {% load md2 %}
    {{ variable|markdown }}
    
  • Or specify additional extensions:

    {% load md2 %}
    {{ variable|markdown:"safe, code-friendly, code-color" }}
    
  • Also, if you use my recent markdown2-with-blackjack from http://pypi.aartemenko.com, then you can pass additional options to code-color extension:

    {% load md2 %}
    {{ variable|markdown:"safe, code-friendly, code-color: noclasses|linenos" }}
    

Options from this example switch off css classes and turn on line numbers.

Contribution

Code for this application available at: http://github.com/svetlyak40wt/django-markdown2

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-markdown2, version 0.2.0
Filename, size File type Python version Upload date Hashes
Filename, size django-markdown2-0.2.0.tar.gz (2.5 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 Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page