1

I got'we are sorry an application error has occurred' when I add a action attribute to dial verb, and it's working fine without the action attribute

Below is the working code :

<?php
header("content-type: text/xml");
echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n";
?>
<Response>
<Say voice="alice">Hello Client, your Call will forwarded to Psychic, Please Wait ..</Say>
 <Dial>
    +91-8086699702
</Dial>
<Say>I am unreachable</Say>

And below is the code I got the error,

<?php
header("content-type: text/xml");
echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n";
?>
<Response>
<Say voice="alice">Hello Client, your Call will forwarded to Psychic, Please Wait ..</Say>
 <Dial action='http://demo.wdstech.com/wds5/psychicwiz/dialcallback.php' >
    +91-8086699702
</Dial>
<Say>I am unreachable</Say>

I don't know why the error is occured when I add the action attribute, Pls help what's wrong in my code ..?

1 Answers1

2

can you please show the code of http://demo.wdstech.com/wds5/psychicwiz/dialcallback.php

this php page might not be in the proper xml format

Digant Shah
  • 131
  • 6
  • Should the code 'dialcallback.php' in XML format ? I think twilio will not process the code as twiml, Is just the callback , Isn't it ..? – Arun Wilson Dec 08 '15 at 12:32
  • yes its just call back but it should be in proper XML format to hangup the call, if call is not properly hang up or xml is not in proper format it will give error – Digant Shah Dec 08 '15 at 13:11