mirror of
https://github.com/ankitects/anki.git
synced 2025-11-06 12:47:11 -05:00
we do need to quote when adding media
contrary to commit 3576475, we do need to quote when adding media on windows
as well, as it seems webkit can not handle all representations variants when
passed unicode
as we're stripping # and % when adding characters, hopefully that's the last
of it!
This commit is contained in:
parent
cfac1eb99b
commit
9c24c41b90
1 changed files with 1 additions and 2 deletions
|
|
@ -866,8 +866,7 @@ to a cloze type first, via Edit>Change Note Type."""))
|
||||||
pass
|
pass
|
||||||
# return a local html link
|
# return a local html link
|
||||||
ext = name.split(".")[-1].lower()
|
ext = name.split(".")[-1].lower()
|
||||||
if not isWin and not isMac:
|
name = urllib.quote(name.encode("utf8"))
|
||||||
name = urllib.quote(name.encode("utf8"))
|
|
||||||
if ext in pics:
|
if ext in pics:
|
||||||
return '<img src="%s">' % name
|
return '<img src="%s">' % name
|
||||||
else:
|
else:
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue