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

Interdigittimeout problem with key pound

Questions and answers about IVR programming for Plum DEV

Moderators: admin, support

Post Reply
soso
Posts: 62
Joined: Tue Apr 22, 2008 8:11 am

Interdigittimeout problem with key pound

Post by soso »

Hi,

I've always a problem with the key pound.

I've this code:

Code: Select all

<form id="main">
   <field name="msg">
        
            <property name="inputmodes"        value="dtmf" />
            <property name="termchar"          value="" />
            <property name="interdigittimeout" value="20s" />
            <property name="termtimeout"       value="0s" />
            
            <prompt>
                <audio expr="media_message">
                </audio>
            </prompt>
            
            <grammar root="ROOT" type="application/srgs+xml" mode="dtmf"> 
                <rule id="ROOT" scope="public"> 
                    <one-of> 
                        <item repeat="0-255"> 
                            <ruleref uri="#digit"/> 
                        </item>
                        <item> "#" </item> 
                    </one-of> 
                </rule> 

                <rule id="digit" scope="public"> 
                    <one-of> 
                        <item> 0 </item> 
                        <item> 1 </item> 
                        <item> 2 </item> 
                        <item> 3 </item> 
                        <item> 4 </item> 
                        <item> 5 </item> 
                        <item> 6 </item> 
                        <item> 7 </item> 
                        <item> 8 </item> 
                        <item> 9 </item>            
                        <item> "#" </item>                         
                    </one-of> 
                </rule> 
            </grammar>
            
            <filled>            
                <if cond="msg$.utterance.length > longueur_max">
                    <audio expr="nom_media" />
                    
                    <if cond="try==2">
                        <audio src="media/sorry.wav" />                        
                        <goto next="#fin" />
                    <else />
                        <assign name="try" expr="try+1" />
                        
                        <clear namelist="msg" />
                        <reprompt />                    
                    </if>
                <elseif cond="msg=='#'" />
                
                    <if cond="rds==true">
                        <audio src="media/au_moins1_chiffre.wav" />
                                
                        <throw event="nomatch" />
                    <else />
                        <goto next="#form2" />
                    </if>
                <else />                
                    <if cond="msg.indexOf('#') != -1">
                        <submit next="#confirm_msg" namelist="msg" />
                    <else />
                        <throw event="nomatch" />
                    </if>
                </if>
            </filled>
            
            <noinput>
                <assign name="try" expr="try+1" />
                <if cond="try==2">
                    <audio src="media/sorry_mais.wav" />    
                    <goto next="#end" />
                <else />
                    <clear namelist="msg" /> 
                    <reprompt />
                </if>                
            </noinput>
            
            <nomatch>
                <assign name="try" expr="try+1" />

                <if cond="essai==3">
                    <audio src="media/sorry.wav" />
                    <goto next="#fin" />
                <else />
                    <clear namelist="msg" /> 
                    <reprompt />
                </if>
            </nomatch>
        </field>
    </form>

It's work perfectly except the key pound.

After I input the dtmf for the message, and press key pound, the time left 20s (interdigittimeout).

I would like to get the filled section immediately after the key pound with this grammar.

The problem is the termchar property?

Can you help me?

Thanks.

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

IVR code for using pound key for termination

Post by support »

Hi,

The reason why you are experiencing this interdigittimeout after entering the pound key is because your IVR grammar includes the "#" key in it. So, this gets affected by your IVR property, interdigittimeout, of 20s.

As mentioned in a previous post, our IVR platform doesn't support the termchar property, as seen here:
http://www.plumvoice.com/docs/dev/voice ... s:termchar

If you want to use the pound key for termination, you may leave the "#" references out of your grammar, as our platform allows you to use the # key for termination by default.

An IVR code example:

digitentry.vxml:

Code: Select all

<?xml version="1.0"?>
<vxml version="2.0">
  <form>
    <field name="myfield">
      <property name="interdigittimeout" value="20s" /> 
      <grammar type="application/x-jsgf" mode="dtmf">
        ( 1 | 2 )+
      </grammar>
      <prompt>
        Enter any number of the digits one or two.
      </prompt>
      <filled>
        You entered <value expr="myfield"/>.
      </filled>
      <nomatch>
        You did not enter any ones or twos.
        <reprompt/>
      </nomatch>
      <noinput>
        You did not enter anything.
        <reprompt/>
      </noinput>
    </field>
  </form>
</vxml>
If I call into this IVR application and enter "1221#" on my phone keypad, the platform will not wait for the interdigittimeout of 20s because of the pound key termination.

Regards,
Plum Support

Post Reply