I have checked the following link before starting this thread
I am making a review website with enfold theme without any additional plugin. So please suggest changes in functions.php
I want to change “comments” as shown in category listing to “reviews”. Also “replies” as shown under individual post to reviews.
now the problem is that “number” of comments are not shown for the following
jQuery(".single-post .comments-link").text("Reviews");
jQuery(".category .comments-link").text("Reviews"); --->
jQuery(".single-post .comment-text").text("Reviews"); ---->
Hi simran1982,
I think it will make more sense to change templates other than using JavaScript, even though JavaScript seems to be a faster and easier way, it might get more complex in the future.
Best regards,
Victoria
Can you tell me how to do with functions.php? I will remove javascript from functions.php
Hi,
Unfortunately, it would require quite some time and customization of the theme to achieve this, so I am sorry to tell you that this is not covered by our support. However, if it’s really important for you to get this done, you can always hire a freelancer to do the job for you :)
Best regards,
Basilis
Someone else might need it so i am sharing this solution
/* Change Text Site Wide */
function wpfi_change_text6( $translated_text ) {
if ( $translated_text == 'Comments' ) {
$translated_text = 'Reviews';
}
return $translated_text;
}
add_filter( 'gettext', 'wpfi_change_text6', 20 );