PDA

View Full Version : PM Status hack (pm folders on forumhome)


The_Wanderer
15 Jan 2003, 16:02
First of all, this is a modified version of the PM Gauge (http://www.vbulletin.org/forum/showthread.php?s=&threadid=34248) hack by Bald_Bouncer (http://www.vbulletin.org/forum/member.php?s=&action=getinfo&userid=112). Although i didn't use much of his code i suppose he deserve some credit :)
I tested this on 2.2.9 but it should work on earlier versions as well.
If you install this remember to click Install (http://www.vbulletin.org/forum/misc.php?s=&action=install&threadid=47744) ;)

What does this hack do?
This hack displays how many percent of your pm quota you use as well as displaying a "PM Status" which starts as Low , then changes to Normal then Critical and finally it changes to full when you're pm quota reaches its limit.
when the status goes "critical" the pm bar starts to blink

Version 1.1
Right under the pm status you'll find links to all your pm folders. Users wont forget to delete the pms in their "sent items" folder anymore, for sure. :)

Version 1.2
same as v1.1 but with fewer queries :D

v1 screenshots (http://www.vbulletin.org/forum/attachment.php?s=&postid=342347)
v1.1 screenshot (http://www.vbulletin.org/forum/attachment.php?s=&postid=345295)


I know this isn't much of a hack, but my members seem to like it anyway.. this is also my first hack. I guess it's a start, right? :)

UPGRADING:
v1.1: http://www.vbulletin.org/forum/attachment.php?s=&postid=345294
v1.2: http://www.vbulletin.org/forum/attachment.php?s=&postid=390598

The_Wanderer
15 Jan 2003, 16:04
Screenshots

PSI|Dr-X
15 Jan 2003, 16:38
Thnx ill try

drumsy
15 Jan 2003, 16:58
You spelled unnecessary wrong in your screen shots! :)

The_Wanderer
15 Jan 2003, 17:07
ooops.. it's fixed now though :rolleyes:

Krakken
15 Jan 2003, 19:47
Hehe, could you add a bar with % full aswell? Underneath the text would be nice. :)
Nice hack!

The_Wanderer
15 Jan 2003, 21:01
hmm yes.. that should be very easy.. just add the part of the PM Gauge code i didn't use.. erh actually..
download the attached file and follow instructions :)

Krakken
15 Jan 2003, 22:03
Thanks. :)

partang2
15 Jan 2003, 22:11
Nice hack!

*clicks install*

drumsy
16 Jan 2003, 14:26
Installed! :)

Oblivion Knight
17 Jan 2003, 12:51
Interesting yet handy feature.. Thanks Wanderer, working great.

/me clicks Install.

Oblivion Knight
18 Jan 2003, 10:39
I've just noticed that this doesn't count the messages in the sent items directory..

Do they not add to the inbox limit or should these indeed be counted aswell at the messages in the inbox directory?

The_Wanderer
18 Jan 2003, 10:59
hmm that's strange.. the original pm gauge hack only counted messages from the inbox and not the sent items directory.. but i changed that in my hack..it works fine on my own forums.. maybe i uploaded the wrong hack.. let me just check :ermm:

EDIT: OOOPS.. i've located the problem :o

in index.php find$pmpercent = round(($inboxpms[messages] / $pmquota) * 100,2);

and replace with $pmpercent = round(($allpm[messages] / $pmquota) * 100,2);

The_Wanderer
23 Jan 2003, 20:20
I added another feature..

now you'll be able to see your pm folders and how many pms there are in each folder on the pm bar, i'll add a screenshot so you can see what i mean :)

here's the upgrade file :banana:

The_Wanderer
23 Jan 2003, 20:20
screenshot

GunsNetwork
23 Jan 2003, 21:23
WOW ~ I love your last edit for this hack.

This is an awesome hack for me. I have OVER 19600 members on my website.

So for very large website this hack is A DAM GOOD ONE.

I have about 11ish member from VBulletin.org send me hacks cause if it will work on a website as large as mine then it will work on a smaller website.

Here is my website The Guns Network (http://www.gunsnet.net/forums/index.php)

My website is the largest gun site on the web. We do over 37 Million hits a month on average.

So if you have any more hacks and want to see if they would work. All I ask is get most of the bugs out and lets test it.

My compliments to your PM hack.

Sincerely

Peter aka BowHunt

The_Wanderer
24 Jan 2003, 20:20
I'm glad you like it. It took me quite some time to do it, seeing how i'm not that experienced with PHP yet. A lot of my members didn't even know the sent items folder existed untill after i installled the hack. :)

I don't have any other hacks in progress at the moment, but i'll start working as soon as i come up with something ;)

