We've Moved! Please visit our new and improved forum over at our new portal: https://portal.plumvoice.com/hc/en-us/community/topics

Submitting a recording

Questions and answers about IVR programming for Plum DEV

Moderators: admin, support

Post Reply
mafeldman
Posts: 9
Joined: Tue Nov 13, 2007 11:09 am

Submitting a recording

Post 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

support
Posts: 3632
Joined: Mon Jun 02, 2003 3:47 pm
Location: Boston, MA
Contact:

IVR code changes to fix data uploads

Post 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
Last edited by support on Fri Feb 19, 2010 2:19 pm, edited 5 times in total.

support
Posts: 3632
Joined: Mon Jun 02, 2003 3:47 pm
Location: Boston, MA
Contact:

Sample of PHP code needed to debug IVR issue

Post 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
Last edited by support on Fri Feb 19, 2010 2:19 pm, edited 2 times in total.

mafeldman
Posts: 9
Joined: Tue Nov 13, 2007 11:09 am

Post by mafeldman »

Removing the GET parameter seemed to do the trick. Thank you for your help.

Post Reply