Plum DEV Documentation

This is an old revision of the document!


The <assign> element assigns a value to a predefined variable.


name The name of the variable being assigned to.
expr An ECMAscript expression to be evaluated, the results of which are assigned to the named variable.


The variable specified by the “name” attribute in the <assign> tag should be declared in a <var> tag first.


<?xml version="1.0"?>
<vxml version="2.0">
    <!-- test_var is declared here -->
    <var name="test_var"/>
      <!-- test_var must be declared before assigning it a value -->
      <assign name="test_var" expr="1234"/>
        The test variable is set to <value expr="test_var"/>.

The output of the above script would be:

Computer: The test variable is set to twelve hundred thirty-four.

Child Tags


Parent Tags