Community Forums › Forums › Archived Forums › Design Tips and Tricks › Enterprise Pro – Adding a Widget Area Between Home Top and Home Bottom
Tagged: Enterprise Pro, widget areas
- This topic has 5 replies, 3 voices, and was last updated 10 years, 1 month ago by Mealtog.
-
AuthorPosts
-
August 6, 2014 at 10:37 am #117369MarkAsackerMember
Hi,
First, thanks for taking the time to read this.
I've registered a new side bar "sub-footer" in enterprise pro (copied it from the outreach pro). I don't actually want them to show up in the sub-footer section of the home page I just kept the IDs and everything the same for ease of copying over.
I want them to show up between the Home Top and the Home Bottom widget areas.
Under Appearance > Widgets it is ordered correctly (Home Top, sub footer left, sub footer right, Home Bottom) but on the home page it displays home top, home bottom, footer left, footer right...
Does anyone know how to flip these? I must be missing something because I've done this type of thing many times before and can't figure out why it's not working now.
Thanks advance for any help you can offer...
Just FYI
I've added support for the widget areas in the functions.php using this...
//* Add the sub footer section add_action( 'genesis_after_content_sidebar_wrap', 'enterprise_sub_footer', 2 ); function enterprise_sub_footer() { if ( is_active_sidebar( 'sub-footer-left' ) || is_active_sidebar( 'sub-footer-right' ) ) { echo '<div class="sub-footer"><div class="wrap">'; genesis_widget_area( 'sub-footer-left', array( 'before' => '<div class="sub-footer-left">', 'after' => '</div>', ) ); genesis_widget_area( 'sub-footer-right', array( 'before' => '<div class="sub-footer-right">', 'after' => '</div>', ) ); echo '</div><!-- end .wrap --></div><!-- end .sub-footer -->'; } }
Then I've added these arrays to the functions.php file between home top and home bottom
genesis_register_sidebar( array( 'id' => 'sub-footer-left', 'name' => __( 'Sub Footer - Left', 'enterprise' ), 'description' => __( 'This is the left section of the sub footer.', 'enterprise' ), ) ); genesis_register_sidebar( array( 'id' => 'sub-footer-right', 'name' => __( 'Sub Footer - Right', 'enterprise' ), 'description' => __( 'This is the right section of the sub footer.', 'enterprise' ), ) );
Finally I've added these functions to the front-page.php file between home top and home bottom
function enterprise_sub_footer_left_widgets() { genesis_widget_area( 'sub-footer-left', array( 'before' => '<div class="sub-footer"><div class="wrap">', 'after' => '</div></div>', ) ); } function enterprise_sub_footer_right_widgets() { genesis_widget_area( 'sub-footer-right', array( 'before' => '<div class="sub-footer"><div class="wrap">', 'after' => '</div></div>', ) ); }
Am I way off? Easier way?
http://www.jltaylorandassociates.com/newAugust 6, 2014 at 3:32 pm #117431AnitaCKeymasterInstead of adding the area to the functions, open up the front-page.php and insert it where you want it.
Need help with customization or troubleshooting? Reach out to me.
August 6, 2014 at 3:33 pm #117433AnitaCKeymasterYou don't need to add them in there twice. Are you waiting two different widget areas - a left and a right or just one widget area?
Need help with customization or troubleshooting? Reach out to me.
August 6, 2014 at 5:50 pm #117463MarkAsackerMemberHi Anita,
Thanks for the input.
The way they did it in Outreach Pro was the way I copied it as above.
It's a sub-footer widget area with sub-footer-left and sub-footer-right within it.
I have the widget area working the way I want (you can see the results guaranteed graphic is in sub-footer-left and the items they remove from the credit report are in sub footer right).
My problem is that I need Sub-footer (which contains sub-footer-left and sub-footer-right) to come right after the Home Top widget area (where the testimonials sit now). Then I want the home bottom then footer widgets.
Right now it's home top, home bottom, sub-footer, footer.
Does that make sense?
Again thanks for the help.
August 6, 2014 at 6:08 pm #117470AnitaCKeymasterSee here in your code:
add_action( 'genesis_after_content_sidebar_wrap', 'enterprise_sub_footer', 2 );
Change the 2 to 3. If that doesn't work, change to 5. I am not good at the positioning of the numbers yet. If 5 doesn't work, try 10.
Need help with customization or troubleshooting? Reach out to me.
November 11, 2014 at 3:15 am #131163MealtogMemberInteresting. I tried the aboev code and it is still below home bottom. Does anyone know if there is a resolution for this?
-
AuthorPosts
- The forum ‘Design Tips and Tricks’ is closed to new topics and replies.