Where can I find the Header Right function?

Community Forums Forums Design Tips and Tricks Where can I find the Header Right function?

This topic is: resolved

This topic contains 13 replies, has 3 voices, and was last updated by  Jen Baumann 1 year, 4 months ago.

Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • #5175

    Axman1413
    Participant

    My client wants me to add a logo/header in the area where the Header Right Widget will be. However, she doesn’tw ant it ont he Home page, where we have the slider. So I’m guessing it would be something like:

    remove_action–genesis_header_right…so on

    if (is_front_page)…something, something …hehehe.

    I just can’t find the initial widget function to copy in order to ad the conditional remove function to the Executive function.php.

    I am  intermediate with php. I am better at manipulating than writing. So if you can lead me in the right direction, or just provide the correct function call so I can have the Header Right widget appear on all pages, EXCEPT the static Home page.

     

    Thanks,

    Johnny

    #5212

    anitac
    Participant
    Post count: 6402

    So this is how you would actually remove it all together -

    /** Remove the header right widget area */
    unregister_sidebar( ‘header-right’ );

    But, if you only want to remove it from the home and show it on the single post/pages, then you need to add to your code the “is_single()” function.

    I found a blog that might help you – scroll down where it says, “Can I say Which Pages the Widget Shows Up On? – http://journalxtra.com/easyguides/howto-add-widgets-genesis-child-themes-4876/.

    Sorry I cannot be of more help. I am not good at this either.


    Let me help you customize your theme, responsive header, Buddypress, Agentpress or technical issue!
    Visit me here: Cre8tiveDiva.com | Tweet Me! | Plus Me!
    When asking for help, please provide a link or screen shot showing your problem!

    #5290

    Axman1413
    Participant

    Well the problem I’m having is that I just want it removed from the front_page, not the home_page. If it were the home_page, I could just jump in that file and alter it. But the static home page doesn’t have this availability in Genesis.

    I’ve been looking at Nick’s stuff, but I’m spending way too much time on this. I could have gotten all these results using my Pro Version of WeaverII, where I don’t have to code. It’s frustrating, when a client insists on a theme, but then wants to make crazy changes.

    I just need to find the add_action function for the header-right in the Genesis files, so I can copy it an rewrite it in the child f.p to not show on the is_front_page

    So I’m not sure if a filter would work or what the best option is. There is a ton of material on adding things, but not a lot on removing them.

    Johnny

    #5294

    anitac
    Participant
    Post count: 6402

    Sorry I couldn’t be of more help and I see no one else has chimed in. I did another Google search and found this – http://stackoverflow.com/questions/11206736/wordpress-genesis-theme-changing-the-logo-from-text-to-graphic and it has the following code in it – but read the link.

    if ( is_active_sidebar( ‘header-right’ ) || has_action( ‘genesis_header_right’ ) ) {
    echo ”;
    do_action( ‘genesis_header_right’ );
    dynamic_sidebar( ‘header-right’ );
    echo ‘‘;
    }
    }


    Let me help you customize your theme, responsive header, Buddypress, Agentpress or technical issue!
    Visit me here: Cre8tiveDiva.com | Tweet Me! | Plus Me!
    When asking for help, please provide a link or screen shot showing your problem!

    #5295

    Axman1413
    Participant

    LOL, Thanks Anita (funny…that’s my client’s name) I just found that code in the Genesis files. Now let’s see if I can rewrite it correctly.

    Johnny

    #5296

    anitac
    Participant
    Post count: 6402

    I know… I have a great name! Good luck, let me know how it turns out.


    Let me help you customize your theme, responsive header, Buddypress, Agentpress or technical issue!
    Visit me here: Cre8tiveDiva.com | Tweet Me! | Plus Me!
    When asking for help, please provide a link or screen shot showing your problem!

    #5297

    anitac
    Participant
    Post count: 6402

    This article on this link says you need to specify that you want it on “single posts” only (not home page). Scroll down to the bottom and you should see it – http://blogvkp.com/add-widget-in-genesis-child-theme/.


    Let me help you customize your theme, responsive header, Buddypress, Agentpress or technical issue!
    Visit me here: Cre8tiveDiva.com | Tweet Me! | Plus Me!
    When asking for help, please provide a link or screen shot showing your problem!

    #5303

    Axman1413
    Participant

    Well I’m not sure, but this is what I’m thinking. I just don’t know how to introduce it into the child function.php:

    if ( is_active_sidebar( 'header-right' ) || has_action( 'genesis_header_right' ) ) {
    if (is_front_page() {
    echo '';
    }
    if (is_page() {
    echo '^div class="widget-area"^';
    do_action( 'genesis_header_right' );
    dynamic_sidebar( 'header-right' );
    echo '^/div^^!-- end .widget-area --^';
    }
    }

    In the child theme, it just calls the entire genesis_custom_header, so there is more needed to get this to interact with the child theme.

    I’m using”^” in place of “&gt/&lt”

    Johnny

    • This reply was modified 1 year, 4 months ago by  Axman1413.
    • This reply was modified 1 year, 4 months ago by  Axman1413.
    #5405

    Jen Baumann
    Keymaster
    Post count: 315

    Try this: http://dreamwhisperdesigns.com/genesis-tutorials/remove-genesis-header-widget-homepage/


    If you need technical support for your theme please file a ticket.

    The forums are community based. Staff only monitors the forum for issues relating to the forum itself and to redirect users to where they need to go.

    #5406

    anitac
    Participant
    Post count: 6402

    Hi Jen, thank you for helping. I thing he and I were at our wits end! Now, that code you supplied – does it go into the Functions.php file?


    Let me help you customize your theme, responsive header, Buddypress, Agentpress or technical issue!
    Visit me here: Cre8tiveDiva.com | Tweet Me! | Plus Me!
    When asking for help, please provide a link or screen shot showing your problem!

    #5407

    Jen Baumann
    Keymaster
    Post count: 315

    Yep!


    If you need technical support for your theme please file a ticket.

    The forums are community based. Staff only monitors the forum for issues relating to the forum itself and to redirect users to where they need to go.

    #5408

    anitac
    Participant
    Post count: 6402

    Great. Can you delete or close my post in the General area pertaining to this? Thank you.


    Let me help you customize your theme, responsive header, Buddypress, Agentpress or technical issue!
    Visit me here: Cre8tiveDiva.com | Tweet Me! | Plus Me!
    When asking for help, please provide a link or screen shot showing your problem!

    #5414

    Axman1413
    Participant

    Wonderful…wonderful!!! The only change I had to make was to put (is_front_page) in place of (is_home).

    Thank you both for all your help.

    Johnny

    #5415

    Jen Baumann
    Keymaster
    Post count: 315

    Great!


    If you need technical support for your theme please file a ticket.

    The forums are community based. Staff only monitors the forum for issues relating to the forum itself and to redirect users to where they need to go.

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

The topic ‘Where can I find the Header Right function?’ is closed to new replies.