Qwoon Posted March 27, 2021 Share Posted March 27, 2021 (edited) Hello, everyone! I recently picked up all my files from remote server, got my SQL dump files and tried to set up a local environment to develop new features and to simplify the development process for the team. We are also planning to create a QA server, but while this issue persists locally I doubt that we can create a QA server. On my local machine I am using Open Sever (also tried WAMP). The problem I get is when trying to log in to the BO. Entering the right credentials changes the URL to redirect=AdminDashboard, but I am not being redirected to the dashboard, which means I am stuck on the login page. Here are the steps I have already done to migrate from remote server locally 1. Downloaded all the files via FTP; 2. Imported the database with all my data besides products (and all tables that are relates, like product_attribute, etc.); 3. Changed in the PS_CONFIGURATION table the following values: PS_SHOP_DOMAIN to localhost, PS_SHOP_DOMAIN_SSL to localhost, PS_COOKIE_CHECKIP to 0, PS_COOKIE_LIFETIME_BO to 0; 4. Changed parameters.php file; 5. Changed the records in the PS_SHOP_URL table to localhost; 6. Deleted all the cache from var/cache; 7. Tried removing the .htaccess file from the root; Additional Info: Prestashop Version: 1.7.7.0 Apache Version: 2.4 PHP Version: 7.3 MariaDB Version: 10.4 The issue persists between all browsers, so I doubt this is something cookie related. Thanks in advance! Edited March 27, 2021 by Qwoon (see edit history) Link to comment Share on other sites More sharing options...
musicmaster Posted March 29, 2021 Share Posted March 29, 2021 Did you read this: https://github.com/PrestaShop/PrestaShop/issues/22758 Link to comment Share on other sites More sharing options...
Qwoon Posted March 30, 2021 Author Share Posted March 30, 2021 On 3/29/2021 at 12:18 PM, musicmaster said: Did you read this: https://github.com/PrestaShop/PrestaShop/issues/22758 Hi, yes, I have tried to play around with the ICU, tried switching PHP versions also. I am thinking that this could be something module related, any ideas on that and how to debug it while having only access to the FO. Thanks. Link to comment Share on other sites More sharing options...
musicmaster Posted March 31, 2021 Share Posted March 31, 2021 This is the "admin login loop" There are dozens of forum post about it and dozens of solutions that sometimes work. Most are cookie related. Things that sometimes work are use https instead of http remove .htaccess Use localhost instead of 127.0.0.1 for server (or vice versa). If the hosting provider offers yet another address like mysite.provider.com, try that disable the option "Check the IP address on the cookie" in preferences disable multiviews try domain name with and without www set PS_COOKIE_LIFETIME_BO to 480 change $cookie = new Cookie('psAdmin', substr($_SERVER['PHP_SELF'], strlen(__PS_BASE_URI__), -10)); to: $cookie = new Cookie('psAdmin', substr($_SERVER['REQUEST_URI'], strlen(__PS_BASE_URI__), -10)); You write that you set PS_COOKIE_LIFETIME_BO to 0. I am not sure how that works out. It might be better to keep it at the default of 480 (hours). You can use Prestools to make easy changes. Under Tools&Stats->Shop Rescue there are options to easily change some relevant configuration values. The only way I would know to test whether this is module related is to rename or remove the modules trees under the /modules directory. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now