Login  Register

Re: Adding unique IDs in xforms with JS

Posted by Markku Laine on Oct 27, 2009; 6:48am
URL: https://discuss.orbeon.com/Adding-unique-IDs-in-xforms-with-JS-tp277068p277128.html

Stephanie,


On 26.10.2009, at 22.22, Stephanie Hall (TT) wrote:

I am new to Orbeon and X-Forms, and in my application, I am trying to use javascript with my xforms to show/hide buttons for different instances in the repeats by putting them in divs.  Is there a way to assign a unique ID to the div specific to the index of the repeater?   They can’t be hard-coded.

In XForms, you can generate UUIDs as follows (or just use string( random(true))):
<xforms:output value="digest( string( random( true ) ), 'MD5', 'hex' )" />


-Markku


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws