• Hello

    (@themophiles)


    I have recently started using Ajax baseg login option provided by my new theme.

    When I tried to login, I successfully logged in, but once I try to open the dashboard or profile or to write a new posts – they automatically redirects to a new page which asks to sign in again and so on-

    Here is the flow chart.

    – I logged in using Top login Modal from my website mydomain.com

    – I successfully logged in and then I try to open the dashboard , the url is: https://mydomain.com/wp-admin/

    but it automatically redirects to :

    https://mydomain.com/login/?redirect_to=https%3A%2F%2Fmydomain.com%2Fwp-admin%2F&reauth=1

    – then I try to open my profile- the url is: https://mydomain.com/wp-admin/profile.php

    But after clicking it, it automatically redirects to this page: https://mydomain.com/login/?redirect_to=https%3A%2F%2Fmydomain.com%2Fwp-admin%2Fprofile.php&reauth=1

    Now let me be clear on this, the redirected page is a working login and once I re-login here. It works perfectly well. The only is why it is asking for re-alogin or re-authorisation? Why doesn’t it treat Ajax based login as final login.

    once I login again using this default WordPress panel at this redirected loginpage: https://mydomain.com/wp-login.php?redirect_to=https%3A%2F%2Fmydomain.com%2Fwp-admin%2F&reauth=1 , everything starts working well. Now no matter whether you click the same dashaboard or your profile link from the top bar menu, it always works fine.

    Looking at the same issue from a different angle I mean suppose you first logged in through https://mydomain.com/wp-login.php or https://mydomain.com/wp-admin.php , at this time you won’t face any issue in login . Now visit the homepage. Now the homepage still have the same black dashboard top most bar with all same option ( means to click on Dashboard, or click Edit User Profile) and if you click any of them , you won’t find any issues with it. I mean there will no such redirection or re-authorisation again. So, if you click “Dashboard” the original url is https://mydomain.com/wp-admin and it will also open https://mydomain.com/wp-admin without any issue.

    What I am trying to say is that there is no such redirections set anywhere because if it would have been it should always give the error. After deactivating and deleting all plugins, I can almost definitely say that somehow “Wordpress always needs a reauthorisation when someone tries to see the backend when logged in through your Ajax based login popup menu. It works fully well for the front end, but once someone click/request any backend links, it starts asking for re-login”

    I am not sure, how much are you getting me but after doing all kinds of checking , I don’t there is any issue with any plugin or hidden redirection rules on my website ( at least logically). I think, there is something you need to look in the codes of the behaviour of this ajax based login menu.

    After reading a lot of threads, it appears that this has somehow related to my use of TML plugin, though I tried deactivating it, but I am still getting this. Can you help to get rid of this situation.

    Thank you.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Jeff Farthing

    (@jfarthing84)

    If you deactivate TML and use this modal login, does it work?

    Thread Starter Hello

    (@themophiles)

    Hey, Thanks for this reply.

    I tried deactivating as well as deleting the TML but still modal login is not working. To better understand the issue. Have a look at this recorded GIF : https://imgur.com/nx42V2G Notice at the last point. Even though Ican successfully logged in ,it still asked to re-login when one tries to visit backend dashboard or to edit their profile etc.

    I have tried deactivating all plugins but nothing works…

    Please help.. to diagnose it.. like which files I should to check or modify. Can it be prevented using code in HTACCESS or functions.php ?

    Thank you.

    Hello, did you found out the solution? Its also happening with on one my client’s website hover the same setup is working fine on my Server..

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘wp-admin&reauth=1 redirect while using ajax based login’ is closed to new replies.