Getting error log for every URL hits in magento1.7
-
12-12-2019 - |
Question
I am getting this error log for any url hit in my magento..What could be the reason and how to solve this?
2014-11-14T07:49:47+00:00 ERR (3): Notice: Undefined variable: cookieParams in /var/www/beta_dev/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php on line 94
2014-11-14T07:49:47+00:00 ERR (3): Notice: Undefined variable: cookieParams in /var/www/beta_dev/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php on line 95
2014-11-14T07:49:47+00:00 ERR (3): Notice: Undefined variable: cookieParams in /var/www/beta_dev/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php on line 96
2014-11-14T07:49:47+00:00 ERR (3): Notice: Undefined variable: cookieParams in /var/www/beta_dev/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php on line 97
2014-11-14T07:49:47+00:00 ERR (3): Notice: Undefined variable: cookieParams in /var/www/beta_dev/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php on line 98
2014-11-14T07:49:47+00:00 ERR (3): Notice: Undefined variable: cookieParams in /var/www/beta_dev/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php on line 99
2014-11-14T07:49:47+00:00 ERR (3): Notice: Undefined variable: cookieParams in /var/www/beta_dev/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php on line 108
2014-11-14T07:49:47+00:00 ERR (3): Warning: call_user_func_array() expects parameter 2 to be array, null given in /var/www/beta_dev/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php on line 108
Solution
At a guess you have edited your core, as that variable is defined.
Restore a clean, unmodified copy of the core.
OTHER TIPS
I found the solution..
// session cookie params
/*$cookieParams = array(
'lifetime' => $cookie->getLifetime(),
'path' => $cookie->getPath(),
'domain' => $cookie->getConfigDomain(),
'secure' => $cookie->isSecure(),
'httponly' => $cookie->getHttponly()
);*/
This makes the problem.so after uncomment this variable ,my problem solved..
// session cookie params
$cookieParams = array(
'lifetime' => $cookie->getLifetime(),
'path' => $cookie->getPath(),
'domain' => $cookie->getConfigDomain(),
'secure' => $cookie->isSecure(),
'httponly' => $cookie->getHttponly()
);
No need to mod core file!!!!
Try these settings in : System > Config > Web
Cookie Lifetime: 86400 Cookie Path: / Cookie Domain: Your Domain Use HTTP Only: YES Cookie Restriction Mode: No
Important settings is HTTP Only: YES.
Licensed under: CC-BY-SA with attribution
Not affiliated with magento.stackexchange