April 20, 2007
7:58 a.m.
Hi, Jeroen van Holst wrote:
I'm trying to pass a parameter to an XSLT object as follows:
xslt = etree.parse(stylesheet) style = etree.XSLT(xslt) params = {'profile.lang': 'en'} result = style(doc, params)
The stylesheet is applied, but the parameter is ignored. This works in libxslt, so what am I missing?
One thing you're missing is that lxml is not libxslt. It has a different API. Have you tried result = style(doc, **params) ? Stefan