Limited Support
Our team is currently on holiday, so support will be limited during this period. Response times may be slower than usual, and some inquiries may be delayed.
We appreciate your patience and understanding, and we’ll resume our usual support by the end of August.
Hello,
Is there a snippet to allow only vendor role and author of the post to view the comment form and restrict other visitors and guests from reading the comments?
Hi @3dwan,
you can use the following two options:
In this case, the comments will be visible for the roles, however, they'll not be able to post a comment.Â
The whole comment section can be hidden for the guests by the following CSS code:Â
body:not(.logged-in) #comments #wpdcom {
display: none !important;
}
Thank you for the fast reply, I will add the css code to hide comments from guests, but how do I hide them from other user roles? I have already defined the settings you mentioned but I want comments to be only visible to the author of the post and user-role because comments will act as agreement on services and I don't want the author name to be visible to subscriber user role
Hello,
I have tried the above snippet and it doesn't work, sorry im not a developer I don't know coding but the above doesn't work.Â
I am worried if it works it will also disable reviews for products. I need to hide comments for user role on posts only not products.Â
Thank you a lot on advanceÂ
Hello,
Thank you for your reply, if I provided you with the admin access, could you apply the snippet?
Because I have tried to search for comment_template but I couldn't find it.
Waiting for your reply, thank you in advanceÂ
Hi @3dwan,
The changes were implemented by our developers. Please check it.Â
I mean these changes, where can I find them?