CCXML 1.0-W3C Development GuideHome  |  Frameset Home


<log>  element

The log element allows the developer to output debug messages to the Voxeo Logger. Generous use of log statements placed within code can greatly assist when tracking variable values, and errors that occur in the application.


usage
<log expr="(ECMAScript Expression)" label="(ECMAScript Expression)">


attributes
exprData Type: (ECMAScript Expression)Default: none - attribute is required
The expr attribute is a required parameter for the <log> element that is an ECMAscript expression evaluating to a string to be logged. This string will be output in the Voxeo Realtime Logger when the <log> element is encountered.
labelData Type: (ECMAScript Expression)Default: none - attribute is optional
Not Enabled
The label attribute is an ECMAScript expression that returns a character string which is used as an identifier, or 'marker' indicating the reason for the <log> statement.



parents
none


children
none


code samples
<1.0 log -expr>
<?xml version="1.0" encoding="UTF-8"?>
<ccxml version="1.0" xmlns="http://www.w3.org/2002/09/ccxml">

  <var name="BenFranklin"
      expr="'When the people find that they can vote themselves money, that will herald the end of the republic.'"/>


  <eventprocessor>
  <transition event="connection.alerting">
    <accept/>
    <log expr="'***** CALL ACCEPTED *****'"/>
  </transition>

  <transition event="connection.connected">
    <log expr="'*** BEN FRANKLIN SAYS: ' + BenFranklin"/>
    <exit/>
  </transition>


  <transition event="error.*">
    <log expr="'ERROR OCCURRED: '+ event$.name"/>
    <exit/>
  </transition>
</eventprocessor>

</ccxml>



additional links
W3C Specification


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

login



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