Hello,
Installed fresh version of opencart 2.1 version. changed my design etc and time from time was getting this error.
At the time it was annoying but did not bother me a lot.
Now the time to upload my products. From admin panel I am inserting all information needed, adding the picture, however once clicking SAVE it logs me out automatically, redirects to admin log in page and gives an error: Invalid token session. Please login again.
Now it is annoying, as I literally cannot add any products as it ALWAYS logs me out. Tried clearing cookies etc, changing user login details, adding new user and so on.
Any suggestions on how to sort this out?
Thanks.
I have this same problem!
It's infuriating!!
My problem started when I tried to switch my e-commerce site to a new host (iPage). I installed Opencart 1.5.6 onto the new server and copied over the database and the backed-up store. Nothing I did could get it to work, not even the online help advisors could assist. It should have been straight forward with FTP - none of the files or the file structure changed...
I finally threw in the towel and installed Opencart 2.0 on the server and have had to completely re-do my store, from scratch. I could live with this frustration because I wanted to change the look of the store anyway.
However, whilst I'm trying to update categories, products, in fact anything, I keep getting an 'invalid token session' error! It seems to appear randomly, but frequently, meaning it's taking 10 times longer to create the store than with the 1.5.6 version of the software.
Can anyone help?
It's infuriating!!
My problem started when I tried to switch my e-commerce site to a new host (iPage). I installed Opencart 1.5.6 onto the new server and copied over the database and the backed-up store. Nothing I did could get it to work, not even the online help advisors could assist. It should have been straight forward with FTP - none of the files or the file structure changed...
I finally threw in the towel and installed Opencart 2.0 on the server and have had to completely re-do my store, from scratch. I could live with this frustration because I wanted to change the look of the store anyway.
However, whilst I'm trying to update categories, products, in fact anything, I keep getting an 'invalid token session' error! It seems to appear randomly, but frequently, meaning it's taking 10 times longer to create the store than with the 1.5.6 version of the software.
Can anyone help?
I have this exact issue. As the developer working on this site its infuriating every time hitting save icon or refresh icon getting bounced back to the login screen. I have googled high and low for a fix for the issue.
Making it worse I am the server host, We have this running on a dedi in a mainstream DC in the UK running cpanel 11 so I know full well its not the server causing the issue.
I would be greatfull if any one knows a fix for this!
Making it worse I am the server host, We have this running on a dedi in a mainstream DC in the UK running cpanel 11 so I know full well its not the server causing the issue.
I would be greatfull if any one knows a fix for this!
Try the fix on this link.
http://stackoverflow.com/questions/8311 ... out-in-php
This part.
You can add it on system/library/session.php
Add it after this code
ini_set('session.cookie_httponly', 'On');
http://stackoverflow.com/questions/8311 ... out-in-php
This part.
Code: Select all
// server should keep session data for AT LEAST 1 hour
ini_set('session.gc_maxlifetime', 3600);
// each client should remember their session id for EXACTLY 1 hour
session_set_cookie_params(3600);
Add it after this code
ini_set('session.cookie_httponly', 'On');
Opencart Options Pro, Reward Points For Review, DISQUS Comment Form,
Dolrich Fortich - Freelance web developer
Tried this fix still getting logged out on every save. this can be product, settings worse still the error log shows nothing, Server logs only showing no default file in the image directory so this is completly unrelated
Completly at a loss for how to stop getting logged out every time i save any thing, any help would be much appreciated! using Journal2 front end theme how ever i wouldn't assume that would cause admin session bugs
Session.php now reads[Thu Sep 10 13:02:46.991233 2015] [autoindex:error] [pid 169891] [client **.**.**.**] AH01276: Cannot serve directory public_html/image/: No matching DirectoryIndex (index.html.var,index.htm,index.html,index.shtml,index.xhtml,index.wml,index.perl,index.pl,index.plx,index.ppl,index.cgi,index.jsp,index.js,index.jp,index.php4,index.php3,index.php,index.phtml,default.htm,default.html,home.htm,index.php5,Default.html,Default.htm,home.html) found, and server-generated directory index forbidden by Options directive
Code: Select all
public function __construct() {
if (!session_id()) {
ini_set('session.use_only_cookies', 'On');
ini_set('session.use_trans_sid', 'Off');
ini_set('session.cookie_httponly', 'On');
// server should keep session data for AT LEAST 1 hour
ini_set('session.gc_maxlifetime', 3600);
// each client should remember their session id for EXACTLY 1 hour
session_set_cookie_params(3600);
session_set_cookie_params(0, '/');
session_start();
}
Who is online
Users browsing this forum: No registered users and 142 guests