• is it possible to redirect to another domain/redirect.html while working on WordPress and able to see the WordPress website or do I need a WordPress plugin for that?

Viewing 1 replies (of 1 total)
  • Hi!
    There are some plugins that can do that for you: redirect visitors that are not logged in to a certain page, but you can do that yourself, by adding a few lines of code in header.php file (using FTP or Theme Editor):

    if (!is_user_logged_in()) {
    
    wp_redirect('https://yoursite.com/yourpage');
    
    exit();
    
    }

    Let me know how this goes.
    Good luck!
    Vlad

    • This reply was modified 4 years, 3 months ago by Vlad T.
Viewing 1 replies (of 1 total)
  • The topic ‘redirect’ is closed to new replies.