Log in

View Full Version : Have custom pages, no active users


VodkaFish
01-31-2007, 12:50 AM
I've built some custom pages off of vb. The pages include global.php, call some templates, but anyone who visits these pages isn't listed on the active users list. Do I need to include another file? Is it possible to define where the users are in each page? Or maybe through a few hooks? One thing to note: these pages are not within the main forum directory.

webmazter
01-31-2007, 03:13 AM
you will need to update the session to include where they're currently on your site.

I think the variable is this

$userinfo['location']


I haven't tested. :)

VodkaFish
01-31-2007, 03:41 AM
Thanks for the suggestion. I tried setting that ($userinfo['location'] = "wherever";) on my page, above where global.php is called, and the user still isn't listed.

webmazter
01-31-2007, 08:44 AM
not that simple.

You need to update the session table with the current location of the user.

VodkaFish
02-02-2007, 03:48 AM
Is there another page you can suggest I look at? I'd love to have a code sample to work off of.

I thought any inclusion of global.php added a user to the active users table. I'm really confused since I have one page where users do wind up on the list and I'm not sure exactly what code is triggering it.

VodkaFish
02-07-2007, 05:57 PM
Well, I haven't made much progress, but I have found a workaround. I create a blank template and then call it at the end of everything I do:
eval('print_output("' . fetch_template('BLANK') . '");');

I haven't been able to find exactly how my other pages that don't use print_output are updating the session table, but they are. I just hope this doesn't bog down the site any, as these pages are pretty active.