Renderer plugins
Ross Burton <[email protected]>
| Newsgroups | gmane.comp.web.pyblosxom.user |
|---|---|
| Message-ID | <1107176144.28574.27.camel@localhost> |
Hi,
I've got a plugin written for Pyblosxom 0.8 which in cb_start checked if
the request filename matched a certain name and if so send some data to
the client and set renderer.rendered to 1:
def cb_start(args):
request = args['request']
pyhttp = request.getHttp()
config = request.getConfiguration()
renderer = request.getData()['renderer']
if pyhttp["PATH_INFO"].endswith("doap.rdf"):
data = open(config["datadir"] + pyhttp["PATH_INFO"]).read()
renderer.addHeader('Content-type', 'application/rdf_xml')
renderer.addHeader('Content-Length', len(data))
renderer.showHeaders()
renderer.write(data)
renderer.rendered = 1
However, this isn't working with Pyblosxom 1.1: there isn't a "renderer"
item in the Request.getData() dict. Is this a bug in 1.1, or is there
an API change?
Thanks,
Ross
--
Ross Burton mail: [email protected]
jabber: [email protected]
www: http://www.burtonini.com./
PGP Fingerprint: 1A21 F5B0 D8D0 CFE3 81D4 E25A 2D09 E447 D0B4 33DF
-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl