Hi, I am using xi:include to include external xml in my main xml document.
For example:
<xi:include href=" />
This is fine if "config.aspx" returns valid xml. But if "config.aspx" returns invalid xml, then the whole document fails (the xml returned from config.aspx can't be parsed). Sometimes the "config.aspx" returns an empty string, and this is invalid xml.
How can I configure the xi:include so it ignores parsing errors, and doesn't include the invalid xml in the main document?
I looked at <xi:fallback> but it appears this is only invoked if the external resource can't be found, not if the external resource exists but is invalid.
I also looked at parse="text", but this will encode the xml returned from config.aspx, and I'm not entirely sure this is what I want - I want xml after all, not text.
Any help appreciated!
Thanks,
Peter
For example:
<xi:include href=" />
This is fine if "config.aspx" returns valid xml. But if "config.aspx" returns invalid xml, then the whole document fails (the xml returned from config.aspx can't be parsed). Sometimes the "config.aspx" returns an empty string, and this is invalid xml.
How can I configure the xi:include so it ignores parsing errors, and doesn't include the invalid xml in the main document?
I looked at <xi:fallback> but it appears this is only invoked if the external resource can't be found, not if the external resource exists but is invalid.
I also looked at parse="text", but this will encode the xml returned from config.aspx, and I'm not entirely sure this is what I want - I want xml after all, not text.
Any help appreciated!
Thanks,
Peter