Topic #3415 (no title)

Image

(Click to enlarge)

#2510 - Browser and OS not showing on main site, but showing on MSN

This is a spacer post for a website comment topic. The content this topic relates to: #2510 - Browser and OS not showing on main site, but showing on MSN
Likely one site has stats installed and one does not. This data comes out of the stats table.
Both sites are default installs from Git, I have not turned any addons or settings on or off. The main site didn't show it, the MSN site did.
Ok, but it's a different data table anyway - so there'd be some kind of logical reason rather than a bug, not sure what, but I don't think an investigation is needed.
Not seeing this info on my profile on RC8 either, fresh install. Weird.
Tried reopening this, doesn't seem to work. I do think there is an issue here.
This is the code:

if (((has_privilege($member_id_viewing, 'show_user_browsing')) || ($member_id_viewing == $member_id_of)) && (addon_installed('stats'))) {
$last_stats = $GLOBALS['SITE_DB']->query_select('stats', array('browser', 'operating_system'), array('member_id' => $member_id_of), 'ORDER BY date_and_time DESC', 1);
if (array_key_exists(0, $last_stats)) {
$user_agent = $last_stats[0]['browser'];
$operating_system = $last_stats[0]['operating_system'];
}
}


There are various cases here for the data not showing, all legitimate:
- User neither has "show_user_browsing" privilege on the site being viewed from nor is viewing their own profile
- stats addon is not installed on the site being viewed from
- No stats data is available on the site being viewed from for that member
- for example because it's configured to not hold long


I'd need to know that a user was being tried who had visited from both sites, that stats was on both sites, and that that user definitely was privileged on both sites or viewing their own profile on both sites.

Just the one site, no MSN this time, and it's the admin account I am not seeing these details on.
Ok, maybe this is why:

if ((get_option('site_closed') == '1') && (get_option('stats_when_closed') == '1')) {
return;
}

If the site is closed and "Collect stats when closed" is not checked, those details won't be gathered.
That would explain it. I didn't make the link that stats meant the browser and OS. I assumed that was just hit counting and Alexa ranking, etc. Mystery not so mysterious anymore :)
1 guest and 0 members have recently viewed this.