php forum
php mysql forum
php mysql smarty
 
Page 1 of 4 1 2 3 4 >
Topic Options
#202771 - 04/07/04 04:40 AM [6.7] [beta] User Online
Brett Offline
Moderator

Registered: 05/04/01
Posts: 992
Loc: Twinsburg, Ohio
Modification Name: User Online

Author(s): Brett

Description: Adds a picture in each post to indicate whether the user is active on the forum at the moment or not. Recent Visitors must be enabled.

Demo: http://www.pavioni.com/ubb/ultimatebb.php/topic/4/8.asp#000011

Download Link: http://www.ubbdev.com/ubb/upload/00006378/Online6.7.zip

Credits: LK(for the idea of javascript from the hit hack)

This works in much of the same way as the hit hack, so the cache is safe. wink After install, clear the 'Topic Pages' cache.

Top
#202772 - 04/07/04 04:51 AM Re: [6.7] [beta] User Online
LK Offline
Admin / Code Breaker

Registered: 03/24/01
Posts: 7396
Cool, good job! Going straight into my board.
By looking at the code, though, I think it also shows online state for invisible users, which don't want to appear online...
you might try (untested)
Code:
if($r->{$uniq}->{login}->[1] == 1) {
before the last part of online.cgi.
_________________________

My Hacks Page (will be back with UBB 7!)
UBBDev - We put the class into UBB.classic!

Top
#202773 - 04/07/04 05:35 AM Re: [6.7] [beta] User Online
Brett Offline
Moderator

Registered: 05/04/01
Posts: 992
Loc: Twinsburg, Ohio
It looks like it might be the 2nd(3rd technically wink ) placement in the login array
Code:
$r->{$uniq}->{logins}->{$uniq} = [$user_number, $nologin, $hidden, $daysprune];
as the hidden variable? At least i'm pretty sure it is.

Updated online.cgi. laugh

Top
#202774 - 04/07/04 05:45 AM Re: [6.7] [beta] User Online
LK Offline
Admin / Code Breaker

Registered: 03/24/01
Posts: 7396
Just installed... and it works smile I think it'd be cool though that if the user is online it'd say "Online" or something like that when you hover the image, and if they're offline it'd say "Offline/Invisible". I'm not sure if it's possible in JS, but I think just instead of "src" you should put "alt".
_________________________

My Hacks Page (will be back with UBB 7!)
UBBDev - We put the class into UBB.classic!

Top
#202775 - 04/07/04 05:59 AM Re: [6.7] [beta] User Online
Brett Offline
Moderator

Registered: 05/04/01
Posts: 992
Loc: Twinsburg, Ohio
I am working in mozilla 1.6, and the .alt did work, but it didn't mouseover anything. .title does tho. jic, i left both alt and title in, since they both don't have any errors. Figuring 2 is better than 1, maybe there's a browser who will only accept alt, i dunno. wink

Top
#202776 - 04/07/04 06:01 AM Re: [6.7] [beta] User Online
Gizmo Administrator Offline
Wizard

Registered: 01/10/00
Posts: 5092
Loc: Portland, OR, USA



i use those for my irc indicators heh
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design Owner

Top
#202777 - 04/07/04 06:03 AM Re: [6.7] [beta] User Online
LK Offline
Admin / Code Breaker

Registered: 03/24/01
Posts: 7396
in Mozilla, ALT is when the image isn't available and title is when it is... In IE ALT is when the image is available and near the [x] when it isn't.
_________________________

My Hacks Page (will be back with UBB 7!)
UBBDev - We put the class into UBB.classic!

Top
#202778 - 04/07/04 06:10 AM Re: [6.7] [beta] User Online
Brett Offline
Moderator

Registered: 05/04/01
Posts: 992
Loc: Twinsburg, Ohio
hmm, never noticed that. Sweet, so it should be safe on all fronts. laugh

Top
#202779 - 04/07/04 06:18 AM Re: [6.7] [beta] User Online
LK Offline
Admin / Code Breaker

Registered: 03/24/01
Posts: 7396
"ultimatebb.php/topic/4/8.asp" lol
_________________________

My Hacks Page (will be back with UBB 7!)
UBBDev - We put the class into UBB.classic!

Top
#202780 - 04/07/04 06:44 AM Re: [6.7] [beta] User Online
Gizmo Administrator Offline
Wizard

Registered: 01/10/00
Posts: 5092
Loc: Portland, OR, USA
ultimatebb.php/topic/33/162.brett

:x
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design Owner

Top
#202781 - 04/07/04 09:56 AM Re: [6.7] [beta] User Online
Ian Spence Offline
Master Hacker

Registered: 01/25/03
Posts: 3765
Loc: Saint Johns, PA
Using it on my forums and it looks great. You should use Gizzy's images in the zip cause Jelsoft might get pissed
_________________________
Code monkey like Fritos

Top
#202782 - 04/07/04 10:12 AM Re: [6.7] [beta] User Online
Gizmo Administrator Offline
Wizard

Registered: 01/10/00
Posts: 5092
Loc: Portland, OR, USA
Quote:
Originally posted by Ian Spence:

Using it on my forums and it looks great. You should use Gizzy's images in the zip cause Jelsoft might get pissed


IAN! Watch your language! I'm going to tell mom :x...
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design Owner

Top
#202783 - 04/07/04 10:13 AM Re: [6.7] [beta] User Online
Gizmo Administrator Offline
Wizard

Registered: 01/10/00
Posts: 5092
Loc: Portland, OR, USA
Oh BTW, feel free to use my images, I give you complete rights to do so (at least i think I'm the one who made them, I've been so busy that I don't even recall lol, i've been using them for like 2 years now, and their crappy, so i'm pretty sure i made them)...
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design Owner

Top
#202784 - 04/07/04 10:41 AM Re: [6.7] [beta] User Online
Gizmo Administrator Offline
Wizard

Registered: 01/10/00
Posts: 5092
Loc: Portland, OR, USA
I wonder how much it'd slow down your board having it in the directory...
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design Owner

Top
#202785 - 04/08/04 06:20 AM Re: [6.7] [beta] User Online
*Cartman* Offline
Member

Registered: 03/20/02
Posts: 65
this hack with VIPHTML and recicle bin rocks!

Brett #1 ! thumbsup

Top
#202786 - 04/09/04 11:50 PM Re: [6.7] [beta] User Online
Gizmo Administrator Offline
Wizard

Registered: 01/10/00
Posts: 5092
Loc: Portland, OR, USA
I'm semi curious how this works with deleted members posts...
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design Owner

Top
#202787 - 04/09/04 11:58 PM Re: [6.7] [beta] User Online
Ian Spence Offline
Master Hacker

Registered: 01/25/03
Posts: 3765
Loc: Saint Johns, PA
it doesn't show at all. no image whatsoever
_________________________
Code monkey like Fritos

Top
#202788 - 04/10/04 02:44 AM Re: [6.7] [beta] User Online
Brett Offline
Moderator

Registered: 05/04/01
Posts: 992
Loc: Twinsburg, Ohio
Designed Behavior™ wink

Top
#202789 - 04/10/04 01:39 PM Re: [6.7] [beta] User Online
Gizmo Administrator Offline
Wizard

Registered: 01/10/00
Posts: 5092
Loc: Portland, OR, USA
Nice nice nice... I plan on upgrading soon, so be prepaired...
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design Owner

Top
#202790 - 05/06/04 01:00 AM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
OK, so I get the "Offline" image, but never the online.


Where should I start looking?
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202791 - 05/06/04 02:10 AM Re: [6.7] [beta] User Online
Brett Offline
Moderator

Registered: 05/04/01
Posts: 992
Loc: Twinsburg, Ohio
user_online.gif and user_offline.gif are located in the noncgi directory of the zip and should be uploaded into the respective directory on your webserver. smile

Top
#202792 - 05/06/04 02:17 AM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
That isn't the issue, the image shows up for offline, but I'm having a functionality issue in that it doesn't ever change to "online"...

I'm just not sure what file/part of code toggles that feature.
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202793 - 05/06/04 02:23 AM Re: [6.7] [beta] User Online
Brett Offline
Moderator

Registered: 05/04/01
Posts: 992
Loc: Twinsburg, Ohio
For one, you do need recent visitors enabled. Also check to make sure you've uploaded online.cgi in ascii format and with 755 permissions.

If that doesn't work, can i get a link to your board?

Top
#202794 - 05/06/04 08:32 AM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
I forget there isn't a link to my board in my sig...


http://4.11.202.114/tin_benders/cgi-bin/ultimatebb.cgi


test:1234
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202795 - 05/06/04 08:41 AM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
Quote:
Originally posted by Brett:

For one, you do need recent visitors enabled. Also check to make sure you've uploaded online.cgi in ascii format and with 755 permissions.

If that doesn't work, can i get a link to your board?


These files are on my local disk, so there is no upload and chmod issue to deal with.
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202796 - 05/06/04 09:45 AM Re: [6.7] [beta] User Online
Ian Spence Offline
Master Hacker

Registered: 01/25/03
Posts: 3765
Loc: Saint Johns, PA
according to his online.cgi, it can't locate vars_config.
_________________________
Code monkey like Fritos

Top
#202797 - 05/06/04 04:19 PM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
Quote:
Originally posted by Ian Spence:

according to his online.cgi, it can't locate vars_config.


Do I need to modify online.cgi? I placed it in the cgi-bin folder, along with all the other cgi's.
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202798 - 05/06/04 04:21 PM Re: [6.7] [beta] User Online
Ian Spence Offline
Master Hacker

Registered: 01/25/03
Posts: 3765
Loc: Saint Johns, PA
is it in the same folder as vars_config?
_________________________
Code monkey like Fritos

Top
#202799 - 05/06/04 04:35 PM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
Yes, it is in the came folder as vars_config.cgi (which is 701 bytes)
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202800 - 05/06/04 08:44 PM Re: [6.7] [beta] User Online
GATOR420 Offline
Member

Registered: 01/31/03
Posts: 118
Found a couple of status gifs for this if anyone else would like to use them. Just did a random search on google for gifs of the same name.


_________________________
-GATOR

"Pain is temporary, Pride is forever"

Top
#202801 - 05/06/04 09:35 PM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
Help?
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202802 - 05/06/04 10:13 PM Re: [6.7] [beta] User Online
Gizmo Administrator Offline
Wizard

Registered: 01/10/00
Posts: 5092
Loc: Portland, OR, USA
shh, brett is sleeping... :x...
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design Owner

Top
#202803 - 05/06/04 11:25 PM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
Could there be something wrong with Vars_Config.cgi?

I even tried pointing to it directly (URL) within online.cgi, and it still didn't work although I can access the file via IE.
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202804 - 05/07/04 12:10 AM Re: [6.7] [beta] User Online
Brett Offline
Moderator

Registered: 05/04/01
Posts: 992
Loc: Twinsburg, Ohio
did you have to change the location of vars_config.cgi in your ultimatebb.cgi and cp.cgi? Also you can't do url path to your config file, it's gotta be the full path. e.g. /usr/bin/local/path/file/ubbcgi/vars_config.cgi.

Quote:
Originally posted by Gizzy:

shh, brett is sleeping... :x...

No, i wish. tipsy I work from 2 to 11 on thursday, had a very important project due today, couldn't mess around. :x

Top
#202805 - 05/07/04 12:15 AM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
I haven't changed the location of vars_config.cgi since the install. It is still in cgi-bin, the same folder that online.cgi is in.

I have returned the file online.cgi to it's original state, having altered it playing with paths.
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202806 - 05/07/04 12:25 AM Re: [6.7] [beta] User Online
Brett Offline
Moderator

Registered: 05/04/01
Posts: 992
Loc: Twinsburg, Ohio
Ok, open up your ultimatebb.cgi, about line 122 it will have something like
Code:
eval {
	do "vars_config.cgi";
};
This is the exact same way in the upload file on line 72. They should be exactly the same, since their in the same directory.

Top
#202807 - 05/07/04 12:32 AM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
Software error:
Can't locate http://4.11.202.114/tin_benders/cgi-bin/vars_config.cgi in @INC (@INC contains: E:/Perl/lib E:/Perl/site/lib .) at E:inetpubwwwroottin_benderscgi-binonline.cgi line 9.
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202808 - 05/07/04 12:34 AM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
eval {
do "vars_config.cgi";
};

Is how it looks in both now.


Same problem :tired and confused:

Software error:
Can't locate vars_config.cgi in @INC (@INC contains: E:/Perl/lib E:/Perl/site/lib .) at E:inetpubwwwroottin_benderscgi-binonline.cgi line 9.

For help, please send mail to this site's webmaster, giving this error message and the time and date of the error.
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202809 - 05/07/04 12:35 AM Re: [6.7] [beta] User Online
Brett Offline
Moderator

Registered: 05/04/01
Posts: 992
Loc: Twinsburg, Ohio
Ok, change the http://4.11.202.114/tin_benders/cgi-bin/vars_config.cgi in ubb_upload.cgi to E:inetpubwwwroottin_benderscgi-binvars_config.cgi

Top
#202810 - 05/07/04 12:47 AM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
ubb_upload.cgi? I assume you mean online.cgi? This is what I get making that change to online.cgi because I don't have a ubb_upload.cgi


Software error:
Can't locate E:inetpubwwwroot in_bendersi-binvars_config.cgi in @INC (@INC contains: E:/Perl/lib E:/Perl/site/lib .) at E:inetpubwwwroottin_benderscgi-binonline.cgi line 9.

For help, please send mail to this site's webmaster, giving this error message and the time and date of the error.
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202811 - 05/07/04 01:17 AM Re: [6.7] [beta] User Online
Brett Offline
Moderator

Registered: 05/04/01
Posts: 992
Loc: Twinsburg, Ohio
Whoops, thinking about the wrong hack. okay, replace:
require "vars_config.cgi";

with

eval {
do "vars_config.cgi";
};

Top
#202812 - 05/07/04 11:02 AM Re: [6.7] [beta] User Online
PhillipBurum Offline
Member

Registered: 11/02/03
Posts: 155
Ok, so I did that, and then I got the Error for the lext line of code, where it looks for vars_pntf. So I went and replaced it also. Now I get this if I try and run online.cgi by itself...

Code:
 var AllImgs = document.body.getElementsByTagName("img"); function ChangeAll(img) { for(var i=0;
 i <= AllImgs.length; i++) { if(AllImgs[i] && AllImgs[i].id == img) { AllImgs[i].src = '/user_online.gif';
 AllImgs[i].alt = 'Online'; AllImgs[i].title = 'Online'; } // end if } // end for } 
 
And the image doesn't change.
_________________________
United Devices Points: [img]http://www.ubbdev.com/ud/?u=phillip.burum&s=1[/img]

Top
#202813 - 05/07/04 08:15 PM