Oblivion Knight
05 Feb 2003, 21:38
Thanks for the fix you posted to my question earlier on Wanderer.

Top stuff mate.

HarryBO
07 Feb 2003, 00:06
++++ the Hack doesnīt work on my vb! Iīve tried it 3 times, but i canīt see a difference! Can someone help me?

The_Wanderer
07 Feb 2003, 18:23
Uhm.. that's strange. Are you sure you installed it right?
uhm, can you please send a working link to your forums?

maoz440
22 Feb 2003, 03:00
Great hack on my 2.29 site with 7,000+ users! :D <clicks install>

-Sidekick-
08 Mar 2003, 19:25
2 things I'd like to point out.

When I empty everything out of my folders, it says my folders are 1% full. How can they be 1% full when there's nothing in them?

Also, when everything is empty is says, "Your PM folders:" and then nothing. Could you make it when all folders are empty that line disappears as well? Or maybe after that it says All Folders Empty or something. :)

refertech
08 Mar 2003, 19:43
Originally posted by -Sidekick-
2 things I'd like to point out.

When I empty everything out of my folders, it says my folders are 1% full. How can they be 1% full when there's nothing in them?

Also, when everything is empty is says, "Your PM folders:" and then nothing. Could you make it when all folders are empty that line disappears as well? Or maybe after that it says All Folders Empty or something. :)

May just put a zero after it when they are empty. Or does it, I havent installed it yet but I will. :) Very nice hack

-Sidekick-
08 Mar 2003, 21:53
No it doesn't. They disappear. That's why I'm posting... lol

The_Wanderer
15 Mar 2003, 10:33
03-08-03 at 08:25 PM -Sidekick- said this in Post #23 (http://www.vbulletin.org/forum/showthread.php?postid=362890#post362890)
2 things I'd like to point out.

When I empty everything out of my folders, it says my folders are 1% full. How can they be 1% full when there's nothing in them?

Also, when everything is empty is says, "Your PM folders:" and then nothing. Could you make it when all folders are empty that line disappears as well? Or maybe after that it says All Folders Empty or something. :)

hmm.. i'll have to check on that :)

EDIT: It says 0% on my testboard.. I might have edited it and forgot to upload.. I'll try to sort it out..

EDIT2: done... it says 0% now and when you have 0 pms the line saying "Your PM folders:" disappears.. You can either re-install the entire hack or follow the instruction bellow:

In index.php find:

if ($pmpercent < 50) {$pmstatus = "<font color=lime>Low</font>";}

Add above:
if ($pmpercent != "0") {$pmfolderlinks = "<br>Your folders:";} else {$pmfolderlinks = "";}

In index.php find:
if ($allpm[messages] < 1) {
$pmpercent = "1";
}

Replace with:
if ($allpm[messages] < 1) {
$pmpercent = "0";
}

In forumhome_pmloggedin find:
Your Inbox is $pmpercent% full - Current PM status: <b>$pmstatus</b><br>Your PM folders: $pmfolderlink

Replace with:
Your Inbox is $pmpercent% full - Current PM status: <b>$pmstatus</b>$pmfolderlinks $pmfolderlink

Done :)
thanks for pointing it out, sidekick

refertech
15 Mar 2003, 13:41
Did you edit the original with this info too. :)

Thanks, Great edits.

Mark

The_Wanderer
15 Mar 2003, 22:12
Today at 02:41 PM refertech said this in Post #27 (http://www.vbulletin.org/forum/showthread.php?postid=366682#post366682)
Did you edit the original with this info too. :)

Thanks, Great edits.

Mark

yeah, i did.. as i said, you can just download it again and install it, or follow the instructions above :)

oh, and remember to click Install (http://www.vbulletin.org/forum/misc.php?s=&action=install&threadid=47744) if you install it :D

refertech
15 Mar 2003, 22:14
Opps, sorry. :)

