diff --git a/daemon.py b/daemon.py index 22f40d18..8d66cba8 100644 --- a/daemon.py +++ b/daemon.py @@ -979,9 +979,9 @@ class PubServer(BaseHTTPRequestHandler): imageFilename=imageFilename.split('?')[0] imageDescription=None if '?desc=' in self.path: - imageDescription=self.path.split('?desc=')[1] + imageDescription=self.path.split('?desc=')[1].replace('%20',' ').replace('%40','@').replace('%3A',':').replace('%23','#') if '?' in imageDescription: - imageDescription=imageDescription.split('?')[0] + imageDescription=imageDescription.split('?')[0] msg=htmlFullScreenImage(imageFilename,imageDescription).encode('utf-8') self._set_headers('text/html',len(msg),cookie) self._write(msg) diff --git a/webinterface.py b/webinterface.py index a1f6d3d9..5d1e6635 100644 --- a/webinterface.py +++ b/webinterface.py @@ -68,9 +68,9 @@ def htmlFullScreenImage(imageFilename: str,description: str) -> str: htmlStr+=' background-image: url("'+imageFilename+'");\n' htmlStr+='\n' if description: - htmlStr+=' width: 90%;\n' + htmlStr+=' height: 90%;\n' else: - htmlStr+=' width: 100%;\n' + htmlStr+=' height: 100%;\n' htmlStr+='' htmlStr+=' background-position: center;\n' htmlStr+=' background-repeat: no-repeat;\n'