mirror of
https://github.com/jazzband/django-analytical.git
synced 2026-03-16 22:20:25 +00:00
Merge branch 'master' of github.com:jcassee/django-analytical
This commit is contained in:
commit
861e3b7947
1 changed files with 9 additions and 0 deletions
|
|
@ -36,6 +36,15 @@ CUSTOM_VAR_CODE = "_gaq.push(['_setCustomVar', %(index)s, '%(name)s', " \
|
|||
|
||||
register = Library()
|
||||
|
||||
def enumerate(sequence, start=0):
|
||||
"""
|
||||
Port of 2.6's python enumerate() for compatibility with previos versions
|
||||
"""
|
||||
n = start
|
||||
for elem in sequence:
|
||||
yield n, elem
|
||||
n += 1
|
||||
|
||||
|
||||
@register.tag
|
||||
def google_analytics(parser, token):
|
||||
|
|
|
|||
Loading…
Reference in a new issue