{ "info": { "author": "Martin Aspeli", "author_email": "optilude@gmail.com", "bugtrack_url": null, "classifiers": [ "Framework :: Plone", "Programming Language :: Python", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "**XDV has been renamed to Diazo. Equivalent WSGI middleware is part of the Diazo package.** Visit the `Diazo website`_ or the `Diazo PyPI page`_ for further information.\n\n.. _`Diazo website`: http://diazo.org\n.. _`Diazo PyPI page`: http://pypi.python.org/pypi/diazo\n\nIntroduction\n============\n\ndv.xdvserver is a simple piece of WSGI middleware that can execute the two\nstep compile-and-run XSLT transforms of xdv.\n\nIt takes two required parameters:\n\n - rules: a path to a file containing Deliverance rules\n - theme: a URI or path to a theme HTML file\n\nIn addition, it can take several optional parameters:\n\n - absolute_prefix: if given, relative urls in the theme file will be made\n into absolute links with this prefix.\n - notheme: a set of regular expression patterns (or just simple names) that\n will be matched against the incoming path to allow the theme to be\n switched off for some paths. Multiple patterns should be separated by\n newlines.\n - live: set to True to recompile the theme on each request, rather than on\n startup only.\n - compiler: a path to the XSLT file that can turn theme+rules into a compiled\n theme. The default, bundled version will probably suffice in most cases.\n - boilerplate: a path to the XSLT file that contains boilerplate XSLT\n instructions. The default, bundled version will probably suffice in most\n cases.\n \nConfiguration\n=============\n\nYou can use this middleware in a Paste Deploy pipeline. Here is an example \nconfiguration file of an application that themes a Plone site running on\nhttp://localhost:8080/demo. Static resources are served from /static::\n\n [server:main]\n use = egg:Paste#http\n host = 127.0.0.1\n port = 5000\n\n [composite:main]\n use = egg:Paste#urlmap\n /static = static\n / = default\n\n [app:static]\n use = egg:Paste#static\n document_root = %(here)s/static\n\n [pipeline:default]\n pipeline = egg:Paste#cgitb\n egg:Paste#httpexceptions\n theme.default\n zope.proxy\n\n [filter:theme.default]\n use = egg:dv.xdvserver#xdv\n theme = %(here)s/static/index.html\n rules = %(here)s/static/rules/default.xml\n notheme =\n /emptypage\n\n [app:zope.proxy]\n use = egg:Paste#proxy\n address = http://localhost:8080/VirtualHostBase/http/localhost:5000/demo/VirtualHostRoot/\n\nChangelog\n=========\n\n1.0b8 - 2010-08-22\n------------------\n\n* use lxml.html.tostring instead of lxml.tostring for output to \n avoid empty tags like