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

External Grammar tweak

Questions and answers about IVR programming for Plum DEV

Moderators: admin, support

Post Reply
Posts: 3632
Joined: Mon Jun 02, 2003 3:47 pm
Location: Boston, MA

Re: External Grammar tweak

Post by support »

There's no fix for this in the grammar file. Before assigning your digits to a variable, you'll have to use Javascript to remove the spaces. For example:

Code: Select all

  <field name="digits">
    <!-- Your external grammar -->
    <prompt>Your prompt</prompt>

       <assign name="digits_without_spaces" expr="digits.replace(/ /g, '')"/>
The Javascript inside the expr attribute takes the input from the "digits" field and replaces all spaces with empty strings.

Post Reply