Jump to content

Community

Recommended Posts

Yes.

Open: /applications/core/widgets/whosOnline.php and find:

array( 'core_sessions.running_time>' . \IPS\DateTime::create()->sub( new \DateInterval( 'PT30M' ) )->getTimeStamp() )

change value 30 to 60 and save

Share this post


Link to post
Share on other sites

If I recall it's a php limit on how long it tracks a session which is 24 minutes by default. So setting a higher number in the widget won't do anything really.

session.gc_maxlifetime (php.ini)

Edited by AutoItScript

Share this post


Link to post
Share on other sites

If I recall it's a php limit on how long it tracks a session which is 24 minutes by default. So setting a higher number in the widget won't do anything really.

session.gc_maxlifetime (php.ini)

​right.

@Charles or someone plan to add some option for this?

Share this post


Link to post
Share on other sites

The reason why this matters is that it would look bad to people on the site to think traffic dropped after an upgrade when all that happened was that it was previously counting a longer time. It could be detrimental to a community.

Share this post


Link to post
Share on other sites

I think I may have this figured out. Just giving it some more time to make sure. I created a file and added session.gc_maxlifetime = 36000 to it to test this(I'll lower it if the test works). You'll have to save that file as either php.ini, php5.ini, or .user.ini depending on what you're using and put that in your root.

It's kept people on the online list for two and a half hours so far without issue.

Just FYI, I'm not an expert at this. I think the risk is low but just wanted to pass it along. I think the biggest risk to this is session hijacking since they have more time.

This whole thing makes me wonder why it isn't programmed to base it on the last time that person was online instead of active sessions. Maybe that's more resource intensive to do it that way? It would provide more flexibility to something like this. 

Edited by theblackelk

Share this post


Link to post
Share on other sites

Last try. I've added php_value session.gc_maxlifetime 36000 to my .htaccess file. Up to over three hours now in the count. Will update tomorrow to say whether or not it worked overnight.

Share this post


Link to post
Share on other sites

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...