I have an application that works with Twilio. The idea is that you call the twilio phone number, answer and give you menu options. After you press a number, it will send the message data, and then hang up (this part is working correctly). The problem I ran into is to find out if there is a way to send message data if the user just freezes as soon as twilio answers ... I found the following code in my documentation.
<?xml version="1.0" encoding="UTF-8"?>
<Response>
<Gather action="/process_gather.php" method="GET">
<Say>Enter something, or not</Say>
</Gather>
<Redirect method="GET">
/process_gather.php?Digits=TIMEOUT
</Redirect>
</Response>
The problem with this is that you need to wait until the end of the message to collect before the timeout. Is there a way to do this as soon as it starts, if the user hangs up, he will do something like go to the redirect tag?
Thank!
: , process_gather.php ?
$Completed = $_POST["completed"]; //which would set $Completed == 'completed'
, if (! empty ($ Completed)) -
( , , )