new2cgiperl
Programmer
hi,
i'm trying to write a CGI script in perl. in the script i execute another command and capture its output using the backticks as follows:
my @list = `myprogram arg1 arg2`;
i then iterate over the list with a for loop and basically print it out in html so it can be viewed from a browser.
to verify i did this correctly, i ran "perl -w myCgiScript.cgi" which generates the HTML on the unix command line and i have verified that the generated HTML is correct, because first of all, it contains the proper output of the list i am iterating on, and secondly, i copied this generated HTML into a brand new file, and opened it up in IE, and the results are as expected - my list gets displayed on the UI.
However, when I try to reach my CGI script directly with a URL from the IE, I get everything except my list. It is just blank where the list should be. Any ideas as to where I may be going wrong will be helpful. Thanks!
i'm trying to write a CGI script in perl. in the script i execute another command and capture its output using the backticks as follows:
my @list = `myprogram arg1 arg2`;
i then iterate over the list with a for loop and basically print it out in html so it can be viewed from a browser.
to verify i did this correctly, i ran "perl -w myCgiScript.cgi" which generates the HTML on the unix command line and i have verified that the generated HTML is correct, because first of all, it contains the proper output of the list i am iterating on, and secondly, i copied this generated HTML into a brand new file, and opened it up in IE, and the results are as expected - my list gets displayed on the UI.
However, when I try to reach my CGI script directly with a URL from the IE, I get everything except my list. It is just blank where the list should be. Any ideas as to where I may be going wrong will be helpful. Thanks!