Defines a static text message or an image to display on the form.
If both an image and a text message are defined for the label, the image takes precedence in viewers able to display images.
active, bgcolor, border, borderinfo, fontcolor, fontinfo, format, gradient, help, image, imagemode, itemlocation, itemnext, itemprevious, justify, linespacing, printbgcolor, printfontcolor, printvisible, size, value, visible, xformsenabled, xformsreadonly, xformsrequired, xformsvalid, xforms:output
The following label example shows a value from the XForms data layer combined with a textual label indicating the meaning of the value. The raw data value is formatted using locale-specific currency rules (e.g. $856.07). The data value is determined by a formula provided by the XForms calculate, which is immediately responsive to any user changes to the principal, interest rate, or duration of the loan for which this monthly payment is being calculated. Also, due to the XForms relevant model item property, the label item is invisible until the user enters positive Principal and Duration values.
<xforms:instance xmlns="" id="loan">
<LoanRecord>
...
<MonthlyPayment>856.07</MonthlyPayment>
</LoanRecord>
</xforms:instance>
...
<xforms:bind nodeset="MonthlyPayment"
calculate="if(instance('rate') > 0,
../Principal * instance('rate')
div
(1.0 - power(1.0 + instance('rate'), -../Duration)),
../Principal div ../Duration)"
relevant="../Principal > 0 and ../Duration > 0"/>
...
<label sid="MonthlyPaymentItem">
<xforms:output ref="MonthlyPayment">
<xforms:label>Monthly Payment: </xforms:label>
</xforms:output>
<format>
<datatype>currency</datatype>
</format>
<itemlocation>
<under>InterestRateItem</under>
<expandr2r>InterestRateItem</expandr2r>
</itemlocation>
</label>
This is an example of a multiple-line text label:
<label sid="RHYME LABEL">
<value>
Little Miss Muffet sat on her tuffet,
Eating her curds and whey.
When along came a spider, who sat down beside her,
and frightened Miss Muffet away!
</value>
<fontinfo>
<fontname>Times</fontname>
<size>16</size>
<effect>italic</effect>
</fontinfo>
<justify>right</justify>
</label>
Total: 200