LogoLogo
  • Go to Docs Center
  • Plum DEV Documentation
  • Overview
  • Developer Reference
    • Tutorial
    • How to...
      • Use Plum's Transcription API
    • Audio Formats and Prompts
    • Grammars and Speech Recognition
    • Available ASR Engines
    • TTS Engine Characteristics
      • Amazon Polly TTS Engine
        • Polly Voice Tag Attribute Details
      • AT&T Natural Voices
      • Cepstral Engine
      • RealSpeak Engine
      • Vocalizer 7
        • Vocalizer 7: <voice> tag and SSML Support
    • Data Exchange
    • Logging
    • Caching
    • Root Documents
  • VoiceXML
    • Tags
      • <assign>
      • <audio>
      • <block>
      • <break>
      • <catch>
      • <choice>
      • <clear>
      • <data>
      • <desc>
      • <disconnect>
      • <else>
      • <elseif>
      • <emphasis>
      • <enumerate>
      • <error>
      • <example>
      • <exit>
      • <field>
      • <filled>
      • <foreach>
      • <form>
      • <goto>
      • <grammar>
      • <help>
      • <if>
      • <initial>
      • <item>
      • <lexicon>
      • <link>
      • <log>
      • <mark>
      • <menu>
      • <meta>
      • <metadata>
      • <noinput>
      • <nomatch>
      • <one-of>
      • <option>
      • <paragraph>
      • <param>
      • <phoneme>
      • <prompt>
      • <property>
      • <prosody>
      • <record>
      • <reprompt>
      • <return>
      • <rule>
      • <ruleref>
      • <say-as>
      • <script>
      • <sentence>
      • <speak>
      • <sub>
      • <subdialog>
      • <submit>
      • <tag>
      • <throw>
      • <token>
      • <transfer>
      • <value>
      • <var>
      • <voice>
      • <vxml>
    • Properties
      • audiofetchhint
      • audiomaxage
      • audiomaxstale
      • bargein
      • bargeintype
      • certverifypeer
      • completetimeout
      • confidencelevel
      • datafetchhint
      • datamaxage
      • datamaxstale
      • documentfetchhint
      • documentmaxage
      • documentmaxstale
      • fetchaudio
      • fetchaudiodelay
      • fetchaudiominimum
      • fetchtimeout
      • grammarfetchhint
      • grammarmaxage
      • grammarmaxstale
      • incompletetimeout
      • inputmodes
      • interdigittimeout
      • logging
      • maxnbest
      • maxspeechtimeout
      • normalizeaudio
      • recordcall
      • recordcallappend
      • recordutterance
      • recordutterancetype
      • scriptfetchhint
      • scriptmaxage
      • scriptmaxstale
      • sensitivity
      • speedvsaccuracy
      • termchar
      • termmaxdigits
      • termtimeout
      • timeout
      • universals
      • voicegender
      • voicename
    • Application and Session Variables
      • application.lastresult$[i].confidence
      • application.lastresult$[i].inputmode
      • application.lastresult$[i].interpretation
      • application.lastresult$[i].recording
      • application.lastresult$[i].recordingduration
      • application.lastresult$[i].recordingsize
      • application.lastresult$[i].utterance
      • session.callrecording
      • session.id
      • session.telephone.ani
      • session.telephone.dnis
    • VoiceXML Resources
  • Plum DEV Guide
    • Using the Plum DEV site
    • Using the File Repository
    • Outbound Calling Guide
      • Using the Outbound Tools in the DEV web UI
      • DEV Outbound Programming Notes
      • Outbound FAQs and Tips
    • Call Reporting
    • Analytics
    • VoiceTrends
    • Debugging
    • Scratchpads
    • Saved URLs
    • Voice Biometrics
    • Call Routing
    • Data Security
      • 'Private' Tags
      • Managing Secure Phone Numbers
      • Sensitive Data Types
    • SMS Guide
      • Standard Short Codes
      • SMS Debugging/Error Logs
      • Additional SMS Info
    • Single Sign On
  • Plum DEV APIs
    • DEV Outbound APIs
      • Contacts CSV Formatting
      • Outbound API Parameter Notes
      • Legacy and Miscellaneous Notes
    • SMS API
    • Call Logs API
    • Call Scheduling and Pacing API
    • Transcription API
    • Application API
    • Blocklist API
