equal
deleted
inserted
replaced
179 xsltree = etree.XML(ytext, base_url=os.path.abspath(yscript.filename())) |
179 xsltree = etree.XML(ytext, base_url=os.path.abspath(yscript.filename())) |
180 transform = etree.XSLT(xsltree) |
180 transform = etree.XSLT(xsltree) |
181 |
181 |
182 if options.params: |
182 if options.params: |
183 params = eval(options.params) |
183 params = eval(options.params) |
184 for key, value in params.iteritems(): |
184 for key, value in params.items(): |
185 if type(value) is not str: |
185 if type(value) is not str: |
186 params[key] = u(value) |
186 params[key] = u(value) |
187 if options.stringparams: |
187 if options.stringparams: |
188 for key, value in eval(options.stringparams).iteritems(): |
188 for key, value in eval(options.stringparams).items(): |
189 params[key] = "'" + u(value) + "'" |
189 params[key] = "'" + u(value) + "'" |
190 |
190 |
191 rresult = transform(doc, **params) |
191 rresult = transform(doc, **params) |
192 # lxml is somewhat buggy |
192 # lxml is somewhat buggy |
193 try: |
193 try: |