Calling a CGI executable from a CGI script

Hi experts,
I have a web page with <FORM action="/cgi-bin/a-cgi...METHOD POST> with lots of data. This a-cgi is an executable file and I have no way to modify it. I however need to add a few more lines to this cgi to prevent my pages, generate from this cgi, from caching. I know about METAs, won't work with IE. I think I can create a new CGI script, add the lines I need and then execute the a-cgi. I tried but it doesnot work!!!
I really appreciate all your helps.
Thanks

Let me explain it a little bit more:
I have a Web application that will require the users to login. when they enter an ID and PW, click on submit button, I will sent a service call the the a-cgi via the <FORM method POST action a-cgi....>
within this form, there are a few
<INPUT TYPE="HIDDEN" NAME="VAR1">
<INPUT TYPE="HIDDEN" NAME="VAR2">
<INPUT TYPE="HIDDEN" NAME="VAR3">

if login is successful, they will be at template page with more options....and so on.
The problem is I can't let them go back to previous page. (security reason) so no-cache is a must. I had META tags in all the templates but they are not working in IE. a-cgi is an executable file and so can't edit that.

A wrapper could easily be produced to do something like the following:

#!/usr/loccal/bin/perl
#
# wrapper - to add no-cache

$oldinput=<STDIN>; #the info that was posted and needs sending
$tempfile="tempfile." . $$; #a temp file where we will keep the posted info
open(FIL,">$tempfile"); #so we can make this available
print FIL $oldinput; #the data that was posted in
close(FIL);
$output=`./yourold.cgi <$tempfile`; #call the old cgi - passing the input
unlink $tempfile; #lets get rid of the temp file, we are done with it
print "Pragma: No-Cache\n"; #disable the cache
print $output; #send the stuff made by the original cgi
exit; #we are all done

maneshr - I do not understand what you are saying - please post an example so we can all see what you are talking about or explain more. Also, please explain what this approach offers that the above one does not.

You see what concerns me is that something needs to call the original cgi, which as was said can not be modified. So, if we make a new cgi that generates a form that then calls this we are introducing an additional http transaction - which would not be good at all.

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

I am missing what you think will not work. All information that is submitted by the form would be available to the original script and also to the script that we have created. Actually the original script will not even know that your new script is there.

Or, are ou saying that the original script generates somethin that needs to be modified too to allow you to intercept the next itteraction as well. If so, then this is easy too since you do have the $output available before sending it back to the browser and can make whatever changes you need to there.

Thanks jhurst, I didn't read your suggestion careful enough that I misunderstood the tempfile is not the template. So whatever the old CGI call it is still there. I will take your answer and give you the points.
Your expertise is greatly appreciate.

Introduction
This tutorial will give you a fast look what you can do with WhizBase. I expect you already know how to work with HTML at least, and that you understand the basics of the internet and how the internet works.
WhizBase is a server-s…

Recently I have been answering a lot of questions like this in IT forums that I frequent. The question posed is usually something along the lines of "We have software X installed and need to uninstall it for reason Y" or some other variant of the sa…

Learn the basics of lists in Python.
Lists, as their name suggests, are a means for ordering and storing values. : Lists are declared using brackets; for example: t = [1, 2, 3]: Lists may contain a mix of data types; for example: t = ['string', 1, T…

The viewer will learn how to create a basic form using some HTML5 and PHP for later processing.
Set up your basic HTML file. Open your form tag and set the method and action attributes.:
(CODE)
Set up your first few inputs one for the name and …