[prog] Calling a perl program from within PHP

Gareth Anderson somecsstudent at gmail.com
Sat Nov 13 20:07:47 EST 2004


Thanks, it ended up as:

<?php

$arr = array("testname", "submit");
foreach ($arr as $key)
{
  print "$key -> $_POST[$key] <BR>";
}
?>

Although that's not 100% correct.

Yes, I did get the value from the textbox.

My code does appear to have attached in my gmail account, maybe the
list didn't like it.

Anyway, since my code did work on  a real server, I'm waiting till
Monday when I should have an account to test it on.

Probably the server I downloaded may have a configuration error or I'm
just doing something wrong.

Thankyou very much for your help.

system();

Works perfectly, although I have to remove the Content-type:
"text/html" from the perl files (as it shows up as text in the HTML
documents).

So using system() does pass on the standard output (and I assume input etc.).

I'll post a link to the site and source code once I've finished in
case anyone is interested in how it works (note, its not designed to
be high quality code, just to work :) ).

Regards,
Gareth

Oh and sorry for sending you 2 copies of the message Jacinta.


More information about the Programming mailing list