<vxml>

Contains the VoiceXML code of a document.

Syntax

 <vxml
     application="URI"
     xml:base="URI"
     xml:lang="lang"
     version="version_number"
     xmlns="namespace"
     xmlns:bevocal="bvnamespace"
 >
   Child Elements
 </vxml>

Description

Top-level element in each VoiceXML document. Note that in VoiceXML 2.0 the xmlns attribute has been added as a required attribute.

Attribute Description
application

URI of this application's root document. Optional (default is not to have an application root document).

If the specified document also has an application attribute, an error.semantic event is thrown.

xml:base

Base URI. Optional.

xml:lang

New in VoiceXML 2.0. Language and locale for this document. Optional.

The language identifier for this document. A language identifier labels information content as being of a particular human language variant. A legal language identifier is identified by an RFC 3066 code.

BeVocal currently supports English, Spanish, and French Canadian. Valid values are:

 •  en--English
 •  en-US--United States English
 •  es--Spanish
 •  es-US--United States Spanish
 •  fr-ca--French Canadian

The default value is en-US. If an unsupported language is specified, an error.unsupported.language event is thrown.

If your application consists of multiple documents and is using a language other than the default language, each document must specify the xml:lang attribute.

version

VoiceXML version used in this document. The version number must be either 1.0 or 2.0.

xmlns

New in VoiceXML 2.0. The designated namespace for VoiceXML 2.0. The namespace for VoiceXML is defined as http://www.w3.org/2001/vxml; this must be the value of this attribute. Required.

xmlns:bevocal

Extension. Defines the XML namespace bevocal. Optional (default is not to define the namespace).

The only valid value for this attribute is http://www.bevocal.com/.

You must specify this attribute if this document includes any BeVocal VoiceXML extension tags in the bevocal namespace, such as <bevocal:dial>.

(VoiceXML 1.0 only) The following attributes can be used in applications in which the version attribute of the <vxml> tag is set to 1.0.

Attribute Description
lang

VoiceXML 1.0 only. Language and locale for this document. Optional.

This attribute is ignored.

Used in place of the VoiceXML 2.0 xml:lang attribute.

base

VoiceXML 1.0 only. Base URI. Optional.

Usage

Parents Children

None.

<catch>
<data>
<error>
<form>
<help>
<link>
<menu>
<meta>
<metadata>
<noinput>
<nomatch>
<property>
<script>
<var>

See Also

 •  VoiceXML 2.0 Specification: <vxml>

Examples

 <?xml version="1.0" ?>
 <!DOCTYPE vxml PUBLIC "-//BeVocal Inc//VoiceXML 2.0//EN"
  "http://cafe.bevocal.com/libraries/dtd/vxml2-0-bevocal.dtd">
 
 <vxml version="2.0" xmlns="http://www.w3.org/2001/vxml">
   <form id="foo">
     <block>
       <prompt> 
         Hello Developers! You are the VXML Gurus. 
         Please keep using our services. 
       </prompt>
     </block>
   </form>
 </vxml>


[Show Frames]   [FIRST] [PREVIOUS] [NEXT]
BeVocal, Inc. Café Home | Developer Agreement | Privacy Policy | Site Map | Terms & Conditions
Part No. 520-0001-02 | © 1999-2007, BeVocal, Inc. All rights reserved | 1.877.33.VOCAL