I found little info on how to set constraints, etc on Orbeon XForms elements. What info there is seems to be scattered or clear as mud. Orbeon uses an element called bind inside the xforms:model to set constraints. My particular issue was that some elements don't apply unless another element has some value. Luckily, XForms has an attribute called relevant for this.
<xforms:bind nodeset="instance('main')/element[@name='my-select-list-other-box']">
<xforms:bind nodeset="value" relevant="instance('main')/element[@name='my-select-list']/value='Other'"/>
</xforms:bind>
This is explain concisely at this URL.
3 comments:
Peter, xforms:bind is actually part of the XForms specification. Except for certain dependencies, we implement support as per the spec I believe, so any information on xforms:bind you may find should be relevant.
Thanks Erik, once I stopped searching for Orbeon forms xforms:blah I started getting more results. The actual w3c spec is too verbose however to use as a daily reference...
Peter, I agree, not everybody should have to read through the actual spec as it is a bit daunting. However, there are some references out there that are useful, including http://en.wikibooks.org/wiki/XForms and http://xformsinstitute.com/essentials/browse/book.php (note that Micah's book has not been updated for XForms 1.1, and XForms 1.1 is the real thing now). If you are using Orbeon Forms, then what you need is joining the ops-users mailing-list.
Post a Comment