2.2.1.2.103 views

The views element specifies the collection of all form views in the form template. Form views are used to render and edit form files associated with the form template. Form views are represented by XSLT files, as specified in section 2.4, which define how to convert form files into HTML. A specific form view is used by default, and other form views can be displayed.

Each browser-compatible form template MUST contain at least one form view where both of the following are true:

  • The clientOnly attribute of the viewExtension element, as specified in section 2.2.2.2.35, is set to "no".

  • The designMode attribute of the view element, as specified in section 2.2.1.2.104, is set to "normal".

Parent Elements

xDocumentClass

Child Elements

view

Attributes:

default: This attribute specifies the name of the form view that is used to render the form file. If this attribute is present, the value MUST match the value specified by the name attribute of a view element. If this attribute is not present, the first form view MUST be rendered.

The following W3C XML Schema ([XMLSCHEMA1] section 2.1) fragment specifies the contents of this element.

 <xsd:element name="views">
   <xsd:complexType>
     <xsd:sequence>
       <xsd:element ref="xsf:view" minOccurs="1" maxOccurs="unbounded"/>
     </xsd:sequence>
     <xsd:attribute name="default" type="xsd:string"/>
   </xsd:complexType>
   <xsd:unique name="views_name_unique">
     <xsd:selector xpath="./xsf:view"/>
     <xsd:field xpath="@name"/>
   </xsd:unique>
   <xsd:keyref name="view_printView" refer="xsf:view_or_externalView_name_key">
     <xsd:selector xpath="./xsf:view"/>
     <xsd:field xpath="@printView"/>
   </xsd:keyref>
   <xsd:keyref name="views_default" refer="xsf:view_name_key">
     <xsd:selector xpath="."/>
     <xsd:field xpath="@default"/>
   </xsd:keyref>
 </xsd:element>