[asterisk-users] phpagi problem

Mauricio Mantilla mauriciomantilla at gmail.com
Tue Jul 18 14:21:07 MST 2006


Yeah, I wrote it on a different file and it worked, i guess there was some
hidden character in the script that was messing it up.
Thank you anyway,

Mauricio Mantilla

On 7/17/06, Time Bandit <timebandit001 at gmail.com> wrote:
>
> > #!/usr/bin/php -q
> >  <?php
> > require('/var/lib/asterisk/agi-bin/phpagi.php');
> > $agi = new AGI();
> > $agi->say_digits(62410);
> > $cid = $agi->get_variable("dir");
> > $agi->say_digits($cid);
> >  ?>
> >
> >
> > I'm getting this error:
> >
> > parse error, unexpected '=' on line 6
>
> I don't know why you're getting this error, it parse correctly here.
>
> But one thing is that the line "$agi->say_digits($cid);" won't work.
> When you do a get_variable, the result you get is an array, and the
> member holding the value is 'data'. So you have to write your line
> like this : $agi->say_digits($cid['data']);
>
> Check the documentation : http://phpagi.sourceforge.net/phpagi2/docs/
>
> hth
> _______________________________________________
> --Bandwidth and Colocation provided by Easynews.com --
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060718/a0548501/attachment.htm


More information about the asterisk-users mailing list