Index: MpdlXmlTextServer.py
===================================================================
--- MpdlXmlTextServer.py	(revision 441)
+++ MpdlXmlTextServer.py	(revision 442)
@@ -42,5 +42,5 @@
         return documentViewer.getHttpData(url,data,timeout=self.timeout)
 
-    def getSearch(self, pageinfo=None,  docinfo=None,   lemma=None):
+    def getSearch(self, pageinfo=None,  docinfo=None):
         """get search list"""
         docpath = docinfo['textURLPath'] 
@@ -104,8 +104,8 @@
                             hrefNode.nodeValue = pagexml.replace('page-fragment.xql','%s'%selfurl)  
                         if href.startswith('../lt/lemma.xql'):
-                            hrefNode.nodeValue = href.replace('../lt/lemma.xql','%s/template/head_main_lemma_New'%(selfurl))        
+                            hrefNode.nodeValue = href.replace('../lt/lemma.xql','%s/template/head_main_query'%(selfurl))        
                             l.setAttributeNS(None, 'target', '_blank')
                             l.setAttributeNS(None, 'onClick',"popupWin = window.open(this.href, 'contacts', 'location,width=500,height=600,top=180, left=400, scrollbars=1'); return false;")
-                            l.setAttributeNS(None, 'onClick', 'popupWin.focus();')  
+                            l.setAttributeNS(None, 'onDblclick', 'popupWin.focus();')  
                 pagedivs = pagedom.xpath("//div[@class='queryResultMorphExpansion']")                
                 return serializeNode(pagenode)        
@@ -121,13 +121,13 @@
                         hrefNode.nodeValue=href.replace('mode=text','mode=texttool&viewMode=%s&tocMode=%s&tocPN=%s&pn=%s&optionToggle=%s&characterNormalization=%s'%(viewMode,tocMode,tocPN,pn,optionToggle,characterNormalization))             
                         if href.startswith('../lt/lex.xql'):
-                            hrefNode.nodeValue = href.replace('../lt/lex.xql','%s/template/head_main_voc'%selfurl)         
+                            hrefNode.nodeValue = href.replace('../lt/lex.xql','%s/template/head_main_lex'%selfurl)         
                             l.setAttributeNS(None, 'target', '_blank')
                             l.setAttributeNS(None, 'onClick',"popupWin = window.open(this.href, 'contacts', 'location,width=500,height=600,top=180, left=400, scrollbars=1'); return false;")
-                            l.setAttributeNS(None, 'onClick', 'popupWin.focus();')
+                            l.setAttributeNS(None, 'onDblclick', 'popupWin.focus();')
                         if href.startswith('../lt/lemma.xql'):
-                            hrefNode.nodeValue = href.replace('../lt/lemma.xql','%s/template/head_main_lemma'%selfurl)        
+                            hrefNode.nodeValue = href.replace('../lt/lemma.xql','%s/template/head_main_lemma'%(selfurl))        
                             l.setAttributeNS(None, 'target', '_blank')
                             l.setAttributeNS(None, 'onClick',"popupWin = window.open(this.href, 'contacts', 'location,width=500,height=600,top=180, left=400, scrollbars=1'); return false;")
-                            l.setAttributeNS(None, 'onClick', 'popupWin.focus();')
+                            l.setAttributeNS(None, 'onDblclick', 'popupWin.focus();')
                 return serializeNode(pagenode)      
         return "no text here"   
@@ -349,19 +349,22 @@
                         # is link with href
                         href = hrefNode.nodeValue
-                        if href.startswith('../lt/wordInfo.xql'):
+                        if href.startswith('http://mpdl-proto.mpiwg-berlin.mpg.de/mpdl/interface/lt/wordInfo.xql'):
                             # is pollux link
                             selfurl = self.absolute_url()
                             # change href
-                            hrefNode.nodeValue = href.replace('../lt/wordInfo.xql','%s/template/voc'%selfurl)
+                            hrefNode.nodeValue = href.replace('http://mpdl-proto.mpiwg-berlin.mpg.de/mpdl/interface/lt/wordInfo.xql','%s/head_main_voc'%selfurl)
                             # add target
                             l.setAttributeNS(None, 'target', '_blank')
