summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
0cecf7d)
- iff we get a string object rather than a unicode one, decode it from utf-8
url = u''
for attr in attrs:
if attr[0] == 'alt':
url = u''
for attr in attrs:
if attr[0] == 'alt':
+ if isinstance(attr[1], str):
+ alt = u'%s' %(attr[1].decode("utf-8"))
+ else:
+ alt = attr[1]
+ if isinstance(attr[1], str):
+ url = u'%s' %(attr[1].decode("utf-8"))
+ else:
+ url = attr[1]
if url:
if alt:
if self.images.has_key(alt):
if url:
if alt:
if self.images.has_key(alt):