Re: The Display Name stopped working
Hey, that’s me!
Try this:
<?php
/*
Plugin Name: Force Login
Description: No one can see your forums unless they are logged in.
Plugin URI: https://bbpress.org/forums/topic/694
Author: Michael D Adams
Author URI: http://blogwaffe.com/
Version: 0.7
*/
function force_login_init() {
if ( !bb_is_user_logged_in() && false === strpos($_SERVER['REQUEST_URI'], 'bb-login.php') && false === strpos($_SERVER['REQUEST_URI'], 'bb-reset-password.php') ) {
bb_load_template( 'login.php' );
exit;
}
}
add_action( 'bb_init', 'force_login_init' );
?>