cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Donald Ball <ba...@webslingerZ.com>
Subject problem with namespace declarations and XSP
Date Wed, 21 Jun 2000 17:00:27 GMT
Heya. A buddy of mine was testing out cocoon and came up with this
anomaly. He got an XML page like so:

<?xml version="1.0" ?>

<?cocoon-process type="xsp"?>
<?cocoon-process type="xslt"?>
<?xml-stylesheet href="mail.xsl" type="text/xsl"?>

<xsp:page 
   language="java"
   xmlns:xsp="http://www.apache.org/1999/XSP/Core"
   xmlns:mail="http://www.webslingerZ.com/archiveMail"
>
<page>
  <mail:list>
    <mail:message>
      <messageId>12345</messageId>
      <subject>You're a dink.</subject>
    </mail:message>
    <mail:message>
      <messageId>67890</messageId>
      <subject>Work damnit.</subject>
    </mail:message>
  </mail:list>
</page>
</xsp:page>

The stylesheet in question failed to process the elements in the mail
namespace. I tested out a simpler version by stripping the xslt stuff:

<?xml version="1.0" ?>

<?cocoon-process type="xsp"?>

<xsp:page 
   language="java"
   xmlns:xsp="http://www.apache.org/1999/XSP/Core"
   xmlns:mail="http://www.webslingerZ.com/archiveMail"
>
<page>
  <mail:list>
    <mail:message>
      <messageId>12345</messageId>
      <subject>You're a dink.</subject>
    </mail:message>
    <mail:message>
      <messageId>67890</messageId>
      <subject>Work damnit.</subject>
    </mail:message>
  </mail:list>
</page>
</xsp:page>

and my result is:

<?xml version="1.0" encoding="UTF-8"?>
<page>
  <mail:list>
    <mail:message>
      <messageId>12345</messageId>
      <subject>You&apos;re a dink.</subject>
    </mail:message>
    <mail:message>
      <messageId>67890</messageId>
      <subject>Work damnit.</subject>
    </mail:message>
  </mail:list>
</page>

note that the mail namespace declaration is _not_ copied to the result. I
think that's why the XSLT processor isn't rendering the results properly.
Ricardo, got any clues here?

- donald


Mime
View raw message