网上有很多修改方法,只有这个是唯一有效方法
首先:服务器上搜索functions.php 文件
一般路径是:wp-content/themes/ripro/functions.php
然后就上面插入以下代码:
// 修改启用密码保护时的提示字样add_filter( 'the_password_form', 'zhang_the_password_form' );function zhang_the_password_form() { global $post; $label = 'pwbox-'.( empty( $post->ID ) ? rand() : $post->ID ); $output = '<form action="' . esc_url( site_url( 'wp-login.php?action=postpass', 'login_post' ) ) . '" method="post">' . __( "<p>这是一篇受密码保护的文章,您需要提供访问密码:</p>" ) . '<p><label for="' . $label . '">' . __( "Password:" ) . ' </label><input name="post_password" id="' . $label . '" type="password" size="20" maxlength="20" style="height:24px;" /><input type="submit" name="Submit" value="' . esc_attr__( "提交" ) . '" style="width:50px;height:28px;" /></p></form>'; return $output;}
END:刷新就成功了
文章推荐:
发表评论