Page 1 of 1

Application attribute in vxml tag

Posted: Thu Nov 06, 2008 5:31 pm
by sbaraian
Can i use different files in the application attribute of the vxml tag? something like:

<vxml version="2.0" application="root.aspx?id=1">

thanx

Able to use different files in IVR app attribute of vxml tag

Posted: Thu Nov 06, 2008 5:49 pm
by support
Hi,

Yes, it is possible to use different files in the IVR application attribute of the <vxml> tag. For IVR example:

Root.php:

Code: Select all

<?php
header("Content-type: text/xml");
echo("<?xml version=\"1.0\"?>\n");
?>
<vxml version="2.0">
  <var name="username"/>
  <var name="age"/>

  <property name="interdigittimeout" value="3s"/>

  <catch event="noinput">
    Please enter an input.
  </catch>
  <catch event="nomatch">
    Your input does not make sense.
  </catch>
</vxml>
Page1.vxml:

Code: Select all

<?xml version="1.0"?>
<vxml version="2.0" application="Root.php">
  <form>
    <block>
      <assign name="username" expr="'Big Dog'"/>
    </block>
    <field name="userage" type="digits">
      <prompt>
        <value expr="username"/>,
        please enter the digits of your age.
      </prompt>
      <filled>
        You entered <value expr="userage"/>.
        <assign name="age" expr="userage"/>
        <goto next="Page2.vxml"/>
      </filled>
    </field>
  </form>
</vxml>
Page2.vxml:

Code: Select all

<?xml version="1.0"?>
<vxml version="2.0" application="Root.php">
   <form>
      <block>
         <prompt bargein="false">
            Your name is <value expr="username"/>.
            Your age is <value expr="age"/>.
         </prompt>
      </block>
   </form>
</vxml>
Hope this helps.

Regards,
Plum Support