On Sat, May 09, 2009 at 10:17:27AM +0530, Sam Hawkin wrote:
> Hi All,
>
> I am trying to run the asterisk CLI commands from php.
> Some thing like "asterisk -rx reload".
> But it is not working, where as when I try to run
> linux "ls" command it works fine.
>
> below is sample php code which I am trying to run.
>
> $command = "sudo asterisk -rx reload";
>
> $value1 = system($command,$retval1);
> $value2 = exec($command,$retval2);
>
> echo $value1;
> echo $value2;
>
> can any one suggest what might be the problem and possible solution to it.
Yes. What error do you actually get? You need to get stderr from hte
command as well for that.
What version of Asterisk do you use, BTW?
--
Tzafrir Cohen
icq#16849755 jabber:[email protected]
+972-50-7952406 mailto:[email protected]
http://www.xorcom.com iax:[email protected]/tzafrir
_______________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users