mirror of
https://github.com/getpelican/pelican.git
synced 2025-10-15 20:28:56 +02:00
import wordpress using real name from urlencoded file name
This commit is contained in:
parent
3437592c48
commit
56a78553c8
1 changed files with 2 additions and 1 deletions
|
|
@ -9,6 +9,7 @@ import re
|
|||
import subprocess
|
||||
import sys
|
||||
import time
|
||||
import urllib
|
||||
|
||||
from codecs import open
|
||||
|
||||
|
|
@ -134,7 +135,7 @@ def get_items(xml):
|
|||
|
||||
def get_filename(filename, post_id):
|
||||
if filename is not None:
|
||||
return filename
|
||||
return urllib.unquote(unicode(filename).encode("utf-8")).decode("utf-8")
|
||||
else:
|
||||
return post_id
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue