This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# can be used to hide email addresses in the html source of Web sites from spiders | |
def html_encode(email): | |
''' | |
Takes a unicode string as only parameter and returns | |
a sequence of html encoded chars. | |
>>> html_encode(u"[email protected]") | |
'test@website.org' | |
''' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
''' | |
Django filters, needed when creating LaTeX files with the django template language | |
''' | |
from django.template.defaultfilters import stringfilter, register | |
from django.template.loader import render_to_string | |
@register.filter | |
@stringfilter | |
def brackets(value): |
NewerOlder