changeset 65:c048559460a3

fix problems with full text paths starting with /mpiwg/online
author casties
date Fri, 29 Jun 2007 17:44:40 +0200
parents d928e4820b93
children e3fd957a1b2a
files documentViewer.py
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/documentViewer.py	Fri Jun 22 18:04:24 2007 +0200
+++ b/documentViewer.py	Fri Jun 29 17:44:40 2007 +0200
@@ -425,7 +425,10 @@
            textUrl=getTextFromNode(textUrls[0])
            if urlparse.urlparse(textUrl)[0]=="": #keine url
                textUrl=os.path.join(archivePath,textUrl) 
-
+           # fix URLs starting with /mpiwg/online
+           if textUrl.startswith("/mpiwg/online"):
+               textUrl = textUrl.replace("/mpiwg/online",'',1)
+           
            docinfo['textURL'] = textUrl
    
        presentationUrls=dom.xpath("//texttool/presentation")