zznic Posted March 20, 2013 Share Posted March 20, 2013 Good day, I have a problem in the admin panel since a couple of days, when I go to the statistics and enter the connected users it always says there is one and when I clic on the lid it shows none, like nobody is connected or has been connected in the last few minutes. What is the problem and how can I fix it? Thanks in advance for your help regards Nicola Quote Link to comment Share on other sites More sharing options...
bsmither Posted March 20, 2013 Share Posted March 20, 2013 There is always you who is online. The column Is Admin? should have a green check. When you click the link that is just after the location, you are taken to that location. What do expect to see when you get this page? Please describe what you think is the problem, that is, what you see versus what you think you should see. Quote Link to comment Share on other sites More sharing options...
zznic Posted March 20, 2013 Author Share Posted March 20, 2013 Hi BSmither, I clik on statistics and I expect to see 20, 15, 25 or 150 people online, like it used to be three days ago. Now there's only one and no links are shown either, not even for that single one. The administrator has a green check Hope this helps tx, ciao Nicola Quote Link to comment Share on other sites More sharing options...
bsmither Posted March 21, 2013 Share Posted March 21, 2013 Using a utility like phpMyAdmin, would you please view the database directly, the table CubeCart_sessions. We need to compare how many records are in this table versus what shows up in the admin Statistics, Users Online list. According to the code, only visitors who last viewed a page not any later than 30 minutes ago will be in the list. Quote Link to comment Share on other sites More sharing options...
zznic Posted March 21, 2013 Author Share Posted March 21, 2013 BSmither, I seem to have solved the problem through the manteinance tool. Thanks, ciao Nicola Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted March 21, 2013 Share Posted March 21, 2013 Glad you fixed it, but it might help someone in the future if you explained what you did. I'm assuming it was a cache issue, but did you change browsers or some other action that could have precipitated this odd CC behavior? Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted November 21, 2013 Share Posted November 21, 2013 I've been having an issue with not seeing the usual time frame of users online since I upgraded plushcatalog to 5.2.4. Dirtybutterestates, also on 5.2.4, still shows 12 hours worth, but I can only get 30 minutes to show on plushcatalog, even though the database has 120 records in _sessions. I'm using the same statistics.index.inc.php file for both sites. Any suggestions about where else the problem could be? Quote Link to comment Share on other sites More sharing options...
bsmither Posted November 21, 2013 Share Posted November 21, 2013 I can't find any where else that would affect the time elapsed parameter for the query to pull records from the database. In statistics.index.inc.php, near the bottom, find: // Customers Online $timeLimit = time()-1800; // 30 minutes The 1800 number (might be different for your needs) is the same for both stores? "The database has 120 records in _sessions." But what are the values in the 'session_last' column? Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted November 21, 2013 Share Posted November 21, 2013 Record 1 is 1385052850 Record 94 is 1385056530 Quote Link to comment Share on other sites More sharing options...
bsmither Posted November 21, 2013 Share Posted November 21, 2013 In the file /classes/class.session.php, near line 540, find: // Purge sessions older than the session time out Database::getInstance()->delete('CubeCart_sessions', array('session_last' => '<='.(time() - $this->_session_timeout)), false); This purges records older than the session timeout, which, unless you changed it near the top of this file, is one hour. Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted November 21, 2013 Share Posted November 21, 2013 Actually I have it set for 12 hours, and I'm certainly not getting that! My line 540 looks just like you have above. Quote Link to comment Share on other sites More sharing options...
bsmither Posted November 21, 2013 Share Posted November 21, 2013 You've not split the time between ADMIN_CP and otherwise? $this->_session_timeout = (ADMIN_CP) ? 60 * 60 * 168 : 60 * 60 * 168; // Admin : Customer session length in hours Realize that when a customer's page is delivered, and the customer's session closes (not the same as destroyed), the session getting closed (any session) will cause the database _session table purge according to the session_timeout of that session. That is to say, if your customers have a 60 minute session_timeout, your customer is causing the table to be purged of all records older than 60 minutes. Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted November 21, 2013 Share Posted November 21, 2013 //LINE BELOW IS COMMENTED OUT IN 5.2.4 - UNCOMMENTED PER CONVICT $this->_session_timeout = (ADMIN_CP) ? 3600 * 24 : 3600 * 1; So THiS is the culprit?? This line is still commented out in dirtybutterestates. Quote Link to comment Share on other sites More sharing options...
bsmither Posted November 21, 2013 Share Posted November 21, 2013 More towards the top of the file is where $_session_timeout is declared: private $_session_timeout = 3600; So, unless some other statement assigns a value to it (like the un-commented $this->_session_timeout statement), 3600 seconds (1 hour) will be the time span used to purge the table (and also be the idle-time session timeout). Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted November 21, 2013 Share Posted November 21, 2013 Both stores have this: private $_session_timeout = 604800; Quote Link to comment Share on other sites More sharing options...
bsmither Posted November 22, 2013 Share Posted November 22, 2013 Getting back to post#8, I don't see you telling us the value you have there. 4:54PM and 5:55PM UTC, and you posted at :46 after the hour, so -- I don't know what that means. Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted November 22, 2013 Share Posted November 22, 2013 I edited the post when I realized I needed to sort before I determined the oldest and the newest times. I'll try giving you the data points again tomorrow. Quote Link to comment Share on other sites More sharing options...
bsmither Posted November 22, 2013 Share Posted November 22, 2013 In post#8, I am referring to: "The 1800 number (might be different for your needs) is the same for both stores?" Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted November 22, 2013 Share Posted November 22, 2013 Both stores have // Customers Online $timeLimit = time()-43200; // 1800=30 minutes Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted November 25, 2013 Share Posted November 25, 2013 I don't understand why, but commenting out the line I mentioned in post #13 FIXED it. I couldn't find the thread where the reason FOR uncommenting it was suggested by Convict. I usually do a better job of documenting why I make these kinds of suggested changes, so I'm at a loss. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.