New answers tagged

0

Try below code which is return comment count of current user who posted comments on post. get_comment() have count parameter which returns only count of comment. in your code you are using $commentdata variable which is not defined. I have tested below code and it is working fine for me. let me know if this works for you. global $current_user, $post; if ( ...


0

You can't just do a simple If statement like this? ... if ( count( $usercomment ) < 1 ) { comment_form(); }; I don't know why you would have to unset it.


Top 50 recent answers are included