mark_safe
This commit is contained in:
parent
3ac7ed5e42
commit
cedf131f4d
|
@ -1,5 +1,5 @@
|
|||
from django import template
|
||||
|
||||
from django.utils.safestring import mark_safe
|
||||
register = template.Library()
|
||||
|
||||
def make_li(value):
|
||||
|
@ -7,6 +7,6 @@ def make_li(value):
|
|||
ret = ''
|
||||
for l in lines:
|
||||
ret += "<li>%s</li>" % l
|
||||
return ret
|
||||
return mark_safe(ret)
|
||||
|
||||
register.filter("make_li", make_li)
|
||||
|
|
Loading…
Reference in New Issue
Block a user