The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
who's online on other pages?
hi ^^
I was wondering if there's a way to incorporate the 'who's online' feature on all my php pages. it would be cool to be able to know who's reading our comics ^^ here, my site, http://darkroomfiction.com ** doing big puppy dog's eyes** |
#2
|
||||
|
||||
Include this in all your scripts:
PHP Code:
PHP Code:
Also in functions_online.php FIND PHP Code:
|
#3
|
||||
|
||||
Quote:
that will show what's people doing on online.php right? how can I also show who's on each pages like in showthread as well? |
#4
|
||||
|
||||
hmmm.. I just tried it and (after fixing chdir typo and placing it in an area where it didn't affect any of my other include scripts) it didn't work.
I visit the who's online section and nothing comes up about people viewing the default index.php home page in the root dir. am I not doing something right? |
#5
|
||||
|
||||
Hmm ...
Does it work if you use require_once('./global.php'); instead of init.php? ? |
#6
|
||||
|
||||
That worked ^_^
I also noticed some other things too. I did some 'static' coding into the file to get it to recognise all my pages properly, as the original version only recognises the 'filenames', not the full path or data that comes with the url after the '?'. Thanks a bunch for your help! Really appreciate it. |
#7
|
||||
|
||||
Quote:
If you want to display more detailed information about where your visitors are (eg. based on some specific parameters) this will become a bit more tricky ... So if you want this send me a PM with some more details (eg. filenames, parameters, etc) and i'll see what I can do for you. |
#8
|
||||
|
||||
Thanks for the offer, but managed to get it working finally.
Did some tweaking and some experimenting and managed to get it to do exactly what I wanted. See, I needed it to recognise the full path, otherwise, the script got confused. My index page at the root of my site is index.php and that handles all my site pages for me (data parsed to it via the url). So, by only passing the filename, the script couldn't tell the difference between index.php in my root folder and index.php in my forum folder. But using some if statements inside the index case and using the userinfo[location] array, I was able to get it to direct the activity to the right cases. But I couldn't have done it without your code. I didn't even know where to start, so again, thanks a bunch PS. just to let you know, the first message was posted by Shari herself, but the rest were posted by me, Fred, the dude who does the coding on our sites ^_~ I just didn't have my own login for this forum. |
#9
|
|||
|
|||
Does this work for pages that are located on another domain?
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|