-                            l.setAttributeNS(None, 'onClick',"popupWin = window.open(this.href, 'contacts', 'location,width=500,height=600,top=180, left=700, scrollbars=1'); return false;")
-                            l.setAttributeNS(None, 'onClick', 'popupWin.focus();')      
-                        if href.startswith('lt/lemma.xql'):    
+                            l.setAttributeNS(None, 'onClick',"popupWin = window.open(this.href, 'InfoWindow', 'menubar=no, location,width=500,height=600,top=180, left=700, toolbar=no, scrollbars=1'); return false;")
+                            l.setAttributeNS(None, "onDblclick", "popupWin.focus();")
+                            #window.open("this.href, 'InfoWindow', 'menubar=no, location,width=500,height=600,top=180, left=700, toolbar=yes, scrollbars=1'"); return false;")
+                                                          
+                        if href.startswith('http://mpdl-proto.mpiwg-berlin.mpg.de/mpdl/lt/lemma.xql'):    
                             selfurl = self.absolute_url()
-                            hrefNode.nodeValue = href.replace('lt/lemma.xql','%s/template/head_main_lemma'%selfurl)
+                            hrefNode.nodeValue = href.replace('http://mpdl-proto.mpiwg-berlin.mpg.de/mpdl/lt/lemma.xql','%s/head_main_lemma'%selfurl)
                             l.setAttributeNS(None, 'target', '_blank')
-                            l.setAttributeNS(None, 'onClick',"popupWin = window.open(this.href, 'contacts', 'location,width=500,height=600,top=180, left=700, scrollbars=1'); return false;")
-                            l.setAttributeNS(None, 'onClick', 'popupWin.focus();')   
+                            l.setAttributeNS(None, 'onClick',"popupWin = window.open(this.href, 'InfoWindow', 'menubar=no, location,width=500,height=600,top=180, left=700, toolbar=no, scrollbars=1'); return false;")
+                            l.setAttributeNS(None, 'onDblclick', 'popupWin.focus();')   
+                        
                         if href.startswith('#note-'):
                             hrefNode.nodeValue = href.replace('#note-',"?url=%s&viewMode=text_dict&tocMode=%s&tocPN=%s&pn=%s#note-"%(url,tocMode,tocPN,pn))    
@@ -394,7 +397,7 @@
 
                 
-    def getTranslate(self, query=None, language=None):
+    def getTranslate(self, word=None, language=None):
         """translate into another languages"""
-        data = self.getServerData("lt/lex.xql","document=&language="+str(language)+"&query="+urllib.quote(query))
+        data = self.getServerData("lt/wordInfo.xql","language="+str(language)+"&word="+urllib.quote(word)+"&output=html")
         #pagexml=self.template.fulltextclient.eval("/mpdl/interface/lt/lex.xql","document=&language="+str(language)+"&query="+url_quote(str(query)))
         return data
@@ -402,12 +405,15 @@
     def getLemma(self, lemma=None, language=None):
         """simular words lemma """
-        data = self.getServerData("lt/lemma.xql","document=&language="+str(language)+"&lemma="+urllib.quote(lemma))
-        #pagexml=self.template.fulltextclient.eval("/mpdl/interface/lt/lemma.xql","document=&language="+str(language)+"&lemma="+url_quote(str(lemma)))
+        data = self.getServerData("lt/lemma.xql","language="+str(language)+"&lemma="+urllib.quote(lemma)+"&output=html")
         return data
     
-    def getLemmaNew(self, query=None, language=None):
+    def getLemmaQuery(self, query=None, language=None):
         """simular words lemma """
-        data = self.getServerData("lt/lemma.xql","document=&language="+str(language)+"&lemma="+urllib.quote(query))
-        #pagexml=self.template.fulltextclient.eval("/mpdl/interface/lt/lemma.xql","document=&language="+str(language)+"&lemma="+url_quote(str(query)))
+        data = self.getServerData("lt/lemma.xql","language="+str(language)+"&query="+urllib.quote(query)+"&output=html")
+        return data
+    
+    def getLex(self, query=None, language=None):
+        #simular words lemma
+        data = self.getServerData("lt/lex.xql","document=&language="+str(language)+"&query="+urllib.quote(query))
         return data
     
