changeset 612:a79e4e4b3e37

json schnittsellen
author dwinter
date Thu, 16 May 2013 18:04:00 +0200
parents e18ef3786753
children c57d80a649ea
files documentViewer.py
diffstat 1 files changed, 9 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/documentViewer.py	Tue Jan 29 17:56:47 2013 +0100
+++ b/documentViewer.py	Thu May 16 18:04:00 2013 +0200
@@ -500,6 +500,15 @@
             
         return userinfo
 
+    def getDocinfoJSON(self, mode, url, tocMode=None):
+        """returns docinfo depending on mode"""
+        import json
+        
+        dc = self.getDocinfo( mode, url, tocMode)
+        
+        return json.dumps(dc)
+    
+    
     def getDocinfo(self, mode, url, tocMode=None):
         """returns docinfo depending on mode"""
         logging.debug("getDocinfo: mode=%s, url=%s"%(mode,url))