change hooks of secondary sidebar

Community Forums Forums Design Tips and Tricks change hooks of secondary sidebar

This topic is: not resolved

This topic contains 2 replies, has 2 voices, and was last updated by  design_agency 4 months, 1 week ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #104708

    design_agency
    Member
    Post count: 53

    hi —

    looking for some advice on how to change the position of the secondary sidebar*. i’d like it to appear in the “genesis_entry_footer” hook (instead of in the default sidebar widget location) on my pages and single portfolio pages, but not in my blog posts.

    since the file for the secondary sidebar (sidebar-alt.php) is part of the genesis core files, im not sure 1) how to be smart about pointing it to a different location and 2) when i do, how to point it to my pages and single portfolio pages only.

    any ideas?

    thanks,
    emily

    * using minimum pro, but added back in the secondary sidebar

    http://dev.design-agency.org/
    #104715

    Lauren @ OnceCoupled
    Member
    Post count: 608

    You’ll need to adjust the hooks and use some conditional logic. Untested:

    if ( is_singular('portfolio') || is_page() ) {
         remove_action( 'genesis_sidebar_alt', 'genesis_do_sidebar_alt' );
         add_action( 'genesis_entry_footer', 'genesis_do_sidebar_alt' );
    }

    This may take significant CSS re-styling. You may be better off using a template for those pages, forcing a full width layout, and then inserting a custom sidebar at the bottom of the page.

    Best,
    Lauren


    I do custom WordPress work! http://oncecoupled.com
    Contact me directly: lauren@oncecoupled.com

    #105067

    design_agency
    Member
    Post count: 53

    hi lauren,

    thanks so much for this. it makes perfect sense to me, though when i try it out i get nothing. i’m not quite sure where to go from here and might look for another design solution. nevertheless, thanks for your suggestion!

    emily

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.