summaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2012-07-09 06:30:48 +0200
committerDan McGee <dan@archlinux.org>2012-07-09 06:33:44 +0200
commit8383a071608329c7683f7a710030ce945bd20b4d (patch)
tree55efabe829287b71cfb52b8db3dc05e3dd0294e7 /main
parentc589f7d930ee7642524ecc33ee41bae79d4edd9b (diff)
downloadarchweb-8383a071608329c7683f7a710030ce945bd20b4d.tar.gz
archweb-8383a071608329c7683f7a710030ce945bd20b4d.tar.xz
Add a new jquery_tablesorter CDN template tag
And use it everywhere we were including the file before. This should make updating the version a heck of a lot easier. Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'main')
-rw-r--r--main/templatetags/cdn.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/main/templatetags/cdn.py b/main/templatetags/cdn.py
index ab5d881..5429982 100644
--- a/main/templatetags/cdn.py
+++ b/main/templatetags/cdn.py
@@ -17,4 +17,11 @@ def jquery():
link = staticfiles_storage.url(filename)
return '<script type="text/javascript" src="%s"></script>' % link
+
+@register.simple_tag
+def jquery_tablesorter():
+ filename = 'jquery.tablesorter.min.js'
+ link = staticfiles_storage.url(filename)
+ return '<script type="text/javascript" src="%s"></script>' % link
+
# vim: set ts=4 sw=4 et: