Changeset 167:7e2b97941a66 in documentViewer for MpdlXmlTextServer.py


Ignore:
Timestamp:
Aug 24, 2010, 12:43:24 PM (14 years ago)
Author:
abukhman
Branch:
default
Message:

characterNormalization

File:
1 edited

Legend:

Unmodified
Added
Removed
  • MpdlXmlTextServer.py

    r166 r167  
    4343        docpath = docinfo['textURLPath']
    4444        url = docinfo['url']
    45         #logging.debug("documentViewer (gettoc) docpath: %s"%(docpath))
    46         #logging.debug("documentViewer (gettoc) url: %s"%(url))
     45        logging.debug("documentViewer (gettoc) docpath: %s"%(docpath))
     46        logging.debug("documentViewer (gettoc) url: %s"%(url))
    4747        pagesize = pageinfo['queryPageSize']
    4848        pn = pageinfo['searchPN']
     
    254254         tocSearch = int(getTextFromNode(numdivs[0]))
    255255         tc=int((tocSearch/10)+1)
    256          #logging.debug("documentViewer (gettoc) tc: %s"%(tc))
     256         logging.debug("documentViewer (gettoc) tc: %s"%(tc))
    257257         return tc
    258258
    259259    def getToc(self, mode="text", docinfo=None):
    260260        """loads table of contents and stores in docinfo"""
    261         #logging.debug("documentViewer (gettoc) mode: %s"%(mode))
     261        logging.debug("documentViewer (gettoc) mode: %s"%(mode))
    262262        if mode == "none":
    263263            return docinfo       
     
    303303        selfurl = self.absolute_url() 
    304304        viewMode=  pageinfo['viewMode']
    305         characterNormalization =pageinfo['characterNormalization']
     305        characterNormalization =pageinfo ['characterNormalization']
    306306        tocMode = pageinfo['tocMode']
    307307        tocPN = pageinfo['tocPN'] 
    308308       
    309         data = self.getServerData("doc-query.xql","document=%s&queryType=%s&queryResultPageSize=%s&queryResultPN=%s"%(docpath,queryType, pagesize, pn)) 
    310         page = data.replace('page-fragment.xql?document=%s'%str(path),'%s?url=%s&viewMode=%s&tocMode=%s&tocPN=%s&characterNormalization=%s'%(selfurl,url, viewMode, tocMode, tocPN,characterNormalization))
     309        data = self.getServerData("doc-query.xql","document=%s&queryType=%s&queryResultPageSize=%s&queryResultPN=%s&characterNormalization=%s"%(docpath,queryType, pagesize, pn,characterNormalization)) 
     310        page = data.replace('page-fragment.xql?document=%s'%str(path),'%s?url=%s&viewMode=%s&tocMode=%s&tocPN=%s'%(selfurl,url, viewMode, tocMode, tocPN))
    311311        text = page.replace('mode=image','mode=texttool')
    312312        logging.debug("documentViewer (characterNormalization) characterNormalization: %s"%(characterNormalization))
Note: See TracChangeset for help on using the changeset viewer.