Accessibility test fails with the search form of Drupal
Hi all,
We are developing several spanish eGovernment web sites, and the main point we want to obtain is a good accesibility acording to W3C, we are using TAW (Web Accessibility Test) http://www.tawdis.net/. We have experienced two accesibility problems on the search form. This is the result of our TAW-analysis:
Associate labels explicitly with their controls.
- This form control is not explicitly associated with a label. (1)
- Line 40:
<input type="text" maxlength="128"
name="search_theme_form_keys" id="edit-search-theme-form-keys" size="15"
value="" title="Insert the words you want to search"
class="form-text" />
First error: the search form do not contains a text item on the 'value'
of the form, this must be corrected, the solution would be adding
"Search..." on the edit box.
Second error: The form doesn't have the tag LABEL with the name of the
search form ID. The solution is adding:
<LABEL
for="edit-search-theme-form-keys"></LABEL><input
type="text"..."So, the solution we propose is:
<div id="search" class="container-inline"><div class="form-item">
<b>CHANGE 1 (ADDING A LABEL)</b> <LABEL for="edit-search-theme-form-keys"></LABEL>
<b>CHANGE 2 (ADDING A VALUE)</b> <input type="text" maxlength="128" name="search_theme_form_keys" id="edit-search-theme-form-keys" size="15" value="Search..." title="Insert the words you want to search" class="form-text" />Is it posible to add in the core of Drupal?
For a manual change, where is the generator file of this search form?
thanks in advance!
joan

Please test this in drupal 6
Please test this in drupal 6 and if the issue persists search for an issue node, and create one if there is no issue node. Creating a patch for it will likely bring more attention to your issue.
Bevan/
Search input accessibility improved in drupal 6
In Drupal 6 the built-in search form does have a label tag as suggested. This meets current best practices as well as important accessibility standards: U.S. Section 508 § 1194.22 (n); W3C WCAG 12.4.
The code looks like this in drupal 6.1:
<label for="edit-search-block-form-1">Search this site: </label><input type="text" maxlength="128" name="search_block_form" id="edit-search-block-form-1" size="15" value="" title="Enter the terms you wish to search for." class="form-text" />
Brandon Bowersox - OJC Technologies - www.ojctech.com - Check out our latest Drupal website at http://ihrp.uic.edu