Journalism Degree

Adding a search form directly into a default WordPress nav menu is not very intuitive.

However, once you know how to add a search bar into your primary WP menu, it’s easy.

We’ll step through the process, avoiding code that gets into “workarounds” involving z-index, negative margins, and so forth.

This search area will be embedded right into the primary WordPress nav menu. Nice and solid.


Journalism Degree Levels


Our goal, therefore, is a search bar integrated into a WordPress nav menu. Requirement one is that you use a WordPress menu, not the default Thesis menu (there’s an equally simple way to add search to Thesis nav menus, but it’s out of scope for this entry).

So you have a WordPress nav menu. And it’s presumed you want your WordPress search bar ready for additional CSS styling — that way, your search area can be adjusted to match the look-and-feel of your menu and your overall site design preferences.

In short, the search bar and nav menu integration needs to finish looking something like this