FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » php exec http url
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
php exec http url [message #185182] Thu, 06 March 2014 20:42 Go to previous message
bishop2001 is currently offline  bishop2001
Messages: 1
Registered: March 2014
Karma:
Junior Member
Greetings,
I am trying to execute a shell script which is residing on a webserver on a remote machine with no luck. I have tried the following. It looks like it runs but I never see the output from the script on machine2. Any suggestions. Thanks,

from machine 1:
echo exec('http://machine2/script.sh);

and

from machine1:
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "http://machine2/script.sh");
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_exec($ch);
curl_close($ch);
?>
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Experienced Web designer required
Next Topic: When a random file is not found then what?
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Thu Nov 21 17:01:36 GMT 2024

Total time taken to generate the page: 0.03239 seconds