Community Forums › Forums › Archived Forums › Design Tips and Tricks › Enterprise Pro – Create a new widget area
- This topic has 4 replies, 3 voices, and was last updated 8 years, 1 month ago by
rjr6305.
-
AuthorPosts
-
October 27, 2017 at 8:22 pm #213031
Belinda
ParticipantI am trying to create a new widget area to be displayed below the navbar but above the page/post title for a site but no matter what code i try, it's not working. I can register the new widget area, and can see it through the dashboard to add test content to it, but cannot get it to actually display on the site.
Can anyone point me in the right direction?
October 27, 2017 at 8:24 pm #213032Belinda
ParticipantP.S. I've been using https://my.studiopress.com/documentation/tutorials/widget-areas/register-a-widget-area/ as a reference but none of the code is showing on the page.
October 29, 2017 at 2:40 pm #213063Victor Font
ModeratorDid you follow the directions for adding the widget area to a hook and displaying it on a page?
The example you referenced will on show the widget area on the front end on single post pages. Do you want the widget area to display site-wide or on a specific page?
Does your theme display the navigation menu in the genesis_after_header hook?
Regards,
Victor
https://victorfont.com/
Call us toll free: 844-VIC-FONT (842-3668)
Have you requested your free website audit yet?October 31, 2017 at 9:52 pm #213134Belinda
ParticipantI've managed to get it to display but certainly isn't showing in the location I want it and it doesn't matter how much i move it around I can't get it sitting correctly.
Ideally I would just use the Footer 1 widget area I already have, but i want it to be full screen width and displayed on all site pages and posts. I've done this before on another site (not studiopress) and it worked fine but having so much issue this time round.
Is there a way I can make Footer 1 widget area display full width?
November 8, 2017 at 8:48 pm #213401rjr6305
MemberI too am trying to add a widget area to the center of my header. I am running Enterprise Pro.
I successfully reduced the size of the existing site-title and widget-area to make ample room between them to add a new widget area. I also successfully registered a new widget area and it is showing on the Genesis Widgets dialog. The only thing I have not gotten to work is actually displaying the new widget area - anywhere, let alone in the middle of the header where I want it to be.
I did follow the directions for adding the new widget area to a hook and displaying it on a page - to the best of my understanding and ability, but nothing shows anywhere.
Here is the code I added to the functions.php file:
add_action( 'genesis-header', 'sp_header_center_widget', 11 );
function sp_header_center_widget() {
genesis_widget_area( 'header-center', array (
'before' => '<div class="header-center widget-area">',
'after' => '</div',
) ); -
AuthorPosts
- The forum ‘Design Tips and Tricks’ is closed to new topics and replies.