changeset 437:da43c361c0ff

*** empty log message ***
author abukhman
date Thu, 10 Mar 2011 15:03:31 +0100
parents 0baf4e761be7
children 3e78973773c0
files MpdlXmlTextServer.py
diffstat 1 files changed, 9 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/MpdlXmlTextServer.py	Mon Mar 07 15:08:07 2011 +0100
+++ b/MpdlXmlTextServer.py	Thu Mar 10 15:03:31 2011 +0100
@@ -20,7 +20,9 @@
     
     manage_changeMpdlXmlTextServerForm = PageTemplateFile("zpt/manage_changeMpdlXmlTextServer", globals())
         
-    def __init__(self,id,title="",serverUrl="http://mpdl-proto.mpiwg-berlin.mpg.de/mpdl/interface/", serverName=None, timeout=40):
+    #def __init__(self,id,title="",serverUrl="http://mpdl-proto.mpiwg-berlin.mpg.de/mpdl/interface/", serverName=None, timeout=40):
+    def __init__(self,id,title="",serverUrl="http://mpdl-test.mpiwg-berlin.mpg.de:30030/mpdl/interface/", serverName=None, timeout=40):    
+        
         """constructor"""
         self.id=id
         self.title=title
@@ -183,6 +185,7 @@
         name = docinfo.get('name',None)
         pn =pageinfo['current']
         sn = pageinfo['sn']
+        optionToggle =pageinfo ['optionToggle']
         highlightQuery = pageinfo['highlightQuery']
         #mode = pageinfo ['viewMode']
         tocMode = pageinfo['tocMode']
@@ -194,7 +197,7 @@
         else:
             textmode = mode
         
-        textParam = "document=%s&mode=%s&pn=%s&characterNormalization=%s"%(docpath,textmode,pn,characterNormalization)
+        textParam = "document=%s&mode=%s&pn=%s&characterNormalization=%s&optionToggle=%s"%(docpath,textmode,pn,characterNormalization,optionToggle)
         if highlightQuery is not None:
             textParam +="&highlightQuery=%s&sn=%s"%(urllib.quote(highlightQuery),sn)           
         
@@ -480,7 +483,8 @@
         text = page.replace('mode=image','mode=texttool')
         return text
     
-    def manage_changeMpdlXmlTextServer(self,title="",serverUrl="http://mpdl-proto.mpiwg-berlin.mpg.de/mpdl/interface/",timeout=40,RESPONSE=None):
+    #def manage_changeMpdlXmlTextServer(self,title="",serverUrl="http://mpdl-proto.mpiwg-berlin.mpg.de/mpdl/interface/",timeout=40,RESPONSE=None):
+    def manage_changeMpdlXmlTextServer(self,title="",serverUrl="http://mpdl-test.mpiwg-berlin.mpg.de:30030/mpdl/interface/",timeout=40,RESPONSE=None):
         """change settings"""
         self.title=title
         self.timeout = timeout
@@ -494,7 +498,8 @@
     pt = PageTemplateFile("zpt/manage_addMpdlXmlTextServer", globals()).__of__(self)
     return pt()
 
-def manage_addMpdlXmlTextServer(self,id,title="",serverUrl="http://mpdl-proto.mpiwg-berlin.mpg.de/mpdl/interface/",timeout=40,RESPONSE=None):
+#def manage_addMpdlXmlTextServer(self,id,title="",serverUrl="http://mpdl-proto.mpiwg-berlin.mpg.de/mpdl/interface/",timeout=40,RESPONSE=None):
+def manage_addMpdlXmlTextServer(self,id,title="",serverUrl="http://mpdl-test.mpiwg-berlin.mpg.de:30030/mpdl/interface/",timeout=40,RESPONSE=None):    
     """add zogiimage"""
     newObj = MpdlXmlTextServer(id,title,serverUrl,timeout)
     self.Destination()._setObject(id, newObj)