1. No, Plumvoice won't read my XML. Rather, what I meant by "working flawlessly" is parts unrelated to Plumvoice. What's working is my own script's processing of the POST data sent, including two user-keyed DTMF strings, session.id, session.telephone.ani & session.telephone.dnis. My script catches the info, but I seem to be unable to return valid XML that Plumvoice will read. The moment my VXML script reaches the <submit> or <data> tag, and I get error.badfetch.
2. Serious Error of type error.badfetch. I heard a semantic error at one point, but that hasn't repeated.
3. pin_handler.php returns VXML, per the below example of what the script echoes, but only because I'm under the impression that it has to.
4. Yes. That's the code echoed by pin_handler.php (repeated below more completely).
5. Yes. I'll need to send binary data. Ultimately (once I can make the simple stuff work, I plan to <record> and submit the files along with the other POST data. Ideally, it would be nice if the same script could handle it, but if it's better to use a different one, I can do that. Is that what you're getting at?
Incidentally, the error noted below isn't accurate, since the name attribute IS set for the <form> mentioned. Unless I'm missing something.
-- Daniel
Here's pin_handler.php (first two lines are echoed from the PHP section of the file, if that matters).
Code: Select all
<?xml version="1.0"?>
<!DOCTYPE vxml PUBLIC "-//W3C//DTD VOICEXML 2.1//EN" "http://www.w3.org/TR/2007/REC-voicexml21-20070619/vxml.dtd">
<vxml version="2.1">
<block name="final">
<prompt name="end" bargein="true">
Thank you. Goodbye.
</prompt>
</block>
</vxml>
Here's the error log:
Code: Select all
Thu 25 Jul 2013 10:54:07 PM EDT:
Call Start Event: ANII 9419625605 DNIS 3999 VURL http://us.popproxy.plumgroup.com/plumvp/demo.php
DocumentParser::FetchDocument()
Fetching Document: http://us.popproxy.plumgroup.com/plumvp/demo.php
DocumentParser::FetchDocument(http://us.popproxy.plumgroup.com/plumvp/demo.php)
Cache Miss: http://us.popproxy.plumgroup.com/plumvp/demo.php
Attempting to fetch http://us.popproxy.plumgroup.com/plumvp/demo.php
Loading Builtin grammar: builtin:grammar/digits
Loading Builtin grammar: builtin:dtmf/digits
Entering form = '$_internalName_1661680' form item = 'ext'
VXI::queue_prompts()
bargein set to true
INPUTMODES set to "DTMF VOICE"
Cache Hit: http://us.popproxy.plumgroup.com/plumvp/audio/demo.wav
Audio segment from the URL audio/demo.wav added to prompt queue
VXI::field_element - activating grammars for form = '$_internalName_1661680' formitem = 'ext'
VXI::do_recognition()
PromptManager::Play()
starting playback: bargein=true, inputmodes="dtmf speech"
Newly queued prompts are now being played
Thu 25 Jul 2013 10:54:12 PM EDT:
dtmf input: 1168
Found grammar match
hypothesis #0: 1168 (0.9990)
VXI::var_element(name="session_id" expr = "session.id")
VXI::var_element(name="dnis" expr = "session.telephone.dnis")
Fetching Document: demo.php
DocumentParser::FetchDocument(demo.php)
Posted form data is URL encoded
Attempting to fetch http://us.popproxy.plumgroup.com/plumvp/demo.php
Entering form = '$_internalName_1661684' form item = '$_internalName_1661685'
Fetching Document: scratchpad.php/d.benjamin%40eshlepper.com/Test+2+%28pin_handler.php+redirects+to+local+file+end.xml%29
DocumentParser::FetchDocument(scratchpad.php/d.benjamin%40eshlepper.com/Test+2+%28pin_handler.php+redirects+to+local+file+end.xml%29)
Cache Miss: http://us.popproxy.plumgroup.com/plumvp/scratchpad.php/d.benjamin%40eshlepper.com/Test+2+%28pin_handler.php+redirects+to+local+file+end.xml%29
Attempting to fetch http://us.popproxy.plumgroup.com/plumvp/scratchpad.php/d.benjamin%40eshlepper.com/Test+2+%28pin_handler.php+redirects+to+local+file+end.xml%29
Thu 25 Jul 2013 10:54:13 PM EDT:
Loading Builtin grammar: builtin:dtmf/digits?length=12
Loading Builtin grammar: builtin:dtmf/phone
Entering form = '$_internalName_1661687' form item = 'pin'
VXI::queue_prompts()
bargein set to false
INPUTMODES set to "DTMF"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>
Thank you for calling. Please enter the pin code from your mail piece.
</speak>
---------
starting playback: bargein=false, inputmodes="dtmf"
Newly queued prompts are now being played
VXI::field_element - activating grammars for form = '$_internalName_1661687' formitem = 'pin'
VXI::do_recognition()
PromptManager::Play()
Thu 25 Jul 2013 10:54:26 PM EDT:
dtmf input: 103201000715
Found grammar match
hypothesis #0: 103201000715 (0.9990)
Entering form = '$_internalName_1661687' form item = 'callback_phone'
VXI::queue_prompts()
bargein set to true
INPUTMODES set to "DTMF"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>
Please enter a good callback number for our representative to reach you.
</speak>
---------
VXI::field_element - activating grammars for form = '$_internalName_1661687' formitem = 'callback_phone'
VXI::do_recognition()
PromptManager::Play()
starting playback: bargein=true, inputmodes="dtmf"
Newly queued prompts are now being played
Thu 25 Jul 2013 10:54:33 PM EDT:
dtmf input: 8
received event: nomatch:
bargein set to true
INPUTMODES set to "DTMF"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>
That's not a valid phone number. Be sure to enter a full 10 digits phone number now. Please try again.
</speak>
---------
Entering form = '$_internalName_1661687' form item = 'callback_phone'
VXI::queue_prompts()
bargein set to true
INPUTMODES set to "DTMF"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>
Please enter a good callback number for our representative to reach you.
</speak>
---------
VXI::field_element - activating grammars for form = '$_internalName_1661687' formitem = 'callback_phone'
VXI::do_recognition()
PromptManager::Play()
starting playback: bargein=true, inputmodes="dtmf"
Newly queued prompts are now being played
Thu 25 Jul 2013 10:54:39 PM EDT:
dtmf input: 34562365
received event: nomatch:
bargein set to true
INPUTMODES set to "DTMF"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>
That's not a valid phone number. Be sure to enter a full 10 digits phone number now. Please try again.
</speak>
---------
Entering form = '$_internalName_1661687' form item = 'callback_phone'
VXI::queue_prompts()
bargein set to true
INPUTMODES set to "DTMF"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>
Please enter a good callback number for our representative to reach you.
</speak>
---------
VXI::field_element - activating grammars for form = '$_internalName_1661687' formitem = 'callback_phone'
VXI::do_recognition()
PromptManager::Play()
starting playback: bargein=true, inputmodes="dtmf"
Newly queued prompts are now being played
Thu 25 Jul 2013 10:55:01 PM EDT:
dtmf input: 3107895632
Found grammar match
hypothesis #0: 3107895632 (0.9990)
Entering form = '$_internalName_1661687' form item = '$_internalName_1661688'
VXI::var_element(name="session_id" expr = "")
VXI::assign_element(name="session_id" expr = "session.id")
VXI::var_element(name="cid" expr = "")
VXI::assign_element(name="cid" expr = "session.telephone.ani")
VXI::var_element(name="dnis" expr = "")
VXI::assign_element(name="dnis" expr = "session.telephone.dnis")
Fetching Document: http://www.mysite.com/ivr/pin_handler.php
DocumentParser::FetchDocument(http://www.mysite.com/ivr/pin_handler.php)
Posted form data is URL encoded
Attempting to fetch http://www.mysite.com/ivr/pin_handler.php
[b][color=#FF0000]DocumentParser::FetchDocument - Parse error in file "http://www.mysite.com/ivr/pin_handler.php", line 5, column 22 - Attribute 'name' is not declared for element 'prompt'
errno: 205 uri http://www.mysite.com/ivr/pin_handler.php
received event: error.badfetch: [/color][/b]
bargein set to true
INPUTMODES set to "DTMF"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>
A serious error of type </speak>
---------
bargein set to true
INPUTMODES set to "DTMF"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>error.badfetch</speak>
---------
bargein set to true
INPUTMODES set to "DTMF"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak> has occurred. Exiting. </speak>
---------
VXI::exit_element()
starting playback: bargein=true, inputmodes="dtmf"
Newly queued prompts are now being played
Thu 25 Jul 2013 10:55:07 PM EDT:
Call End Event
Ending session
Ending Session On Channel 2