select
elements have a label that contains text.
select
element.
label
associated with the select
element.
select
elements.select
element's associated label.label
contains text.
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/xhtml; charset=UTF-8" /> <title>ATRC Testfile 208.2 - Negative</title> </head> <body> <form method="post" action="http://www.test.com"> <p> <label for="animal">Animal:</label> <select name="abcselect" id="animal"> <option value="1">dog</option> <option value="2">cat</option> <option value="3">bird</option> </select> </p> </form> </body> </html>
label
is empty.
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/xhtml; charset=UTF-8" /> <title>ATRC Testfile 208.1 - Positive</title> </head> <body> <form method="post" action="http://www.test.com"> <p> <label for="animal"></label> <select name="abcselect" id="animal"> <option value="1">dog</option> <option value="2">cat</option> <option value="3">bird</option> </select> </p> </form> </body> </html>