This website can use cookies to improve the user experience

This website can use cookies to improve the user experience and to provide certain services and functions to users. Cookies contain small amounts of information (such as login information and user preferences) and will be stored on your device.

Enable All Cookies Privacy Policy

Online users mod


avatar
Rushian 0
From: -
Online users mod

I have duplicated the Online Users info box that is at the top of the forums on my main page (ie. site header), but it 'goes blank' when viewing someone's proifile.

For example, if there are 2 users online (Rushian and DrEvil), if I view DrEvil's profile, the users online box says there are 0 users and 0 guests online even though there are 2 of us online. Going to any other module then updates the list correctly again.

Can that be fixed somehow?

Notice

This topic is archived. New comments cannot be posted and votes cannot be cast.

Responses to this topic


1 Re: Online users mod
avatar
OP 0
From: -
Online users mod

Works!

I used method #1 since it's better to mod my external code rather than the core code. Smiling Face

Thanks!
1 Re: Online users mod
avatar
Administrator
1340
From: Vienna, Austria
Online users mod

Yes, this is caused by $website.

There are two fixes:

1) You replace the SQL in the template with:

$result = DBQuery("SELECT online_user FROM esselbach_st_online ORDER BY online_user");

or

2) You add the following line after require("core.php"); in profile.php:

    $website = $configs[4];
1 Re: Online users mod
avatar
OP 0
From: -
Online users mod

Yes. Winking Face

I copied it to an external script that is included into the site_footer template.

Hmm, I wonder if it has something to do with $website var (which I made global in site_footer) or some other ver collision when the view profile module runs..
1 Re: Online users mod
avatar
Administrator
1340
From: Vienna, Austria
Online users mod

You added the entire online users code from forum_overview_header to site_header?

Notice

This topic is archived. New comments cannot be posted and votes cannot be cast.