X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Dev Questions (https://forum.x-cart.com/forumdisplay.php?f=20)
-   -   More accurate 'Users Online' stats (https://forum.x-cart.com/showthread.php?t=38983)

Ene 04-10-2008 11:20 PM

More accurate 'Users Online' stats
 
I see that many users claim that 'Users Online' stats is quite innacurate.
Actually it isn't a bug, but a feature : -)
'Users Online' shows all the customers who open any page during the last 30 minutes.
Known bots are not counted. (The list of the known bots can be found in the include/bots.php file)


How to make this module accurate:

1. Open modules/Users_online/registered_user.php script.

2. Replace

PHP Code:

$expiry_time $curtime $config["Sessions"]["session_length"]; 



with

PHP Code:

$expiry_time $curtime 300// 5 minutes instead of 30 minutes 


pauldodman 04-11-2008 02:07 AM

Re: More accurate 'Users Online' stats
 
Of course you could use this to make it less accurate so that a quiet shop appears really busy to help achieve that "safety in numbers" feeling and make them spend money.

carpeperdiem 04-11-2008 02:48 AM

Re: More accurate 'Users Online' stats
 
Eugene,

Thank you for this --

Do you have any idea why my "users online" stats will also show multiple entries from the SAME IP at times? As many as 5-20 duplicate entries, from the same IP, will be listed -- not always, so it is difficult to chase down why??? It is quite annoying to see the same IP as 10 entries, all on different pages... and if they have items in their cart, it will look like each entry has the same items --

Could this issue be related to Marketing Manager Pro, or WebsiteCM's "remember me" ?

Thanks,

Jeremy

Ene 04-11-2008 02:57 AM

Re: More accurate 'Users Online' stats
 
Quote:

Originally Posted by carpeperdiem
Eugene,
Do you have any idea why my "users online" stats will also show multiple entries from the SAME IP at times? As many as 5-20 duplicate entries, from the same IP, will be listed -- not always, so it is difficult to chase down why??? It is quite annoying to see the same IP as 10 entries, all on different pages... and if they have items in their cart, it will look like each entry has the same items --


Somebody browses your site and doesn't accept cookies.
Most likely it's an unknown bot or a spider.

Could you possibly PM me this IP?

carpeperdiem 04-11-2008 03:10 AM

Re: More accurate 'Users Online' stats
 
It's not just one IP -- I see this constantly. Next time I see this, I'll PM you. Thanks

homeworldz 04-12-2008 07:37 AM

Re: More accurate 'Users Online' stats
 
What does the '300' value represent ?

carpeperdiem 04-12-2008 07:39 AM

Re: More accurate 'Users Online' stats
 
Quote:

Originally Posted by homeworldz
What does the '300' value represent ?


seconds -- note the comment "// 5 minutes instead of 30 minutes"

homeworldz 04-12-2008 07:40 AM

Re: More accurate 'Users Online' stats
 
The penny just dropped that 300 seconds is 5 minutes :)

hamid 04-15-2008 07:28 AM

Re: More accurate 'Users Online' stats
 
carpeperdiem - you get multiple instances of an ip if the visitor opens a new window or tab (for example middle clicking a link in firefox) - each window/tab starts a new session

carpeperdiem 04-15-2008 08:10 AM

Re: More accurate 'Users Online' stats
 
Quote:

Originally Posted by hamid
carpeperdiem - you get multiple instances of an ip if the visitor opens a new window or tab (for example middle clicking a link in firefox) - each window/tab starts a new session


ah... good explanation. thanks.

I paid usertesting.com to do a usability test -- and the tester kept right-clicking away. Not only was it annoying to watch her do this, but she didn't get the benefit of the navigation system in place... I tweaked my navigation after watching her do this.


All times are GMT -8. The time now is 05:32 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.