On Mon, 04 Oct 2004 22:39:04 GMT, RobG <rg***@iinet.net.auau> wrote:
[snip]
To turn it into an element (type 1) that you can
manipulate, put it inside an element tag, such as <p>
<span> <div> or similar valid HTML tags. It will be an
"official" sibling of the input.
As the text probably qualifies as a label, the LABEL element would be the
best to use:
<label for="myInput"><input id="myInput" type="checkbox" ...>
Your text here</label>
All DOM-supporting browsers should access that label text with:
inputObj.nextSibling.data
(Verified with the latest versions of Opera, IE, Mozilla, Netscape, and
Firefox)
When you change the value, remember to add a space before the text so that
it doesn't appear flush next to the checkbox.
Mike
--
Michael Winter
Replace ".invalid" with ".uk" to reply by e-mail.