CCXML Voxeo 1.0 Development Guide Home  |  Frameset Home

This documentation is for CCXML 1.0-Voxeo, which has been superceded by CCXML 1.0-W3C. The CCXML-Voxeo platform is not being updated any longer. The CCXML 1.0-W3C version, however, has many new features and is actively being enhanced. If you're writing a new CCXML application, you should use CCXML 1.0-W3C. Click here for the CCXML 1.0-W3C documentation.

<var>  element


The <var> element is used to explicitly declare CCXML variables. All expressions must be valid ECMAScript expressions, assignable to variables with valid ECMAScript names.



usage

<var expr="(ECMAScript Expression)" name="(variable name)">


attributes

expr Data Type: (ECMAScript Expression) Default: none - attribute is required
The expr attribute specifies the value to assign to the variable in question. This may be any valid ECMAScript value.
name Data Type: (variable name) Default: none - attribute is optional
The name attribute indicates the name of the variable. Any valid ECMAScript variable names are permitted as a value for this attribute.



parents

none


children

none


code samples

<Var name-expr> sample
<?xml version="1.0" encoding="UTF-8"?>
<ccxml version="1.0">

  <var name="MyVar" expr="'MyValue'"/>

  <eventhandler>
    <transition event="connection.CONNECTION_ALERTING" name="evt">
      <accept/>
    </transition>

    <transition event="connection.CONNECTION_CONNECTED">
      <log expr="'MyVar = ' + MyVar "/>
      <disconnect/>
    </transition>

    <transition event="call.CALL_INVALID">
      <exit/>
    </transition>

  </eventhandler>
</ccxml>




additional links

W3C Specification


  ANNOTATIONS: EXISTING POSTS
0 posts - click the button below to add a note to this page

login



© 2011 Voxeo Corporation  |  Voxeo IVR  |  VoiceXML & CCXML IVR Developer Site