I made a slight change to the FlexSearchForm to improve validation:
// $xhtmlStrict [ true | false ]
// If you want this form to validate as XHTML Strict compliance, then
// this needs to be true, but IE has a fieldset bug that I don't know
// a workaround for. So you can set this to false to avoid it.
$xhtmlStrict = (isset($xhtmlStrict))? $xhtmlStrict : true;
This way it validates by default; if you have a problem with the IE fieldset bug you can set it to ’false’ in the snippet call.
[[FlexSearchForm?... &xhtmlStrict=`false`]]
-
- 372 Posts
To make FlexiSearch validate against Cynthia (WCAG) you need to include the label reference, if you replace the code around line 291 to 293 with the following code it will validate although with a warning about using implicit labels.
$SearchForm .= '<label><input class="FSF_input" type="text" name="search" value="'.$searchBoxVal.'" ';
$SearchForm .= ($boxText)? 'onfocus="this.value=(this.value==\''.$boxText.'\')? \'\' : this.value ;" />' : '/></label>';
$SearchForm .= '<label><input class="FSF_submit" type="submit" name="sub" value="'.$searchButtonText.'" /></label>';
Might come back to this another day and see if I can make a better solution or maybe someone already has one?
Cheers.