[Support request] After Content GP Hook – Display:none on Taxonomies?

Home Forums Support After Content GP Hook – Display:none on Taxonomies?

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #937807

    Using the GP hook for After Content puts items in the taxonomies as well. I’m sure this is a simple php if statement, but for whatever reason I’m having a massive brain fart.

    How would I get the hook not to fire (or display:none) on the taxonomies, or anywhere else besides the posts/pages.



    Might also help to know that the hook is executing php and currently contains:

    <?php the_field('benefits'); ?>
    <?php if(  get_field('desire') == '90%' ): ?>
    <?php echo do_shortcode("[PROGRESSBAR_WP id=3897]"); ?>
    <?php endif; ?>
    <?php if ( function_exists( 'wpsabox_author_box' ) ) echo wpsabox_author_box(); ?>
    <?php related_posts(); ?>

    I *think* I have a possible solution, but I’ll leave this open in case you know of a better global way to nest these statements. I know just enough PHP is completely break a site. πŸ˜‰

    Possible solution:

    <?php if ( is_single() ) {the_field('benefits');} ?>
    <?php if ( is_single() ) {if(  get_field('desire') == '90%' ): ?>
    <?php echo do_shortcode("[PROGRESSBAR_WP id=3897]"); ?>
    <?php endif;} ?>
    <?php if ( is_single() ) {if ( function_exists( 'wpsabox_author_box' ) ) echo wpsabox_author_box();} ?>
    <?php if ( is_single() ) {related_posts();} ?>
    // To use on single post add "if (is_single() {functionality;}
    Customer Support

    Hi there,

    Maybe I’m missing something here but have you tried the Display Rules?

    You can just set it to Post > All Posts and Page > All Pages.

    Let me know πŸ™‚

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.