Password protect any posts automatically upon publish

You can password protect all posts once they’re published using the following function. add_action(‘publish_post’, ‘ppwp_pro_auto_protect_posts_when_publishing’); function ppwp_pro_auto_protect_posts_when_publishing( $post_id ) { if ( method_exists(‘PPW_Pro_Password_Services’, ‘protect_post_by_password’ ) ) { $passwords_service = new PPW_Pro_Password_Services(); $passwords_service->protect_post_by_password( $post_id ); } } To apply for pages or any custom post types, you should change the action accordingly. add_action(‘publish_page’, ‘ppwp_pro_auto_protect_posts_when_publishing’); // Apply…

WordPress Double Password Protection

Our Password Protect WordPress (PPWP) plugin provides various ways to protect your private content with passwords, namely, sitewide, individual, and partial content protection. 1. Sitewide Protection Users will be prompted to enter passwords in order to access any content on your protected site. In other words, the entire website including its header, footer, and sidebar…