How to Show or Hide WordPress Widgets
Have you ever needed to show or hide WordPress widgets? Have you found the need to control your sidebar widgets and restrict who sees what? Or maybe you are wondering what a widget really is? First things first. What is a widget, you ask? Well, you can put bits of important information into a WordPress widget and then use that widget in a sidebar on all of your pages. A WordPress widget is simply a way to add that content to your sidebar.
For example, the search widget or categories widget are two widgets you might be familiar with. Or you can use a widget for a call-to-action (CTA). An example would be a newsletter sign-up form.
Here are screenshots of two such widgets that you will see in the sidebar on our website:
Search Widget
Call-to-Action Widget
For a more detailed explanation of widgets, please refer to the WordPress Codex here.
As a WordPress web designer, I’ve run into the issue of how to show or hide WordPress widgets on nearly every site I work on. Themes vary as to how they use sidebars, and some themes give you the option to create your own sidebars. You can then add or remove widgets for each sidebar.
Many of my sites are built on the Genesis Framework and I’ve
Source: https://managewp.org/articles/13844/how-to-show-or-hide-wordpress-widgets
source https://williechiu40.wordpress.com/2016/11/16/how-to-show-or-hide-wordpress-widgets/