Using Action Hook on homepage content only

Community Forums Forums Design Tips and Tricks Using Action Hook on homepage content only

This topic is: not resolved

This topic contains 1 reply, has 1 voice, and was last updated by  wizz6113 8 months, 3 weeks ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #87642

    wizz6113
    Member
    Post count: 77

    I am using the genesis_entry_footer hook to add an image (a call to action banner) within the body content of the homepage only; ie. I don’t wish it to show on all site body content areas.

    I am using the simple hooks plugin, and have pasted in the html for the image. How do I add the right php code to ensure it’s visible home page only?

    Tnx anyone!

    http://localdev
    #87645

    wizz6113
    Member
    Post count: 77

    I think I edit this code in functions.php:

    //* Add the after entry section
    add_action( ‘genesis_entry_footer’, ‘streamline_after_entry’, 10 );
    function streamline_after_entry() {

    if ( ! is_singular( ‘post’ ) ) return;

    genesis_widget_area( ‘after-entry’, array(
    ‘before’ => ‘<div class=”after-entry widget-area”>’,
    ‘after’ => ‘</div>’,
    ) );

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

You must be logged in to reply to this topic.