diff options
author | Chris Ball <cjb@laptop.org> | 2008-05-25 16:22:27 (GMT) |
---|---|---|
committer | Chris Ball <cjb@laptop.org> | 2008-05-25 16:22:27 (GMT) |
commit | e1193acb3e51eaa10f758360087323a8b0fa57ed (patch) | |
tree | 5804e056a71ac144cc32031e1d35cdc23cefee98 | |
parent | 8dfc4bc616d7f303b31c98d165193abc7a31967e (diff) |
Unicode crashes in writeImageMap.
-rwxr-xr-x | server.py | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -246,7 +246,7 @@ class WPHTMLWriter(mwlib.htmlwriter.HTMLWriter): attr += 'width="%d" ' % width img = '<%(tag)s %(ref)s="%(url)s" longdesc="%(caption)s" %(attr)s></%(tag)s>' % \ - {'tag':tag, 'ref':ref, 'url':url.encode('utf8'), 'caption':caption.encode('utf8'), 'attr':attr} + {'tag':tag, 'ref':ref, 'url':url, 'caption':caption, 'attr':attr} if thumb: frame = True @@ -271,7 +271,7 @@ class WPHTMLWriter(mwlib.htmlwriter.HTMLWriter): self.out.write(img) self.out.write('<div class="thumbcaption">') self.out.write('<div class="magnify" style="float:right">') - self.out.write('<a href="%s" class="internal" title="Enlarge">' % url.encode("utf8")) + self.out.write('<a href="%s" class="internal" title="Enlarge">' % url) self.out.write('<img src="/static/magnify-clip.png">') self.out.write('</a>') self.out.write('</div>') |