changeset 625:80a3b1fa5705

more move sslification to only client-visible urls.
author casties
date Mon, 15 Dec 2014 17:18:20 +0100
parents 80a0191ae51c
children 7dafe8283312
files documentViewer.py
diffstat 1 files changed, 5 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/documentViewer.py	Mon Dec 15 17:05:51 2014 +0100
+++ b/documentViewer.py	Mon Dec 15 17:18:20 2014 +0100
@@ -518,9 +518,9 @@
         docinfo = {'mode': mode, 'url': url}
         # add self url
         docinfo['viewerUrl'] = self.getDocumentViewerURL()
-        docinfo['digilibBaseUrl'] = self.digilibBaseUrl
-        docinfo['digilibScalerUrl'] = self.digilibScalerUrl
-        docinfo['digilibViewerUrl'] = self.digilibViewerUrl
+        docinfo['digilibBaseUrl'] = sslifyUrl(self.digilibBaseUrl, self, force=True)
+        docinfo['digilibScalerUrl'] = sslifyUrl(self.digilibScalerUrl, self, force=True)
+        docinfo['digilibViewerUrl'] = sslifyUrl(self.digilibViewerUrl, self, force=True)
         # get index.meta DOM
         docUrl = None
         metaDom = None
@@ -642,7 +642,7 @@
             if docinfo.get('imagePath', None):
                 imgpath = docinfo['imagePath'].replace('/mpiwg/online', '', 1)
                 logging.debug("imgpath=%s"%imgpath)
-                docinfo['imageURL'] = "%s?fn=%s"%(self.digilibScalerUrl, imgpath)
+                docinfo['imageURL'] = sslifyUrl("%s?fn=%s"%(self.digilibScalerUrl, imgpath), self, force=True)
                 docinfo = self.getDocinfoFromDigilib(docinfo, imgpath)
             else:
                 # imagePath still missing? try "./pageimg"
@@ -651,7 +651,7 @@
                 if docinfo.get('numPages', 0) > 0:
                     # there are pages
                     docinfo['imagePath'] = imgPath
-                    docinfo['imageURL'] = "%s?fn=%s"%(self.digilibScalerUrl, docinfo['imagePath'])
+                    docinfo['imageURL'] = sslifyUrl("%s?fn=%s"%(self.digilibScalerUrl, docinfo['imagePath']), self, force=True)
 
         # check numPages
         if docinfo.get('numPages', 0) == 0: