inovve

Magento Admin Login not working on WAMP localhost

Jan 16th, 2013
198
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.81 KB | None | 0 0
  1. If you install Magento on localhost WAMP you cannot login to admin section due to cookie valiting the domain, since localhost is not a valid domain you must:
  2.  
  3. Go to app/code/core/Mage/Core/Model/Session/Abstract/Varien.php go to line 85 and find the code:// session cookie params
  4.  
  5. $cookieParams = array(
  6. ‘lifetime’ => $cookie->getLifetime(),
  7. ‘path’ => $cookie->getPath(),
  8. ‘domain’ => $cookie->getConfigDomain(),
  9. ‘secure’ => $cookie->isSecure(),
  10. ‘httponly’ => $cookie->getHttponly()
  11. );
  12.  
  13. comment the last three array elements as here:
  14.  
  15. // session cookie params
  16.  
  17. $cookieParams = array(
  18. ‘lifetime’ => $cookie->getLifetime(),
  19. ‘path’ => $cookie->getPath(),
  20. //’domain’ => $cookie->getConfigDomain(),
  21. //’secure’ => $cookie->isSecure(),
  22. //’httponly’ => $cookie->getHttponly()
  23. );
Advertisement
Add Comment
Please, Sign In to add comment