Diff for /ECHO_content/ECHO_collection.py between versions 1.161 and 1.162

version 1.161, 2004/08/05 20:29:23 version 1.162, 2004/08/09 10:10:56
Line 48  import xml.dom.minidom Line 48  import xml.dom.minidom
 from ECHO_graphicalOverview import javaHandler,javaScriptMain  from ECHO_graphicalOverview import javaHandler,javaScriptMain
 import ECHO_helpers  import ECHO_helpers
   
   #regexp for extracting elements from xml
   patternTXT=r"<\s*txt.*?>(.*?)</txt>"
   regexpTXT = re.compile(patternTXT, re.IGNORECASE + re.DOTALL)
   patternPage=r"<\s*page.*?>(.*?)</page>"
   regexpPage = re.compile(patternPage, re.IGNORECASE + re.DOTALL)
   
           
 def ECHO_rerenderLinksMD(self,obj=None,types=['title','label']):  def ECHO_rerenderLinksMD(self,obj=None,types=['title','label']):
         """Rerender all Links"""          """Rerender all Links"""
     ret=""      ret=""
Line 3051  class ECHO_root(Folder,Persistent,Implic Line 3058  class ECHO_root(Folder,Persistent,Implic
                     link.setAttribute("href",self.aq_parent.absolute_url()+"/vlp_coll?id="+ref)                      link.setAttribute("href",self.aq_parent.absolute_url()+"/vlp_coll?id="+ref)
   
             newxml=dom.toxml('utf-8')              newxml=dom.toxml('utf-8')
         match=re.sub(r'<\?xml version=\"1.0\" encoding=\"utf-8\"\?>\n<txt>','',newxml)  
         match=re.sub(r'</txt>','',match)  
                   
         return match          retStr=regexpTXT.search(newxml)
   
           return retStr.group(1)
   
                                 
         return ""          return ""
   
Line 3073  class ECHO_root(Folder,Persistent,Implic Line 3081  class ECHO_root(Folder,Persistent,Implic
                 if self.checkRef(ref):                  if self.checkRef(ref):
                     link.setAttribute("href",self.aq_parent.absolute_url()+"/vlp_coll?id="+ref)                      link.setAttribute("href",self.aq_parent.absolute_url()+"/vlp_coll?id="+ref)
   
             return dom.toxml('utf-8')              str= dom.toxml('utf-8')
           #print str
           retStr=regexpPage.search(str)
   
           return retStr.group(1)
         return ""          return ""
   
     def checkRef(self,ref):      def checkRef(self,ref):

Removed from v.1.161  
changed lines
  Added in v.1.162


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>