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

Digits length

Questions and answers about IVR programming for Plum DEV

Moderators: admin, support

Post Reply
aliasg
Posts: 24
Joined: Sat Mar 14, 2009 1:23 am

Digits length

Post by aliasg »

Hi,

I am using

Code: Select all

 <field name="iCardNumber" type="digits?length=10">
But it also accept 98765432103210 as 9876543210 when entered in flow. I need to get no match event for input of greater than ten digits.

Any help?
Ali

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

IVR example for "termmaxdigits" property

Post by support »

Hi,

We would need to see more IVR code in context in order to understand this IVR issue you are experiencing.

Do you have an termmaxdigits property set to "true" within your IVR code? If so, then as soon as you've entered 10 digits for your field, there will be an immediate timeout on the entry of digits.

The following IVR example demonstrates this:

termmaxdigits.php:

Code: Select all

<?php
header("Content-type: text/xml");
echo("<?xml version=\"1.0\"?>\n");
?>
<vxml version="2.0">
<property name="inputmodes" value="dtmf"/>
<property name="termmaxdigits" value="true"/>
<property name="interdigittimeout" value="5s"/>
  <form>
    <field name="myfield" type="digits?length=10">
      <prompt>
        Enter up to ten digits.
      </prompt>
      <filled>
        <prompt bargein="false">
          You entered <value expr="myfield"/>.
        </prompt>
      </filled>
      <nomatch>
        You did not enter enough digits.
        <reprompt/>
      </nomatch>
      <noinput>
        You did not enter anything.
        <reprompt/>
      </noinput>
    </field>
  </form>
</vxml>
From this IVR example, if you enter more than 10 digits, there will be no chance for a nomatch even from occurring because the application will just take the first 10 digits that were entered due to the "termmaxdigits" property.

Hope this clarifies things.

Regards,
Plum Support

Post Reply