]> git.phdru.name Git - bookmarks_db.git/blobdiff - bkmk_parser.py
Store charset in the DB and the generated HTML.
[bookmarks_db.git] / bkmk_parser.py
index d43674138e33f4f2eccc2b577a9ff2656c725cb9..7ce99e8412447cbba334291783149f80cc2c3e46 100755 (executable)
@@ -80,6 +80,8 @@ class BkmkParser(HTMLParser):
 
 
    def start_title(self, attrs):
+      if DEFAULT_CHARSET:
+         self.accumulator += '<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=%s">\n' % DEFAULT_CHARSET
       self.accumulator += "<TITLE>"
 
    def end_title(self):