Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- add_filter('wpf_redirect_url', 'wpf_redirect_users', 10, 2);
- function wpf_redirect_users($redirect, $post_id) {
- if(is_user_logged_in()) {
- return $redirect;
- } else {
- return 'http://mysite.com/login';
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement