Remove role=”search” in get_search_form()
wordpress snippet
Adding this PHP snippet to the functions.php of your wordpress theme will remove the role=”search” from the get_search_form() HTML output. Please note that role is an attribute introduced in XHTML draft for accessibility however does not validate.
snippet : PHPcopy
function valid_search_form ($form) {
return str_replace('role="search" ', '', $form);
}
add_filter('get_search_form', 'valid_search_form');












Pingback: Tweets that mention Wordpress Remove role=”search” in get_search_form() – wpsnipp.com Wordpress code snippets for your blog -- Topsy.com