Archived topic
Where is the header widget area located?
6 replies · Started by John on September 7, 2016
Now I'm trying to insert a widget with social links into the header widget area... but I can't find the header widget area!
I've created the set of social links with AccessPress Social Icons which provides both a widget and a short code.
I've gone to Widgets > Header > Add a widget in the customizer and added the AccessPress Social Icons widget - but nothing shows up.
So I've gone to the main WP widget management area, put a text box in the Header Widget Area field there and pasted the AccessPress Social Icons short code. Still nothing.
If I use Firefox's Inspector on the front page header, I can't find a widget area.
I'm running a narrow, full-width header, is that what I'm doing wrong? What do I need to do to get the widget area to show?
Thanks,
John
The front page is on my sandbox website here:
http://www.nixon-wit.com/
Ah, OK. Discount that. I've found the header widget area. Apparently I have the header switched off for this page and only the sticky navigation bar visible.
But is there a way for me to include a line of social icons in the sticky header, for exampel to the left under the logo? (I mean is it possible to put a widget here?)
Ideally the social icons will be always visible even when a visitor is scrolling down.
Thanks
John
There is a hook you can use: generate_inside_navigation
Using hooks: https://generatepress.com/knowledgebase/hook-list/
Putting a widget in there would require you to do something like this: https://codex.wordpress.org/Function_Reference/the_widget
Or use a plugin like this: https://en-ca.wordpress.org/plugins/widget-shortcode/
If you go the shortcode route, you'll need to wrap it in a function like this:
<?php echo do_shortcode('[shortcode]'); ?>
Hope this gets you going :)
More easily, you can just add social icons to your menu: https://generatepress.com/knowledgebase/menu-social-icons/
Hi Tom,
It would be easier but I can't add social icons to the menu as Font Awesome isn't awesome enough to have icons for some of the social networks I want to include (Ello, Bloglovin, Ipernity). Nor does it let let me create my own (as AccessPress does).
I'll look at that plug-in first. I'm no programmer, so using hooks doesn't attract me, but I suppose if that's what I have to learn how to use then that's what I have to learn how to use.
Thanks for your response.
Cheers,
John
How I do hate programming.
:(
It can be difficult, but it's very rewarding once you meet your goals.
Unfortunately hooks are the only way to get custom HTML into the navigation right now - hopefully you're able to find those icons you need in one form or another.