• Resolved wp_muro

    (@wp_muro)


    I can’t get this plugin’s redirects to work with nginx. It was working correctly with apache’s .htaccess rules, listed below.
    Even without any rules, the login page at /login will show up.
    When the form submits, which is going to /login, it never sets the cookie and never logs in.

    @nginx rules
    location /login { return 200 /wp-login.php?; }
    location /passwordreset { return 200 /wp-login.php?action=lostpassword; }
    location /join { return 200 /wp-login.php?action=register; }
    location /logout { return 200 /wp-login.php?action=logout; }

    my old .htaccess rules from Apache
    RewriteRule ^login /wp-login.php [QSA,L]
    RewriteRule ^passwordreset /wp-login.php?action=lostpassword [QSA,L]
    RewriteRule ^join /wp-login.php?action=register [QSA,L]
    RewriteRule ^logout /wp-login.php?action=logout [QSA,L]

    With the plugin enabled, when I attempt to load: /wp-login.php it redirects to /login.
    This is the same behavior with or without nginx rules. Seems like the POST is not making it to the wp-login.php routine. Anyone see this issue before, or have this issue solved?

    Much appreciated.

    https://ww.wp.xz.cn/plugins/custom-login/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Austin

    (@austyfrosty)

    Hello, I am not familiar with NGINX rules. But Custom Login doesn’t manage any rewrites or redirects.

    The /login redirect is a core WordPress feature, which will always redirect to wp-login.php.

    Thread Starter wp_muro

    (@wp_muro)

    Thanks – we are trying the profile builder plugin, as to create custom login and profile pages. These redirects were disabled and handled with a wp_login filter instead.

    // login redirect to home url
    add_filter( ‘login_redirect’, create_function( ‘$url,$query,$user’, ‘return home_url();’ ), 10, 3 );

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Help – Does this work with NGINX?’ is closed to new replies.