• fredsbend

    (@fredsbend)


    I’ve set it to popup with <a class="xoo-el-action-sc xoo-el-login-tgr"> in two places, one for desktop and one for mobile responsive.

    The popup shows for both but will not redirect after login.

    On desktop, it gives a successful login message, but no redirect. I’ve temporarily gotten around this by having the login success message include a link to the redirection page. Users can click for now.

    On mobile, it will not give a successful login message and no error message. Just spins and spins. I have no workaround for this; my mobile users cannot log in.

    Any ideas?

    The exact code is:

    Desktop:

    <li><a onmouseout="RemoveActive(this.id)" onmouseover="ShowDropBox('9557',this.id)" class="xoo-el-action-sc xoo-el-login-tgr" id="login">Login</a></li>

    The extra stuff is for hover styles, tying in to what my site menu already does.

    Mobile:

    <p><a class="xoo-el-action-sc xoo-el-login-tgr">Click Here to Log in</a></p>

    This is in a plain post. Nothing special going on.

    WP Version 5.3.2
    PHP Version 5.6.40 – Maybe the issue? WP wants me to update PHP

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author xootix

    (@xootix)

    Hello @fredsbend

    How you open the popup doesn’t affect redirection functionality.
    As long as you have not made any changes to the login/signup form, it should work fine.
    PHP 5.6.4 has no compatibility issues.
    Something else is causing the issue.
    Please share your website link.

    Thread Starter fredsbend

    (@fredsbend)

    My website

    You can click the login link at the top menu, or on that page itself.

    Thank you,

    Thread Starter fredsbend

    (@fredsbend)

    Okay, I now have the redirect hard coded.

    Line 76 in class-xoo-el-form-handler.php says:

    'notice' => xoo_el_add_notice('success','<i class="fa fa-check-circle" aria-hidden="true"></i> <p><a href="/my-account/">Click here if you are not redirected in a few seconds.</a></p><script>setTimeout(window.location = "/my-account/", 1000);</script>'.__('Login successful')),'redirect' => $redirect);

    It will redirect now, but the styles are goofy.

    Mobile still just spinning. I’ve only tested Android Chrome, btw.

    Thread Starter fredsbend

    (@fredsbend)

    Okay, I wasn’t sure if I broke something unintentionally. I wasn’t sure what the original behavior was before I started fiddling. I deleted the plugin and reinstalled. Original behavior was that login on Desktop and mobile was successful, but redirect would not happen on either.

    I have accomplished a redirect on both, but there’s some style issues I might work on in the future.

    Here’s what I changed:

    xoo-el-login-section.php Line 60

    <input type="hidden" name="redirect" value="<?php echo $redirect; ?>">
    	changed to
    <input type="hidden" name="redirect" value="/my-account/">

    A few other items I hard code changed as well, but they were simple message type things, piggybacked on other messages already in your code.

    At this point, it’s working well enough for me, so you don’t have to commit any more time to this support request. Thank you for your help.

    Hello Fredsbend?
    I had the same problem but to me just the desktop is enough, I tried to put your code: <input type=”hidden” name=”redirect” value=”/my-account/”>
    Instead /my account/ another address.
    But nothing… do you know if I cab change something more?

    Thank you so much for you help???

    Thread Starter fredsbend

    (@fredsbend)

    @cofhugo Sorry, I’m kind of flying by the seat of my pants here already. I’m better than novice with this coding stuff, but still very much an amateur. I only noticed your comment because I came back to find out what I did. The last update undid my changes. I hope you worked out your issue, and maybe it was even a better solution than mine.

    For others reading, xoo-el-login-section.php is found in /wp-content/plugins/easy-login-woocommerce/templates/global/

    I also found it useful to update line 75 in class-xoo-el-form-handler.php found in /wp-content/plugins/easy-login-woocommerce/includes/

    $success_notice = apply_filters( 'xoo_el_login_success_notice', '<i class="fa fa-check-circle" aria-hidden="true"></i> '.__( 'Login successful', 'easy-login-woocommerce' ), $user );
    to 
    $success_notice = apply_filters( 'xoo_el_login_success_notice', '<i class="fa fa-check-circle" aria-hidden="true"></i> '.__( 'Login successful <p><a href="/my-account/">Click here if you are not redirected in a few seconds.</a></p>', 'easy-login-woocommerce' ), $user );
    • This reply was modified 4 years, 10 months ago by fredsbend.
Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Will not redirect after login’ is closed to new replies.