Difference between revisions of "CAM:XForms"
(→Transport) |
|||
(2 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
This page is to discuss a general XForms-based specification to be used across the CAM, Mobile MRS, etc. projects intended to support distributed, disconnected data collection in rural areas of the developing world. | This page is to discuss a general XForms-based specification to be used across the CAM, Mobile MRS, etc. projects intended to support distributed, disconnected data collection in rural areas of the developing world. | ||
+ | ( a good XForms reference: [http://developer.mozilla.org/en/docs/XForms Mozilla XForms]) | ||
+ | == XForm example == | ||
+ | |||
+ | <pre> | ||
+ | <html | ||
+ | xmlns="http://www.w3.org/1999/xhtml" | ||
+ | xmlns:xf="http://www.w3.org/2002/xforms" | ||
+ | xmlns:xs="http://www.w3.org/2001/XMLSchema" | ||
+ | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | ||
+ | <head> | ||
+ | <title>Your Title Here</title> | ||
+ | <xf:model> | ||
+ | <xf:instance xmlns=""> | ||
+ | <Data> | ||
+ | <PersonName/> | ||
+ | <DOB/> | ||
+ | </Data> | ||
+ | </xf:instance> | ||
+ | <xf:bind id="name" nodeset="/Data/PersonName"/> | ||
+ | <xf:bind id="DateOfBirth" nodeset="/Data/PersonSurName" type="xsd:date"/> | ||
+ | </xf:model> | ||
+ | </head> | ||
+ | <body> | ||
+ | <xf:input bind="PersonName" incremental="true"> | ||
+ | <xf:label>Input Name:</xf:label> | ||
+ | </xf:input> | ||
+ | <br/> | ||
+ | <xf:input bind="name" incremental="true"> | ||
+ | <xf:label>Input Last Name:</xf:label> | ||
+ | </xf:input> | ||
+ | <br/> | ||
+ | <xf:output bind="name"> | ||
+ | <xf:label>Output Name:</xf:label> | ||
+ | </xf:output> | ||
+ | <br/> | ||
+ | <xf:output bind="DateOfBirth"> | ||
+ | <xf:label>Output DOB:</xf:label> | ||
+ | </xf:output> | ||
+ | </body> | ||
+ | </html> | ||
+ | </pre> | ||
== Subset of XForms Spec to Support == | == Subset of XForms Spec to Support == | ||
Line 40: | Line 81: | ||
Specify binding of form elements to sensor readings. | Specify binding of form elements to sensor readings. | ||
+ | |||
+ | Specify binding of form elements to xml data model in xform. | ||
+ | |||
+ | <xforms:bind nodeset="/payment/expiry" | ||
+ | relevant="/payment/@method = 'cc'" | ||
+ | required="true()" | ||
+ | type="xsd:date"/> | ||
=== Multi-media === | === Multi-media === |
Latest revision as of 07:59, 19 June 2007
This page is to discuss a general XForms-based specification to be used across the CAM, Mobile MRS, etc. projects intended to support distributed, disconnected data collection in rural areas of the developing world.
( a good XForms reference: Mozilla XForms)
Contents
XForm example
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:xf="http://www.w3.org/2002/xforms" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <head> <title>Your Title Here</title> <xf:model> <xf:instance xmlns=""> <Data> <PersonName/> <DOB/> </Data> </xf:instance> <xf:bind id="name" nodeset="/Data/PersonName"/> <xf:bind id="DateOfBirth" nodeset="/Data/PersonSurName" type="xsd:date"/> </xf:model> </head> <body> <xf:input bind="PersonName" incremental="true"> <xf:label>Input Name:</xf:label> </xf:input> <br/> <xf:input bind="name" incremental="true"> <xf:label>Input Last Name:</xf:label> </xf:input> <br/> <xf:output bind="name"> <xf:label>Output Name:</xf:label> </xf:output> <br/> <xf:output bind="DateOfBirth"> <xf:label>Output DOB:</xf:label> </xf:output> </body> </html>
Subset of XForms Spec to Support
Specify subset of XForms elements that will be supported.
- XPath
- Only basic XPath support (/myData/name/firstName)
- Instance
- Single instance within model element
- External instance
- Bind
- Attributes: id, nodeset, type
- DataTypes
- string, int, boolean, date
- Input elements
- Label
- Hint
- Select1 elements
- Label
- Hint
- Radio buttons only (no dropdown)
- Select elements
- Label
- Hint
- Radio buttons only (no dropdown)
Extensions
Discuss possible extensions to the XForms spec.
Ordering
Specify ordering form elements when presented one item at a time (default to lexical ordering?).
Data Binding
Specify binding of form elements to local / remote files and/or database.
Specify binding of form elements to sensor readings.
Specify binding of form elements to xml data model in xform.
<xforms:bind nodeset="/payment/expiry" relevant="/payment/@method = 'cc'" required="true()" type="xsd:date"/>
Multi-media
Specify widgets for image capture, audio / video recording and playback
Security
Support for SIM, POS, mag stripe, smartcard, biometrics, barcode readers?
Support for encryption, digital signatures?
Specify IDs for barcode navigation.
Specify IDs for numeric shortcuts / hotkeys.
Transport
Specify other transport protocols (SMS, MMS, E-mail, Voice)
Specify high-level transport directives