Page 1 of 1

Submitting a recording

Posted: Tue Nov 13, 2007 11:16 am
by mafeldman
I am porting a vxml app from another vendor and I need to submit a recording.

This is the code I'm using:

<var name="gRecording" />
<form id="recordingform" >
<record beep="true" dtmfterm="true" name="Recording" maxtime="20s" type="audio/x-wav">
<property name="timeout" value="5s"/>
<prompt bargein="false"> Start Recording when you hear the beep. Press any key when your are done. </prompt>
</record>
<block>
<assign name="gRecording" expr="Recording" />
<goto next="#nextaction" />
</block>
</form>
<menu id="nextaction">
<prompt bargein="true"> To listen to the message, press 1. To ree reecord, press 2. To accept this message, press 3. </prompt>
<choice dtmf="1" next="#Playback" />
<choice dtmf="2" next="#recordingform" />
<choice dtmf="3" next="#done" />
</menu>
<form id="done">
<block>
<prompt>submitting: <value expr="gRecording"/> </prompt>
<submit expr="'http://xxxxx.biz/Notify/pharmrecordsave2.php?ncpdp='+ ncpdpsave" method="post" namelist="gRecording" enctype="multipart/form-data" />
<disconnect/>
</block>
</form>

Although the prompt "submitting" plays and the submit actually gets to the site, no data is uploaded. It looks like <submit> is not handling the gRecording variable properly. Is there a better way to reference the recording itself?

Thanks,

Mike

IVR code changes to fix data uploads

Posted: Tue Nov 13, 2007 12:30 pm
by support
Hi,

Looking at your IVR code, this line:

Code: Select all

<submit expr="'http://xxxxx.biz/Notify/pharmrecordsave2.php?ncpdp='+ ncpdpsave" method="post" namelist="gRecording" enctype="multipart/form-data" /> 
might be causing the IVR issue due to the mix of GET and POST variables.

We have tested your IVR code and were able to upload the data successfully. The only main differences were in the <submit> line and by changing all the "gRecording" references to "msg" :

Code: Select all

<submit next="http://www.example.com/~victor/save.php" namelist="msg" method="post"/>
Hope this helps.

Regards,
Plum Support

Sample of PHP code needed to debug IVR issue

Posted: Tue Nov 13, 2007 12:34 pm
by support
Also, could you provide us with a small sample of your PHP code that demonstrates the IVR issue? This could possibly help us with debugging this IVR issue.

Regards,
Plum Support

Posted: Tue Nov 13, 2007 1:09 pm
by mafeldman
Removing the GET parameter seemed to do the trick. Thank you for your help.