escape & in HTML messages.

This commit is contained in:
Yann Leboulanger 2009-01-27 20:33:54 +00:00
parent f11c1b226a
commit 0b7f2c3fe7
1 changed files with 1 additions and 0 deletions

View File

@ -217,6 +217,7 @@ class MessageTextView(gtk.TextView):
def xhtml_special(text):
text = text.replace('<', '&lt;')
text = text.replace('>', '&gt;')
text = text.replace('&', '&amp;')
text = text.replace('\n', '<br />')
return text