I want to do exactly the same thing as you. If anyone could help us or
provide us advice I would really appreciate.

Cheers,

Jean-Marc Borer

Mamadou Bobo Sylla wrote:
> 
> Hello everyone,
> I am trying to test some the code examples from Apache . When I call the xml
> page countries.xml through bowser, it works fine being processd by page.xsl.
> But I want countries.xml to be processed after a resquet to a servlet.
> For that purpose I have writtent a servlet called Test which should now
> output the xml  to be processed by a stylsheet called page.xsl.
> 
> How do I configure  Cocoon so that it becomes aware of my servlet.
> 
> The codes of Test.java:
> ============
> public class Test extends HttpServlet {
> 
>  public void doGet( HttpServletRequest req,
>                        HttpServletResponse res )
>         throws ServletException, IOException
>  {
> 
>   PrintWriter output = res.getWriter();
>         res.setContentType( "text/xml" );
> 
>          StringBuffer xmlbuf =new StringBuffer("<?xml version=\"1.0\"
> encoding = \"UTF-8\"?>");
>   xmlbuf.append("<?cocoon-process type=\"xslt\"?>");
>   xmlbuf.append("<?xml-stylesheet href=\"page.xsl\" type=\"text/xsl\"?>");
>   xmlbuf.append("<page>");
>   xmlbuf.append("<country code = \"ca\">Canada</country>");
>   xmlbuf.append( "<country code = \"de\">Germany</country>");
>   xmlbuf.append("<country code = \"fr\">France</country>") ;
>   xmlbuf.append("<country code = \"uk\">United Kingdom</country>");
>   xmlbuf.append("<country code = \"us\">United States</country>");
>   xmlbuf.append("<country code = \"es\">Spain</country>");
>   xmlbuf.append("</page>");
> 
>   output.println(xmlbuf.toString());
> 
>  }
> ==================
> 
> }
> ============
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, email: [EMAIL PROTECTED]


Mamadou Bobo Sylla wrote:
> 
> Hello everyone,
> I am trying to test some the code examples from Apache . When I call the xml
> page countries.xml through bowser, it works fine being processd by page.xsl.
> But I want countries.xml to be processed after a resquet to a servlet.
> For that purpose I have writtent a servlet called Test which should now
> output the xml  to be processed by a stylsheet called page.xsl.
> 
> How do I configure  Cocoon so that it becomes aware of my servlet.
> 
> The codes of Test.java:
> ============
> public class Test extends HttpServlet {
> 
>  public void doGet( HttpServletRequest req,
>                        HttpServletResponse res )
>         throws ServletException, IOException
>  {
> 
>   PrintWriter output = res.getWriter();
>         res.setContentType( "text/xml" );
> 
>          StringBuffer xmlbuf =new StringBuffer("<?xml version=\"1.0\"
> encoding = \"UTF-8\"?>");
>   xmlbuf.append("<?cocoon-process type=\"xslt\"?>");
>   xmlbuf.append("<?xml-stylesheet href=\"page.xsl\" type=\"text/xsl\"?>");
>   xmlbuf.append("<page>");
>   xmlbuf.append("<country code = \"ca\">Canada</country>");
>   xmlbuf.append( "<country code = \"de\">Germany</country>");
>   xmlbuf.append("<country code = \"fr\">France</country>") ;
>   xmlbuf.append("<country code = \"uk\">United Kingdom</country>");
>   xmlbuf.append("<country code = \"us\">United States</country>");
>   xmlbuf.append("<country code = \"es\">Spain</country>");
>   xmlbuf.append("</page>");
> 
>   output.println(xmlbuf.toString());
> 
>  }
> ==================
> 
> }
> ============
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, email: [EMAIL PROTECTED]

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

Reply via email to