Today I’ve come across an interesting question on the support forum: How do I add a toggling search box to the MH Magazine Lite theme?

Here’s a video that shows you how to accomplish this (download .zip file available).

Download .zip File
You can freely download and use the demo files for this tutorial.

If you intend to distribute your theme, all strings of text should be translation-ready. Therefore, a better approach to the screenreader text in header.php presented in the video is the following:

_e( ‘Click here to display searchbox’, ‘mh-magazine-lite-child’ )
_e( ‘Click here to hide searchbox’, ‘mh-magazine-lite-child’ )

The download files have been updated accordingly.

MH Magazine Lite Theme
Genericons Icon Fonts
Was this tutorial useful? Let me know

Leave a comment

Your email address will not be published. Required fields are marked *