Review Count / Rating count

This topic contains 9 replies, has 3 voices, and was last updated by  Matthew 5 years, 6 months ago.

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
  • Author
    Posts
  • #500702

    Matthew
    Lifetime Member
    Post count: 178

    Someone else had this issue but the topic is closed so I could not add to that thread.

    But on my site reviews are showing as zero for a listing even though there are numerous reviews displayed.

    The argument was I believe that the Reviews count bubble only counts Ratings.

    So my suggestion is, please can the Reviews bubble show the number of reviews rather than the number of ratings?

    #500714

    Alex Rollin
    Moderator
    Post count: 27815

    They are one and the same, as GD is targeted towards reviews (which is a rating with a text comments, as opposed to just comments), so this would be a customization at this time.

    I have flagged your idea for the developers, and spoken with them, and they will let us know if they plan to alter this feature in the future.

    #500721

    Kiran
    Moderator
    Post count: 7069

    Hi Matthew,

    If CPT has review with stars options is enabled then comments submitted without reviews do not included in reviews total.

    Use following PHP snippet to achieve what you requested.

    
    
    /**
     * Count comment without stars in review total.
     */
    function gd_snippet_190801_get_comments_number( $count, $post_id ) {
    	global $post;
    
    	if ( ! empty( $post ) && (int) $post->ID == (int) $post_id && geodir_is_gd_post_type( get_post_type( $post_id ) ) && geodir_is_page( 'detail' ) ) {
    		$count = absint( $post->comment_count );
    	}
    
    	return $count;
    }
    add_filter( 'get_comments_number', 'gd_snippet_190801_get_comments_number' , 20, 2 );

    Regards,
    Kiran

    #500723

    Matthew
    Lifetime Member
    Post count: 178

    Hi Thanks Kiran, but I wouldn’t know where to add this. Would I need to have a child theme in place before adding this?

    #500724

    Kiran
    Moderator
    Post count: 7069
    #506426

    Matthew
    Lifetime Member
    Post count: 178

    Hi Kiran, a customer pointed out …

    “Hi, one of my clients was trying to leave a review on my listing, and was having problems – she says “it seems to be insisting that I leave a star rating before it will post anything but won’t actually let me do that!” ”

    I hoep you can help… I am wondering if some of the customisations have created this side-effect?

    I hope you can help?

    Mat

    #506501

    Kiran
    Moderator
    Post count: 7069

    Hi Matthew,

    Provide us a site link and admin credentials to look into there.

    Kiran

    #506510

    Matthew
    Lifetime Member
    Post count: 178
    This reply has been marked as private.
    #506519

    Kiran
    Moderator
    Post count: 7069

    Please check now.

    Rating icon was empty. I have selected it at GeoDirectory > Settings > Design > Rating icon.

    Kiran

    #506522

    Matthew
    Lifetime Member
    Post count: 178

    Oh thanks, no idea why that happened!

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

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
20% Discount Offer
Hurry! Get your 20% discount before it expires. Get 20% Discount