version 1.238.2.6, 2011/08/03 19:04:18
|
version 1.238.2.7, 2011/08/04 14:57:02
|
Line 1
|
Line 1
|
|
|
from OFS.SimpleItem import SimpleItem |
from OFS.SimpleItem import SimpleItem |
from Products.PageTemplates.PageTemplateFile import PageTemplateFile |
from Products.PageTemplates.PageTemplateFile import PageTemplateFile |
|
|
Line 269 class MpdlXmlTextServer(SimpleItem):
|
Line 268 class MpdlXmlTextServer(SimpleItem):
|
return |
return |
|
|
|
|
def getTextPage(self, mode="text_dict", pn=1, docinfo=None, pageinfo=None): |
def getTextPage(self, mode="text", pn=1, docinfo=None, pageinfo=None): |
"""returns single page from fulltext""" |
"""returns single page from fulltext""" |
logging.debug("getTextPage mode=%s, pn=%s"%(mode,pn)) |
logging.debug("getTextPage mode=%s, pn=%s"%(mode,pn)) |
# check for cached text -- but this shouldn't be called twice |
# check for cached text -- but this shouldn't be called twice |
Line 292 class MpdlXmlTextServer(SimpleItem):
|
Line 291 class MpdlXmlTextServer(SimpleItem):
|
characterNormalization = pageinfo.get('characterNormalization', None) |
characterNormalization = pageinfo.get('characterNormalization', None) |
selfurl = docinfo['viewerUrl'] |
selfurl = docinfo['viewerUrl'] |
|
|
if mode == "text_dict": |
if mode == "dict": |
# text_dict is called textPollux in the backend |
# text_dict is called textPollux in the backend |
textmode = "textPollux" |
textmode = "textPollux" |
|
elif not mode: |
|
# default is text |
|
textmode = "text" |
else: |
else: |
textmode = mode |
textmode = mode |
|
|