How do I access the shadow variables in an input item?

Answers to common Plum DEV questions

Moderators: admin, support

  • Author
  • Message
Offline

support

  • Posts: 3628
  • Joined: Mon Jun 02, 2003 3:47 pm
  • Location: Boston, MA

How do I access the shadow variables in an input item?

PostFri Jun 13, 2003 2:16 pm

Input items (<field> tags, <record> tags, etc.) have an associated set of shadow variables which are used to return results from the execution of the input item (other than the value stored under the input item's name attribute).

A shadow variable is referenced as name$.shadowvar where name is the value of the input item’s name attribute, and shadowvar is the name of a specific shadow variable. E.g. the <record> element's "duration" variable can be accessed thusly:

Code: Select all
<form id="shadowvar_test">
  <record name="foo" beep="true">
    <prompt>
      Please record a message after the tone.
    </prompt>
    <filled>
     <if cond="foo$.duration > 10000">
       Wow, long message!
     </if>
    </filled>
  </record>
</form>

Return to Plum DEV FAQs

Who is online

Users browsing this forum: No registered users and 1 guest

cron