Powered by GitBook
On this page
  • <goto>
  • Attributes
  • Notes
  • Example
  • Child Tags
  • Parent Tags
  1. VoiceXML
  2. Tags

<goto>

<goto>

The <goto> element is used to:

  • Transition to another form item in the current form.

  • Transition to another dialog in the current document.

  • Transition to another document.

Attributes

Name
Data type
Description

fetchhint

This attribute is not supported.

fetchtimeout

String

(defaults to “fetchtimeout” global property value) The timeout for fetches. Must be specified with the appropriate time units (e.g., “120s” for 120 seconds).

maxage

String

(defaults to “documentmaxage” global property value) Tells the platform the maximum acceptable age, in seconds, of cached documents.

maxstale

String

(defaults to “documentmaxstale” global property value) Tells the platform the maximum acceptable staleness, in seconds, of expired cached documents.

next

String

The URI to which to transition.

expr

String

An ECMAScript expression that yields the URI.

fetchaudio

String

(defaults to “fetchaudio” global property value) The URI of the audio clip to play while the fetch is being done.

expritem

String

An ECMAScript expression that yields the name of the next form item to visit.

nextitem

String

The name of the next form item to visit in the current form.

Notes

Exactly one of “next”, “expr”, “nextitem”, and “expritem” must be specified.

Example

gotoexample.php

<?php
header("Content-type: text/xml");
echo "<?xml version=\"1.0\"?>\n";
?>
<vxml version="2.0">
  <form id="firstform">
    <block>
      <prompt>
        Jumping to the third form.
      </prompt>
      <!-- A "#" symbol followed by an identifier specifies a -->
      <!-- form or menu ID to jump to. -->
      <goto next="#thirdform"/>
    </block>
  </form>
  <form id="secondform">
    <block>
      <prompt>
        Now jumping to another document.
      </prompt>
      <goto next="newdocument.php"/>
      <disconnect/>
    </block>
  </form>
  <form id="thirdform">
    <field name="firstfield">
    <grammar type="application/x-jsgf">
      1 | 2
    </grammar>
      <prompt>
        Enter 1 to go to the next field. Enter 2 to go to the next form.
      </prompt>
    <filled>
      <if cond="firstfield==1">
        <prompt>
          Jumping to the next field.
        </prompt>
        <goto nextitem="secondfield"/>
      <else/>
        <prompt>
          Jumping to the next form.
        </prompt>
        <goto next="#secondform"/>
      </if>
    </filled>
    </field>
    <field name="secondfield">
    <grammar type="application/x-jsgf">
      1
    </grammar>
      <prompt>
        Enter 1 to go to the next form.
      </prompt>
    <filled>
      <prompt>
        Now jumping to the next form.
      </prompt>
      <goto next="#secondform"/>
    </filled>
    </field>
  </form>
</vxml>
<?php
header("Content-type: text/xml");
echo("<?xml version=\"1.0\"?>\n");
?>
<vxml version="2.0">
  <form id="main">
    <block>
      <prompt>
        This is a new document.
      </prompt>
    </block>
  </form> 
</vxml>

The output of the above script would be:

Computer: Jumping to the third form. Computer: Enter 1 to go to the next field. Enter 2 to go to the next form. Human: (enters DTMF-1) Computer: Jumping to the next field. Computer: Enter 1 to go to the next form. Human: (enters DTMF-1) Computer: Now jumping to the next form. Computer: Now jumping to another document. Computer: This is a new document.

Child Tags

None

Parent Tags

Previous<form>Next<grammar>

Last updated 1 year ago

, , , , , , , ,

<block>
<catch>
<error>
<filled>
<foreach>
<help>
<if>
<noinput>
<nomatch>