954,148 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Help with <label for = idref[CS]>

Hello,
I am trying to understand html's attribute. According to http://www.w3.org/TR/html4/interact/forms.html#h-17.9
when I am using a single label for multiple elements I should use the following format: label for = idref [CS]. From what I understand [CS] represents names of the elements that I am labeling. But what is idref? What am I suppose to put there? Would someone kindly post a small example please?

ryy705
Junior Poster
171 posts since Jul 2006
Reputation Points: 10
Solved Threads: 0
 
Hello, I am trying to understand html's attribute. According to http://www.w3.org/TR/html4/interact/forms.html#h-17.9 when I am using a single label for multiple elements I should use the following format: label for = idref [CS]. From what I understand [CS] represents names of the elements that I am labeling. But what is idref? What am I suppose to put there? Would someone kindly post a small example please?

I don't believe labels can be used for multiple FORM elements.

Theidref should be the value of the id attribute of the FORM element for which the label is for. The [CS] stands for Case Sensitive. Since IDs are CS also.

So a label can only be for a single element, since you cannot have two IDs of the same value in an XHTML document.

digital-ether
Nearly a Posting Virtuoso
Moderator
1,293 posts since Sep 2005
Reputation Points: 461
Solved Threads: 101
 

Thanks

ryy705
Junior Poster
171 posts since Jul 2006
Reputation Points: 10
Solved Threads: 0
 
Thanks


you're welcome. :)

digital-ether
Nearly a Posting Virtuoso
Moderator
1,293 posts since Sep 2005
Reputation Points: 461
Solved Threads: 101
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You