Re: [xml] empty xmlns attributes

On Tue, Feb 11, 2003 at 11:21:15PM +0000, Peter McGarvey wrote:

The weirdest thing is that my theory works for me, but doesn't apply 
to your example, because you get correct xmlns in your <a> tags:

  Your stylesheet puts the root html element in the XHTML namespace as
the default namespace. If you later generate XHTML element but without
namespace in the stylesheet, libxslt will do what you asked for and
as a result MUST eliminate the default namespace, and does that by
outputting xmlns="" which is the *only* way to do what you ask it to do.
Soultion is to NOT ask the stylesheet to generate XHTML element without
namespace, and make 100% sure in your staylesheet that all generated
element are in the default XHTML namespace.
   You MUST read and understand the following spec before solving your

  <p> and <p> can represent TOTALLY different things depending on the
default namespace context.


Daniel Veillard      | Red Hat Network
veillard redhat com  | libxml GNOME XML XSLT toolkit | Rpmfind RPM search engine

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]