struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alain Van Vyve <Alain.VanV...@brussels.sema.slb.com>
Subject RE: Calling CGI script
Date Thu, 15 Apr 2004 08:18:49 GMT

In fact, the problem I forgot to mention is that this CGI script will 
himself contact the banking site responsible of a payment
and present an HTML page to the end-user ...

What do I have to do in my action ? because my action needs an 
ActionForward return value ...

I think the solution should be to forward to something 
like     .../cgi-bin/myscript?arg1=value1

Tomcat will then recognize the URL pattern cgi-bin and execute the script 
located in WEB-INF/cgi

So my problem is to find code sample in order to forward to this kind of URL
I cannot put this url in my struts-config.xml action mapping because I have 
parameters to pass

Thank's again


At 14/04/2004 18:08, you wrote:
>I had a similar problem once, an action needing to call a client's NT
>executable to generate a file to be emailed to someone. This isn't
>really a struts problem though.
>
>CGI only means it's an application that takes it parameters on the
>command line and prints whatever it wants to be displayed in the
>browser, so it shouldn't be incredibly tough to call the script.
>
>You could put it on some hidden/secure place on your web server, and
>make your own properly formed http call to it from your action.
>
>If making an http call to an app that technically doesn't need http to
>work offends you, you can probably call it directly with the Runtime
>class, but at that moment, you've made yourself dependent on your
>underlying OS.
>
>HTH
>
>-Joe
>
> > -----Original Message-----
> > From: Alain Van Vyve [mailto:Alain.VanVyve@brussels.sema.slb.com]
> > Sent: Wednesday, April 14, 2004 9:48 AM
> > To: Struts Users Mailing List
> > Subject: Calling CGI script
> >
> >
> >
> > My application is using Struts in a Tomcat 4.1.29
> > environment. I'm in a situation where an Action has to call a
> > CGI script that will be
> > responsible to initiate a payment process (third party)
> >
> > I have  found the way how to modify my Tomcat environment ...
> > that's not
> > the issue !
> > My problem is : How can I call a cgi script in my action ?
> >
> > Thank's
> >
> > Alain
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> > For additional commands, e-mail: user-help@struts.apache.org
> >
> >
> >
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
>For additional commands, e-mail: user-help@struts.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message