/**
* WordPress 更改文章密码保护后显示的提示内容
*/
function password_protected_change( $content ) {
global $post;
if ( ! empty( $post->post_password ) && stripslashes( $_COOKIE['wp-postpass_'.COOKIEHASH] ) != $post->post_password ) {
$output = '
<form action="' . get_option( 'siteurl' ) . '/wp-login.php?action=postpass" method="post">
<p>'.__( "该测试高能,加入页面底部微信群后获得测试密码(完全免费):
" ).'</p>
<p>
<label for="post_password">密码:</label>
<input name="post_password" class="input" type="password" size="20" />
<input type="submit" name="Submit" class="button" value="' . __( "提交" ) . '" />
</p>
</form>
';
return $output;
} else {
return $content;
}
}
add_filter( 'the_password_form','password_protected_change' );
* WordPress 更改文章密码保护后显示的提示内容
*/
function password_protected_change( $content ) {
global $post;
if ( ! empty( $post->post_password ) && stripslashes( $_COOKIE['wp-postpass_'.COOKIEHASH] ) != $post->post_password ) {
$output = '
<form action="' . get_option( 'siteurl' ) . '/wp-login.php?action=postpass" method="post">
<p>'.__( "该测试高能,加入页面底部微信群后获得测试密码(完全免费):
" ).'</p>
<p>
<label for="post_password">密码:</label>
<input name="post_password" class="input" type="password" size="20" />
<input type="submit" name="Submit" class="button" value="' . __( "提交" ) . '" />
</p>
</form>
';
return $output;
} else {
return $content;
}
}
add_filter( 'the_password_form','password_protected_change' );
实际测试管用,页面 力比多(性)知识测试 https://www.xinlixue.cn/wp/archives/1684.html
打赏作者,期待美好
打赏鼓励作者,为网友提供更多更好的测试,也许一瓶水就够了。