X-Cart Mods, X-Cart Addons - WebsiteCM
Did you know...
You can receive a volume
discount by purchasing multiple modules. View our volume discount page for details.
X-Cart Excellence eZine
Subscribe for proven tips and special discounts!
Cart is empty
X-Cart Services
X-Cart Customization X-Cart Optimization
X-Cart Mods
Recommended Packages Must Have Mods Reseller Program
Filter Mods By Version
Mods By Purpose
X-Cart Administration X-Cart Packages X-Cart Appearance X-Cart Conversion X-Cart Customers X-Cart Integration X-Cart Marketing X-Cart Navigation X-Cart Search X-Cart SEO X-Cart Shopping Feeds X-Cart Upselling X-Cart Templates
Mods By Firm
WebsiteCM BCSE Firetank

WebsiteCM on Twitter

Modify Accuracy of X-Cart's Who's Online

Modify Accuracy of X-Cart's Who's Online
Category: X-Cart Tutorials
Posted: Feb 2, 2010
Synopsis: X-Cart's "Who's Online" is commonly considered in-accurate. This posting allows you to increase or decrease the accuracy of this x-cart feature.

X-Cart's "Who's Online" feature is commonly considered "in-accurate"  because it records all users who open a page with a 30-minute time period.   This time frame can be reduced to make the module more accurate, or extended to create the "illusion" of a busier store, with the following code changes provided by Eugene on the x-cart forums:

How to make this x-cart module more accurate:

Open modules/Users_online/registered_user.php

Find:

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

Replace with:

$expiry_time = $curtime + 300; // 5 minutes instead of default session length

How to make this x-cart module less accurate:

Open modules/Users_online/registered_user.php

Find:

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

Replace with:

$expiry_time = $curtime + 3600; // 60 minutes instead of default session length





Site Map