cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christian Zoffoli <czoff...@littlepenguin.org>
Subject BUG in RequestGenerator ?
Date Thu, 21 Mar 2002 20:16:20 GMT

Hi to all.
I found a problem using RequestGenerator. 

The generated document seems not processable by any processor (xalan,
saxon, MSXML)


output example:

--------------------------
<?xml version="1.0" encoding="UTF-8"?>
<request target="/betanews202-1/betanews/test.xml" source=""
xmlns="http://xml.apache.org/cocoon/requestgenerator/2.0">

<requestHeaders>
<header name="host">localhost:8080</header>
....
</requestHeaders>

<requestParameters>
<parameter name="email">
<value>prova@prova.com</value>

</parameter>
....

</requestParameters>

<configurationParameters>
</configurationParameters>

</request>

--------------------------


...from my point of view the problem is
'xmlns="http://xml.apache.org/cocoon/requestgenerator/2.0"'  

two possible solutions:
1- add a suffix to "xmlns" ---> xmlns:request
2- remove the namespace declaration (see the following stupid patch)


-- cut --
--- src/java/org/apache/cocoon/generation/RequestGenerator.java	Fri Feb
22 08:03:51 2002
+++ src/java/org/apache/cocoon/generation/RequestGenerator.java.new	Wed
Mar 20 03:39:37 2002
@@ -116,7 +116,7 @@
     throws SAXException {
         Request request = ObjectModelHelper.getRequest(objectModel);
         this.contentHandler.startDocument();
-        this.contentHandler.startPrefixMapping("",URI);
+        //this.contentHandler.startPrefixMapping("",URI);
         AttributesImpl attr=new AttributesImpl();

         this.attribute(attr,"target", request.getRequestURI());
-- cut --



Christian

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Mime
View raw message