I’m coming to the point directly…Actually i’m forwarding the call to another number and before doing that i want to give the options to the caller like 1:to call 2:voicemail and 3:hangup…but i’m not able to get the value from the user.
I’m using asterisk 1.4.24 and phpagi 2.14 and i’m doing all this in a php script. I already used get_data and stream_file functions defined in phpagi but they are not able to get the value given by the user…
please any help or suggestions!!!
thank you for spending your valuable time for me.[/quote]
Hey thanks Macro for ur reply but i got the solution.
$val= $agi->exec(“Background $file”);
where $file is any audio file, so while playing that file if caller presses any key it is accepting and i’m storing that in a variable.$val.
$val=$val[‘result’]; will give u the pressed number…
Thankyou very much[/quote]
Ive done that, and if I:
callblast2-program.php|41283|114: [code] => 200
callblast2-program.php|41283|114: [result] => 0
callblast2-program.php|41283|114: [data] =>
And im pressing 5, not 0.
$keypress = $agi->exec(“Background messagesgsm/176”);
I couldnt get stream_file to even play the file…i seen it had bugs and suggested using the Playback cmd’s…