]> git.llucax.com Git - personal/website.git/commitdiff
blog: Don't use port
authorLeandro Lucarella <luca@llucax.com>
Sun, 17 May 2020 15:12:13 +0000 (17:12 +0200)
committerLeandro Lucarella <luca@llucax.com>
Sun, 17 May 2020 15:12:13 +0000 (17:12 +0200)
source/blog/blog.cgi

index 0875ea76d7069d5bbe183981fadac4a207c31a09..2865925128a9e4f6cb691157c870fb5bc9ff3281 100755 (executable)
@@ -559,11 +559,12 @@ def sanitize(obj):
 # find out our URL, needed for syndication
 try:
        n = os.environ['SERVER_NAME']
-       p = os.environ['SERVER_PORT']
+        # Removed port because it messes up when behind a proxy
+       #p = os.environ['SERVER_PORT']
        s = os.environ['SCRIPT_NAME']
-       if p == '80': p = ''
-       else: p = ':' + p
-       full_url = 'https://%s%s%s' % (n, p, s)
+       #if p == '80': p = ''
+       #else: p = ':' + p
+       full_url = 'https://%s%s' % (n, s)
 except KeyError:
        full_url = 'Not needed'