Alien
16 Apr 2003, 19:14
Wow this hack adds FOUR queries to the front index? Ouch. :(

I'd really love to use it, but that might be a bit much...?

Oblivion Knight
16 Apr 2003, 19:22
Today at 07:14 PM Alien said this in Post #30 (http://www.vbulletin.org/forum/showthread.php?postid=383026#post383026)
Wow this hack adds FOUR queries to the front index? Ouch. :(

I'd really love to use it, but that might be a bit much...?

Use v1.. It's only adding one query.
That's exactly what I thought about v1.1 ;)

Regards,
Oblivion Knight

The_Wanderer
16 Apr 2003, 22:50
Today at 07:22 PM Oblivion Knight said this in Post #31 (http://www.vbulletin.org/forum/showthread.php?postid=383030#post383030)
Use v1.. It's only adding one query.
That's exactly what I thought about v1.1 ;)

Regards,
Oblivion Knight

yup.. that's why i let the v1 install file stay in the zip :)

feel free to edit v1.1 to use less queries though...

The_Wanderer
02 May 2003, 21:26
ok i updated it.. v1.2 features the same as v1.1 but it uses less queries :)

definetly worth a try, methinks :D

this was tested on my testforum and my forum, it should work :)

here's the upgrade file (it's also included in the zip on the first page)

Alien
02 May 2003, 21:42
What's "less" queries? :)

How many in total will it add to forumhome exactly?

-Jason

Alien
02 May 2003, 21:44
I believe v1 added one query, so this will add only 1 query maybe to the forumhome no matter how many folders a user has?

drumsy
02 May 2003, 22:06
My "Your Inbox is 8% full" went to 0% after I installed the upgrade to 1.2

The_Wanderer
02 May 2003, 22:25
uhm.. i think it adds 1 lol... i'll test it tomorrow, k?

EDIT: yeah it adds only 1 query nomatter how many folders you have :)

Today at 11:06 PM drumsy said this in Post #35 (http://www.vbulletin.org/forum/showthread.php?postid=390624#post390624)
My "Your Inbox is 8% full" went to 0% after I installed the upgrade to 1.2

Sounds weird.. i'll try re-installing the hack tomorrow.. just to make sure everything works :D

Alien
03 May 2003, 06:12
Sounds great, I'll give it a test!

(I'll just wait a day in case there is a bug confirmed from above) lol ;)

-Jason

The_Wanderer
03 May 2003, 08:25
i can now confirm that it works.. i tried re-installing it using the v1.2 install file, and everything worked fine..

i've changed nothing in the part of the code, that tells you how many % you've used.. :\
oh and it uses a total of 2 queries apparently.. I can't seem to figure a way for it to use only 1. Not yet at least :D
but still 2 is better than 4 ;)

The_Wanderer
04 May 2003, 21:18
for those of you who installed v1.2, you have to find and delete $ignoreusers near ORDER BY pmfolderid ASC

i'll update the install files included in the zip on the first page

The General
07 May 2003, 13:31
Great hack! Cheers!

cnczone
11 Jun 2003, 04:30
The "your folders" shows nothing
and the PM Gauge shows nothing.

I'm running VB 2.3

S.Shady
11 Jun 2003, 05:36
/me clicks install

But it added no query to my forum home and works perfectly. thanks

S.Shady
11 Jun 2003, 05:38
Today at 12:30 AM cnczone said this in Post #41 (http://www.vbulletin.org/forum/showthread.php?postid=407377#post407377)
The "your folders" shows nothing
and the PM Gauge shows nothing.

I'm running VB 2.3


It wont show folders that have "0" pms in it.

anyway to add this to the hack. Even though theres no pms in the folders i would like to see the folders

cnczone
11 Jun 2003, 12:49
My folder have pms in it.

The_Wanderer
12 Jun 2003, 12:16
Yesterday at 06:38 AM S.Shady said this in Post #43 (http://www.vbulletin.org/forum/showthread.php?postid=407386#post407386)
It wont show folders that have "0" pms in it.

anyway to add this to the hack. Even though theres no pms in the folders i would like to see the folders

that shouldnt be a problem.
uhm, i'm having a bit of a crisis at my forums. I'll have to get back to you in a week or something, if that's ok :)

Yesterday at 05:30 AM cnczone said this in Post #41 (http://www.vbulletin.org/forum/showthread.php?postid=407377#post407377)
The "your folders" shows nothing
and the PM Gauge shows nothing.

I'm running VB 2.3

hmm well I haven't tested it on 2.3... that could be the problem maybe. Or maybe you just installed it wrong.

EDIT: oops i thought you mean 2.2.3... erh it should work on 2.3..

legendarysk8er
17 Sep 2003, 06:36
Working fine on vB 2.3.2. :)

/me clicks install.

Crank
16 Feb 2004, 17:15
thank you again for this hack. *clicks Install*

Lonny
17 Mar 2004, 10:40
Just installed it thanks a lot :