How to customise Leave a Reply area

Hi Aigars and Movin,

Thanks so much for the help thus far. Just wondering how to change the “Your email address will not be published. Required fields are marked*” by the Leave a Reply area?

Thanks in advance,

WP: Current
Dazzling: Current

Hi @4alex,

I hope you are well today and thank you for your question.

You change this text by adding the following code in the functions.php file of your child theme and changing the text in that code to whatever you want to display.

function change_comment_form_defaults($defaults){
	$req      = get_option( 'require_name_email' );
	$required_text = sprintf( ' ' . __('Required fields are marked %s'), '<span class="required">*</span>' );
	$defaults['comment_notes_before'] = '<p class="comment-notes"><span id="email-notes">' . __( 'Your email address will not be published.' ) . '</span>'. ( $req ? $required_text : '' ) . '</p>';
	return $defaults;
add_filter('comment_form_defaults', 'change_comment_form_defaults');

I have also attached the child theme to this reply which contains the above code so you can use it to achieve it.

Best Regards,