This means that if I use the following for my Included Elements XPath:
/rss//item
Nothing will be found.
Dynamic XML DSs get around this by allowing the author to add any namespaces they required as Name/URI pairs. I think the XML Importer needs the same option. To include these namespaces the Dynamic DS ingeniously creates an XSLT stylesheet on the fly, appends the namespaces as processing instructions, and applies it against the XML that is grabbed.
I think XML Importer should do exactly the same. Perhaps its grabbing of XML should even create a Dynamic DS object in memory so that the code for obtaining an XML file, including namespaces, and returning just the XML required, all remains in Symphony’s core (datasource.dynamic_xml.php).
Might be less maintenance in the long run? And is much cooler :-)
There is a bug XML elements are namespaced. For example:
This means that if I use the following for my Included Elements XPath:
Nothing will be found.
Dynamic XML DSs get around this by allowing the author to add any namespaces they required as Name/URI pairs. I think the XML Importer needs the same option. To include these namespaces the Dynamic DS ingeniously creates an XSLT stylesheet on the fly, appends the namespaces as processing instructions, and applies it against the XML that is grabbed.
I think XML Importer should do exactly the same. Perhaps its grabbing of XML should even create a Dynamic DS object in memory so that the code for obtaining an XML file, including namespaces, and returning just the XML required, all remains in Symphony’s core (datasource.dynamic_xml.php).
Might be less maintenance in the long run? And is much cooler :-)