diff MpdlXmlTextServer.py @ 475:5a3ab27385ce elementtree

more new template stuff
author casties
date Fri, 05 Aug 2011 19:04:20 +0200
parents 0bc4a153863a
children 1d93a8cb2d8f
line wrap: on
line diff
--- a/MpdlXmlTextServer.py	Fri Aug 05 15:31:27 2011 +0200
+++ b/MpdlXmlTextServer.py	Fri Aug 05 19:04:20 2011 +0200
@@ -257,6 +257,10 @@
                 # WTF: s1 = int(s)/30+1
                 docinfo['numTocEntries'] = getInt(div.text)
                 
+            # numPlaces
+            elif dc == 'countPlaces':
+                docinfo['numPlaces'] = getInt(div.text)
+                
             # numTextPages
             elif dc == 'countPages':
                 np = getInt(div.text)                    
@@ -302,6 +306,7 @@
             textmode = "textPollux"
         elif not mode:
             # default is text
+            mode = "text"
             textmode = "text"
         else:
             textmode = mode
@@ -340,7 +345,7 @@
                 return serialize(pagediv)
             
         # text-with-links mode
-        elif mode == "text_dict":
+        elif mode == "dict":
             if pagediv is not None:
                 # check all a-tags
                 links = pagediv.findall(".//a")