First of all thanks very trying to help me with this. 
It is good to know there seems more behind 
this problem then just a small error - played to long 
with this problem to be just easy to solve. :-)

It seems it has to do something with the html 
tag combined with the XHTML namespace. I tried your
things and had the same results.
 
I found this point what might has do somehting
with it:
http://archives.real-time.com/pipermail/cocoon-devel/2003-May/013622.htm
l

I am using Xalan 2.5.0. Is this maybe a reason?

Greetings

Christian


> -----Ursprüngliche Nachricht-----
> Von: Bruno Dumon [mailto:[EMAIL PROTECTED]
> Gesendet: Sonntag, 15. Februar 2004 10:57
> An: [EMAIL PROTECTED]
> Betreff: Re: Xinclude/Xpointer problem with XHTML Namespace
> 
> 
> On Sun, 2004-02-15 at 09:32, Christian Kreutz wrote:
> > Hello list,
> > 
> > I have a problem with xpointer and
> > xmlns="http://www.w3.org/1999/xhtml";
> > namespace.
> > I want to include parts of a xhtml document (title) in 
> another xml file, but
> > it doesn't get the content of the node <title> using
> xinclude in either
> > article1 or article2.  In case of article3 it works but
> only for the whole file.
> > :-)  But when I delete the namespace
> xmlns="http://www.w3.org/1999/xhtml out
> > of
> > index.xml I get an outcome from the article2 xinclude. 
> > 
> > Any ideas? Thanks for any help.
> > 
> > The file to where parts of index.xml should be included:
> > 
> > <?xml version="1.0" encoding="utf-8" ?>
> > <news xmlns:xi="http://www.w3.org/2001/XInclude";>
> >   <article1>
> >   <xi:include
> > 
> href="article1/index.xml#xmlns(ert=http://www.w3.org/1999/xhtm
> l)#xpointer(//ert:title)" />
> 
> First of all, you got a "#" too many in there, it should
> read: 
> href="article1/index.xml#xmlns(ert=http://www.w3.org/1999/xhtm
> l)xpointer(//ert:title)"
> 
> error reporting on this was pretty lame (you got a blank
> page), I've made some fixes for this which I'll check in in a moment.
> 
> But then it still won't work. To try it out I simplified your
> document down to this:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <html xmlns="http://www.w3.org/1999/xhtml";>
>   <head>
>     <title>Title to be included with xpointer</title>
>   </head>
> </html>
> 
> and tried the following includes:
> <xi:include
> href="article1/index.xml#xmlns(ert=http://www.w3.org/1999/xhtm
> l)xpointer(//ert:title)" />  
> <xi:include 
> href="article1/index.xml#xmlns(my=http://www.w3.org/1999/xhtml
> )xpointer(/my:html/my:head/my:title)"/>
> 
> which don't work.
> 
> Interestingly enough, if you change both the XML file and the
> xpointer expressions by renaming html to x, head to y and 
> title to z (while leaving them in the same namespace), it 
> will work. Here are the
> snippets:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <x xmlns="http://www.w3.org/1999/xhtml";>
>   <y>
>     <z>Title to be included with xpointer</z>
>   </y>
> </x>
> 
> and
> 
> <xi:include
> href="article1/index.xml#xmlns(ert=http://www.w3.org/1999/xhtm
> l)xpointer(//ert:z)" />  
> <xi:include 
> href="article1/index.xml#xmlns(my=http://www.w3.org/1999/xhtml
> )xpointer(/my:x/my:y/my:z)"/>
> 
> Also interesting, is that when changing the document to use
> explicit namespaces, it also works:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <x:html xmlns:x="http://www.w3.org/1999/xhtml";>
>   <x:head>
>     <x:title>Title to be included with xpointer</x:title>
>   </x:head>
> </x:html>
> 
> I've also tried changing the XPath processor implementation
> from xalan to jaxen but that didn't make a difference.
> 
> The only thing I could still think of then is that the
> DOMBuilder does something special with plain HTML elements, 
> but I wouldn't know what and didn't immediately notice something.
> 
> Needs further investigation... (for which I don't have time right now)
> 
> -- 
> Bruno Dumon                             http://outerthought.org/
> Outerthought - Open Source, Java & XML Competence Support Center
> [EMAIL PROTECTED]                          [EMAIL PROTECTED]
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to