How to redirect to login page when user not loggedin on a particular page
From what I see, you just need to change the if in your redirect_user() function to: // List of Page slugs of the particular pages in question. $pages = array( ‘page-slug’, ‘another-slug’, ‘etc-etc’ ); // .. or specify a list of Page IDs: array( 1, 2, 3, … ) // Redirect only if the current … Read more