replacing hyphen

pull/7/head
Castro0o 5 years ago
parent 652d069c35
commit 0b29abe5b7

@ -34,6 +34,8 @@ with open('login.txt', 'r') as login: # read login user & pwd
SLASH = "\u2044"
HYPHEN = "\u2010"
def filenameforpage(p):
f = p.name.replace(' ','_').replace('/', SLASH) + '.html'
@ -43,7 +45,7 @@ def filenameforlink(href):
href = urlunquote(href)
if href.startswith("/sandbox/itchwiki/index.php/"):
href = href[len("/sandbox/itchwiki/index.php/"):]
href = href.replace(' ','_').replace('/', SLASH) + '.html'
href = href.replace(' ','_').replace('/', SLASH).replace('', HYPHEN) + '.html'
href = urlquote(href)
return href

Loading…
Cancel
Save