RE: Request to external XML server in pipeline

2002-05-02 Thread Matthew Langham

Hi Bryce,

here's one way of doing this:

pipeline
reguest generator
  stylesheet - builds cinclude statements with the params
  cinclude transformer
  stylesheet for output
/pipeline
So you use the cinclude transformer to fetch the external data. Check out
the cinclude documentation for more details.

Matthew

--
Open Source Group   sunShine - Lighting up e:Business
=
Matthew Langham, SN AG, Klingenderstrasse 5, D-33100 Paderborn
Tel:+49-5251-1581-30  [EMAIL PROTECTED] - http://www.s-und-n.de
   Weblogging at: http://www.need-a-cake.com
 Cocoon book: http://www.amazon.com/exec/obidos/ASIN/0735712352
=



-Original Message-
From: Ewing, Bryce [mailto:[EMAIL PROTECTED]]
Sent: Thursday, May 02, 2002 11:27 AM
To: '[EMAIL PROTECTED]'
Subject: Request to external XML server in pipeline


Hi,

Just started working with Cocoon and I have a question in regards to reading
XML content from a XML server probably within a pipeline.  What I have at
present is a backend XML server that given a XML formatted packet does some
processing, including database access, legacy etc. then replies with an
answer XML packet.  This is totally outside of Cocoon.

What I have inside Cocoon at present is an html form that has the request
parameters that would make up the inwards XML packet.  I have a pipeline
that has a request generator, then a xslt transformation to get the XML into
the required format.  What I would like to do is post this packet to the XML
server, with the reply packet being available to the pipeline, maybe a
transformer that changes the input XML to the output via the post.  Then
process this reply XML packet to create the next HTML page.

If anyone has any help on this, or can think of a better way this could be
performed your help would be greatly appreciated.

Cheers
Bryce

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




RE: Request to external XML server in pipeline

2002-05-02 Thread Carsten Ziegeler

In the case of a POST, you can use the session transformer (only available
in the latest CVS) instead of the cinclude transformer:

 pipeline
reguest generator
   stylesheet - builds cinclude statements with the params
   cinclude transformer
   stylesheet for output
 /pipeline

The session transformer is able to use post for HTTP requests. The following
XML should get something from http://itsunshine/test by using POST:

data xmlns:session=http://ocoon.apache.org/session/1.0;
  session:include
  session:connection type=uri
  !-- THE URI --
  session:targethttp://itsunshine/test/session:target

  !-- Setting POST --
  session:config
session:param
  session:namemethod/session:name
  session:valuePOST/session:value
  /session:param
   /session:config

   !-- Setting parameters --
   session:params
 session:param
  session:namemessage/session:name
  session:valueHi there/session:value
/session:param
  /session:params
  /session:connection
   /session:include
/data

But I must confess that I'm not sure if this works with the lastest CVS,
as we changed the source resolving - I will have a look at it asap.

HTH
Carsten

 -Original Message-
 From: Matthew Langham [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, May 02, 2002 11:47 AM
 To: [EMAIL PROTECTED]
 Subject: RE: Request to external XML server in pipeline


 Hi Bryce,

 here's one way of doing this:

 pipeline
   reguest generator
   stylesheet - builds cinclude statements with the params
   cinclude transformer
   stylesheet for output
 /pipeline
 So you use the cinclude transformer to fetch the external data. Check out
 the cinclude documentation for more details.

 Matthew

 --
 Open Source Group   sunShine - Lighting up e:Business
 =
 Matthew Langham, SN AG, Klingenderstrasse 5, D-33100 Paderborn
 Tel:+49-5251-1581-30  [EMAIL PROTECTED] - http://www.s-und-n.de
Weblogging at: http://www.need-a-cake.com
  Cocoon book: http://www.amazon.com/exec/obidos/ASIN/0735712352
 =



 -Original Message-
 From: Ewing, Bryce [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, May 02, 2002 11:27 AM
 To: '[EMAIL PROTECTED]'
 Subject: Request to external XML server in pipeline


 Hi,

 Just started working with Cocoon and I have a question in regards
 to reading
 XML content from a XML server probably within a pipeline.  What I have at
 present is a backend XML server that given a XML formatted packet
 does some
 processing, including database access, legacy etc. then replies with an
 answer XML packet.  This is totally outside of Cocoon.

 What I have inside Cocoon at present is an html form that has the request
 parameters that would make up the inwards XML packet.  I have a pipeline
 that has a request generator, then a xslt transformation to get
 the XML into
 the required format.  What I would like to do is post this packet
 to the XML
 server, with the reply packet being available to the pipeline, maybe a
 transformer that changes the input XML to the output via the post.  Then
 process this reply XML packet to create the next HTML page.

 If anyone has any help on this, or can think of a better way this could be
 performed your help would be greatly appreciated.

 Cheers
 Bryce

 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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


 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Request to external XML server in pipeline

2002-05-02 Thread Zack Angelo

Bryce,

On a side note, it sounds like you may also benefit from the use of SOAP,
have you checked it out yet?

-Zack

On 5/2/02 4:27 AM, Ewing, Bryce [EMAIL PROTECTED] wrote:

 Hi,
 
 Just started working with Cocoon and I have a question in regards to reading
 XML content from a XML server probably within a pipeline.  What I have at
 present is a backend XML server that given a XML formatted packet does some
 processing, including database access, legacy etc. then replies with an
 answer XML packet.  This is totally outside of Cocoon.
 
 What I have inside Cocoon at present is an html form that has the request
 parameters that would make up the inwards XML packet.  I have a pipeline
 that has a request generator, then a xslt transformation to get the XML into
 the required format.  What I would like to do is post this packet to the XML
 server, with the reply packet being available to the pipeline, maybe a
 transformer that changes the input XML to the output via the post.  Then
 process this reply XML packet to create the next HTML page.
 
 If anyone has any help on this, or can think of a better way this could be
 performed your help would be greatly appreciated.
 
 Cheers
 Bryce
 
 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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