Results 1 to 4 of 4

Thread: non xml?

  1. #1

    Post non xml?

    Hi,

    I new to the scripting game, and Ive come across a problem with my XML.

    I initially only had mainform (stolen out the manual im afraid) and that worked perfectly.

    I added a datetime form, and now it wont upload to the PABX..

    My script is below:

    <vxml version="2.0">
    <var name="working_hours" expr="'0'"/>
    <var name="working_days" expr="'0'"/>
    <form id="datetimeform">
    <object name="field1" classid="datetime">
    <filled>
    <if cond="datetime_wday &gt; '1'">
    <if cond="datetime_wday &lt; '7'">
    <assign name="working_days" expr="'1'"/>
    </if>
    </if>
    <if cond="working_days == '1'">
    <if cond="datetime_hour &lt; '8'">
    <elseif cond="datetime_hour &lt; '17'"/>
    <assign name="working_hours" expr="'1'"/>
    <else/>
    </if>
    </if>
    <if cond="working_hours" == '1'">
    <if cond="datetime_hour == '8'">
    <if cond="datetime_min &lt; '25">
    <assign name="working_hours" expr="'0'"/>
    </if>
    </if>
    </if>
    <if cond="working_hours =='1'">
    <goto next="#mainform"/>
    <else/>
    <prompt>
    <audio src="enet_welcome.wav"/>
    <audio src="enet_outoffice.wav" />
    </prompt>
    </if>
    <exit/>
    </filled>
    </object>
    </form>
    <form id="mainform">
    <noinput count="1">
    <assign name="field1" expr="'82'"/>
    <goto nextitem="field2" />
    </noinput>
    <block>
    <prompt bargein="true">
    <audio src="enet_welcome.wav"/>
    </prompt>
    <goto nextitem="field1"/>
    </block>
    <field name="field1" type="digits?length=1" modal="false">
    <prompt timeout="5s">
    <audio src="enet_salesaccounts.wav"/>
    </prompt>
    <option dtmf="1" value="82"/>
    <option dtmf="2" value="80"/>
    <option dtmf="0" value="10"/>
    <filled>
    <goto nextitem="field2"/>
    </filled>
    </field>
    <object name="field2" classid="connect">
    <param name="extension" expr="field1"/>
    <filled>
    <prompt>
    <audio src="timeover.wav"/>
    </prompt>
    <exit/>
    </filled>
    <nomatch>
    <goto nextitem="field1"/>
    </nomatch>
    </object>
    </form>
    </vxml>

    Any ideas?

  2. #2

    Default

    To Clarify my objective:

    every call will get checked for Date and Time (Only open Mon - Fri 8:30am - 5pm)

    Once checked, call gets sent to second form (Mainform) which will ask for dept, etc.

    Mainform worked by itself, however when I added the Dateform the PABX give me the 'invalid XML' error.

  3. #3

    Default

    <if cond="working_hours" == '1'">

    Highlighted in red might be the culprit ... My xml writer/editor tells me that is the problem...


    Regards

    Kevin

  4. #4

    Default

    ah! thanks it was my comments. Sorted it out!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •