summaryrefslogtreecommitdiff
path: root/planet
diff options
context:
space:
mode:
authorMagnus Hagander2008-10-28 16:17:56 +0000
committerMagnus Hagander2008-10-28 16:17:56 +0000
commit346aba23eb13cb7fc00861ab26c756e91397487d (patch)
tree2cd1ab8fe51fd07cd80b4d13d4610276ec7bf982 /planet
parent64331ffb45252bb0211d541ba8bbc141c7cd016f (diff)
Only quote ampersand, that's the one that the HTML validator bitches about.
Specifically don't quote the whole URL, because it's going into HTML and not into a different URL. Per notice from Gevik git-svn-id: file:///Users/dpage/pgweb/svn-repo/trunk@2252 8f5c7a92-453e-0410-a47f-ad33c8a6b003
Diffstat (limited to 'planet')
-rw-r--r--planet/planethtml.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/planet/planethtml.py b/planet/planethtml.py
index 89120860..9dfb5583 100644
--- a/planet/planethtml.py
+++ b/planet/planethtml.py
@@ -11,10 +11,10 @@ import datetime
import urllib
# Yes, a global function (!)
+# Hmm. We only quote the ampersand here, since it's a HTML escape that
+# shows up in URLs quote often.
def quoteurl(str):
- if str=="": return ""
- p = str.split(":",2)
- return p[0] + ":" + urllib.quote(p[1])
+ return str.replace('&','&')
class PlanetPost:
def __init__(self, guid,link,dat,title,author,blogurl,txt):