made template compatible with Django 1.5, thereby dropping Django <= 1.3 compatibility