X-Cart Mods, X-Cart Addons - WebsiteCM
Did you know...
We offer a Community Forum to learn, build, and share with other users of x-cart software?
X-Cart Excellence eZine
Subscribe for proven tips and special discounts!
Cart is empty
View X-Cart Mods
Filter Mods By Version
XCart Mods (4.2.x)
XCart Mods (4.1.x)
XCart Mods (4.0.x)
XCart Mods (3.5.x)
XCart Mods (3.4.x)
View All
Mods By Purpose
Mods By Firm

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


Friday, April 11, 2008


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





<< Live Chat X-Cart Support >>
digg
technorati
Delicious
Reddit
Google Bookmarks
Furl it!

Live Help

Site Map