• Resolved onedna

    (@onedna)


    Hello there

    I notice that the reviews are automatically showing after the post content. Is there any way to remove the reviews from the end of the posts?

    The reviews are calling after the_content()

    I want to show the reviews by using the short code only

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi.

    Here is my solution to placed in functions.php

    
    /**
     * Adds a hidden tag to a post content to suppres review form since we output it in another place.
     * 
     * https://uk.www.ads-software.com/plugins/wp-customer-reviews/
     *
     * @param string $content
     * @return void
     */
    function suppres_review_output( $content ) {
    	$post = get_post();
    
    	if ( ( !empty( $post->ID ) ) ) {
    		$content = '<!-- data-wpcr3-content="' . $post->ID . '" !-->' . $content;
    	}
    
    	return $content;
    }
    add_filter( 'the_content', 'suppres_review_output', 10 );
    
    • This reply was modified 6 years, 9 months ago by gruz.
    Thread Starter onedna

    (@onedna)

    Its Working , A Big Thank You !

    Plugin Author Aaron Queen

    (@bompus)

    This is usually due to a theme conflict. Looks like you resolved it though!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Reviews are showing automatically after post content’ is closed to new replies.