Add the following to your functions.php and change "This post is password protected. To view it please enter your password below:".
add_filter( 'the_password_form', 'custom_password_form' );
function custom_password_form() {
global $post;
$label = 'pwbox-'.(empty($post->ID) ? rand() : $post->ID);
$output = '<form action="' . get_option('siteurl') . '/wp-pass.php" method="post">
<p>' . __("This post is password protected. To view it please enter your password below:") . '</p>
<p><label for="' . $label . '">' . __("Password:") . ' <input name="post_password" id="' . $label . '" type="password" size="20" /></label> <input type="submit" name="Submit" value="' . esc_attr__("Submit") . '" /></p>
</form>
';
return $output;
}
Thread Starter
comrav
(@comrav)
Thanksamillion for the helpful suggestion, Joseph. I took a different approach, though. I figured since the offending text was already appearing I should find the actual source (rather than adding a new filter). Ran a quick search of all text in all documents and discovered the offending text in wp-includes/post-template.php. Quick change in the text editor to, “This area is password protected…” and I’m good to go! Cheers!