Altova Mailing List Archives>Archive Index >comp.text.xml Archive Home >Recent entries >Thread Prev - Re: Include Elements from other namespace in own XML >Thread Next - Re: Include Elements from other namespace in own XML Re: Include Elements from other namespace in own XMLTo: NULL Date: 7/6/2007 9:44:00 AM Benjamin Kalytta <bkausbk@w...> wrote in <f6db8c$mic$1@o...>: >> [...] PHP 5 DOM works just fine. >> > That's true. I made a stupid mistake. I always tried to > get nodeValue of <string> which of course always get > entire text content including those of all child elements. > saveXML() now will output correct tree like expected. > (Text <html:a href="#">Link</html:a>) > > But is it possible to remove each namespace prefix from > XML DOM Tree so that only a ... left? I think there is > no XML conform way to do this. If you mean 'is there a magic switch that would make that happen upon parsing', then no, there isn't any that I'm aware of (I suppose that's because getting rid of namespaces is not a particularly good idea). However, this is trivial to do using DOM tree traversal or XSLT stylesheet. But as I said, I'm not sure this is a good idea at all. Why would you want to get rid of namespaces? If you don't want namespaces, why does your document contain them in first place? -- Pavel Lepin | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
