robincornett / genesis-accessible

This plugin fixes some accessibility issues with the Genesis Framework
28 stars 9 forks source link

Change get_search_form filter removal to priority 10, or delete #2

Closed GaryJones closed 10 years ago

GaryJones commented 10 years ago

The Genesis version of the search form is currently filtered in with:

add_filter( 'get_search_form', 'genesis_search_form' );

That's obviously priority 10, so this plugin's:

remove_filter( 'get_search_form', 'genesis_search_form', 20 );

won't work as intended.

However, this actually doesn't matter - since the plugin's own filter kicks in at priority 20 and replaces everything, all of the filtering by Genesis gets overwritten anyway, so removing it or not doesn't make any difference. The remove_action() could be removed, or fixed.

If it is fixed, then it still might not actually do anything, since this plugin is probably removing it before the theme has had a chance to add it anyway. You would need to wrap it in another function hooked to genesis_setup for it to take effect after Genesis has kicked in.

rianrietveld commented 10 years ago

removed the remove_action();