3 document structure
The XForms specification is an application of XML [XML 1.0] and is designed to be used with other applications of XML, especially XHTML [XHTML 1.0]. This chapter discusses the structure of the XForms defined in this specification.
3.1 XForms Namespace
The address of the XForms namespace is http://www.w3.org/2002/01/xforms, although the recommendation of the XForms defines the final identity, but the future draft may use the new address.
The XForms processor must use the XML namespace mechanism [XML Names] to identify the elements and properties defined by the XForms namespace.
3.2 Transverse Applicable Markers
Each element defined by this specification has an id attribute of the type XSD: ID, allowing elements to pass attribute XSD: IDREF references.
The XForms processor must ignore the unrecognized external elements or properties.
3.3 Model (Model)
This section describes the XForms element model as an element container that defines the XFORMS model, and a page can contain one or more model elements, and Model defines the basic model of the XForms document binding user interaction, so the model element should appear before the user interact mark The content of the Model element is not on the page, for example: Model element appears in the HTML: Head element of XHTML, while the XForms user interface tag appears in element HTML: body.
XML expression:
ExtensionFunctions = List of qnames > model> ExtensionFunctions - Optional, XForms model uses the XPath extension list, using undefined extensions will have an error. Element Model can include the following elements: Instance (Instance) Define basic instances and initial data - see 3.4 Instances. Schema Architecture of the exemplary - see 3.5 Architecture (Schema) Submitinfo Save the submitted details - See 3.6 SubmitInfo Bindings Element BIND Specifies the binding of one or more definitions of XForms model project constraints - see 6 constraints. Privacy P3P-based privacy policy - see 3.7 Privacy Strategy (Privacy) Action Event Processing - See 10.16 Behavior (Action), allowing related events for processing event Model - see 4 processing model. Extension Expansion Elements - See 8.12.4.5 Expansion (Extension) Example: Model ... model> 3.4 Instance (Instance) Element Instance Contains an instance document that provides initial instance data, and instance data can be inline or use external resources. XML expression: instance> xlink: href - Optional pointing to the instance data defined outside. The content of the element instance can be an XML element defined by any namespace, including the processed invisible data, must guarantee the use of the correct defined namespace. 3.5 Architecture (Schema) Elements SCHEMA contains example definition architecture, and the architecture can inline or use external resources. XML expression: ) -> schema> XLINK: HREF - Optional points to the instance data defined outside. 3.6 Submitting Information (SubmitInfo) Element Submitinfo defines how to submit, where is it and what to submit. XML expression: SINGLE NODE BINDING ATRIBUTES Action = XSD: Anyuri MediaTyPeextension = "none" | Qname-but-not-ncname: "none" Method = "post" | "get" | Qname-but-not-ncname: "pos" Version = XSD: NMTOKEN Indent = XSD: Boolean Encoding = XSD: String MediaType = XSD: String omitxmldeclarative = xsd: boolean Standalone = XSD: Boolean CDATASECTIONELEMENTS = list of xsd: qname Replace = "all" | "instance" | "none" | Qname-but-not-ncname: "all" > submitinfo> SINGLE NODE BINDING Attributes - Optional Select Submit some data. Action - The target address of the instance data must be submitted. MediaTyPeextension - Optional Description Information Storage Format, MediaType attached. Method - Optional Description Transfer Protocol submitted. version - corresponds xsl: output version attribute indent - correspondence of xsl: output indent property encoding - corresponding to xsl: output encoding attribute mediaType - corresponding to xsl: output of the media-type attribute omitXMLDeclaration - correspondence of xsl: output omit-xml-declaration Property Standalone - CETADALONE Attribute CDATASECTIONELEMENTS - CDATA-section-Elements attribute of XSL: Output Replace - Define the operation of returning information Note: Many attributes correspond to XSLT attributes [xslt]; do not support the xsltype-system and DOCTYPE-PUBLIC properties supported. Note: The MediaTyPeExtension property is useful when the media type is uncertain, such as: A SOAP Envelope cannot be simply described by "Text / XML" and require additional information. 3.7 Privacy Strategy (Privacy) Element privacy is used to express a P3P [P3P 1.0] strategy involved in a particular form. XML expression: XLINK: HREF = XSD: Anyuri > privacy> XLINK: HREF - Optional Pointing to the external definition P3P Policy reference file ( Non-practical strategy ) .