#21342 closed enhancement (wontfix)
The admin bar search form is lacking the get_search_form filter
| Reported by: | Chouby | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Toolbar | Version: | 3.4.1 |
| Severity: | normal | Keywords: | |
| Cc: | Focuses: |
Description
The correction is obvious. Just add :
$form = apply_filters('get_search_form', $form);
at line 641 of wp-includes/admin-bar.php
Change History (3)
#2
@
14 years ago
- Milestone Awaiting Review
- Resolution → wontfix
- Status new → closed
get_search_form is for get_search_form() which is reserved for themes and not for the toolbar.
If you want to replace the search from you can remove the existing with
remove_action( 'admin_bar_menu', 'wp_admin_bar_search_menu', 4 );
and then add you can add your own with
add_action( 'admin_bar_menu', 'your_custom_callback_function', 4 );
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Since that form is not returned by
get_search_form()function, not sure if it's a good idea to use the same filter.