I am trying to call the text browser lynx from inside a perl script using the -source option in order to grab the output (HTML code) and append it to a file... however, it just will not work when I call it from the web... it only works if I call it directly from the command line (if I have a one-line script with almost exactly the same line. I've tried changing permissions on the script, etc. to rwx by world and several variations of the call, but no to no avail. Ideally, this will take a URL from a form via POST and then go grab the source code and keep it in a file. Any ideas how I can implement this? There must be a way without using sockets since a similar script works with an exact call when executed from the command line. (Also, I'm using HP-UX).
The line is:
system "lynx $link -source >> megafile.spd\n";
where "$link" is a URL received from the POST method.