Updated patch for django
http://amit.chakradeo.net/2007/07/05/django-unicode-integration-fix-for-venus-djando-template/
This commit is contained in:
parent
23cd6be041
commit
3f764d6466
@ -40,7 +40,9 @@ def run(script, doc, output_file=None, options={}):
|
||||
reluri = os.path.splitext(os.path.basename(output_file))[0]
|
||||
context['url'] = urlparse.urljoin(config.link(),reluri)
|
||||
f = open(output_file, 'w')
|
||||
f.write(t.render(context).encode('utf-8'))
|
||||
ss = t.render(context)
|
||||
if isinstance(ss,unicode): ss=ss.encode('utf-8')
|
||||
f.write(ss)
|
||||
f.close()
|
||||
else:
|
||||
# @@this is useful for testing purposes, but does it
|
||||
|
Loading…
Reference in New Issue
Block a user