![]() |
Blink PM icon with userinfo
Blink PM icon with userinfo
--------------------- Installation - easy - queries 0/1 (details below) - file edits 1 - template edits 1 Reason for this hack: I find the PM system lacked some additional information on the navbar the 0 X Unread, Total X isn't enough, as i wanted to know who sent the PM and how many they sent. How it works: When you get a PM the "Private Messages: x Unread, Total x." disappears and is replaced with a little blinking icon, if the user that sent the PM is a mod the icon will blink a teal color, if its a normal user, it will blink yellow. along with this you can view who sent the message, and if multiple people sent you PMs it will show their names.. If they sent you more than one, it will tell you that too. It will also take you directly to the PM without having to go to your inbox first.. After you've read all your PMs (or you dont have any) the "Private Messages: x Unread, Total x." returns to normal. Queries: i know a lot of people are worried when it comes to adding hacks (especially me) because of additional queries.. this hack is sort of different. It only executes 1 query IF the user has unread PMs.. if they have no new PMs then 0 queries. I've included two blinking gifs, you can use your own, put them in your images misc directory. Read the txt file for installtion which takes 30 seconds. I plan to expand this addons, but depends how many find it usefull, so click install plz. |
very cool!
edit- installed in about 30 seconds and it works as advertised! |
Cool
|
[high]* nexialys looks further to receive these pm.. ;)[/high]
|
Very cool, *clicks install*.
One question though, How would you get this to work on a portal page like vBAdvanced? The PM section dissapears as I goto the front page. |
wowzers.. now with the 1) audible PM message hack, and 2) this hack, and 3) the blinking "PRIVATE MESSAGE" message like they have here... my PM system is like the 4th of july when I get a PM :)
|
Works great, thanks!
|
I'm still using 3.0.3. Will I have to make any modifications?
|
it's a 3.0+ hack, everything work the same for all versions...
|
nice :) thanks for sharing
|
You can do this using template conditionals, no need to hack code.
|
Quote:
sure you can use a conditional to blink an image, but there is no way you are going to be able to get the users, the ids to the PM, the unique PM count, etc.. |
I get this SQL Error:
Database error in vBulletin 3.0.3: Invalid SQL: SELECT pmtext.pmtextid, pmtext.fromusername, pmtext.fromuserid, pmtext.dateline, pm.pmid, user.userid, user.usergroupid, COUNT(pmtext.fromuserid) AS fromusertotal FROM pmtext AS pmtext LEFT JOIN pm AS pm USING(pmtextid) LEFT JOIN user ON (user.userid=pmtext.fromuserid) WHERE pm.userid=1 AND messageread=0 GROUP BY pmtext.fromusername ORDER BY user.usergroupid ASC mysql error: Table 'andy.pmtext' doesn't exist mysql error number: 1146 |
@ Kahoona: redownload the zip. i forgot to add TABLE_PREFIX to the query.
|
Quote:
|
It still does not work lol.
|
Quote:
|
Quote:
all i did was change: FROM pmtext to: FROM " . TABLE_PREFIX . "pmtext TABLE_PREFIX is only needed if you add a prefix on your tables when you installed vb, otherwise its not needed. Kahoona, do your tables have a prefix or not? |
most excellent.
installed in 1 minute and works like a charm. |
Quote:
|
Quote:
|
I installed it and it worked on all my pages but not on my vbadvanded cmps portal page. I have a global.php require in my index.php, both my root and my forums but if there are any PMs that line disappears.... No PMs and it looks normal.. again, only on the portal page.... any thoughts?
|
i tired to install it and i got the same database error i had to un-install it
|
Quote:
the sql script needed an additional two prefix's (in bold below): Code:
$getmessages = $DB_site->query(" |
doh, i forgot about the left joins.. i updated the zip,.. those that got the sql error and have table prefix on vb are the only ones that should get the updated version.
thanx. |
is there a way to make it show up also on the VBACmps (vb advanced) page?
|
what attachment are you talking about? the hack file?
|
/me clicks install
|
Just installed it...Thanks!
|
I get this error. Any idea on what the problem is?
Database error in vBulletin 3.0.6: Invalid SQL: SELECTpmtext.pmtextid, pmtext.fromusername, pmtext.fromuserid,pmtext.dateline, pm.pmid, user.userid, user.usergroupid, COUNT(pmtext.fromuserid) AS fromusertotal FROMvb3_pmtext AS pmtext LEFT JOIN vb3_pm AS pm USING(pmtextid) LEFT JOIN vb3_user ON(user.userid=pmtext.fromuserid) WHERE pm.userid=135 AND messageread=0 GROUP BY pmtext.fromusername ORDER BYuser.usergroupid ASC mysql error: Unknown table 'user' in field list mysql error number: 1109 |
Very nice :)
|
My users always login on the portal, my question is ?, how can I use this with the vbadvanded portal.
|
Can I get someone to help me with my code? I think mycode is modded already and this is why I'm not sure where to put thishacked code. THanks in advance!
My PM area code: Code:
<if condition="$bbuserinfo['userid']"> |
Quote:
Tobi |
Hi,
got it work with this query: Code:
SELECT pmtext.pmtextid, pmtext.fromusername, pmtext.fromuserid, pmtext.dateline, pm.pmid, " . TABLE_PREFIX . "user.userid, " . TABLE_PREFIX . "user.usergroupid, Regards, Tobi |
Quote:
|
agreed. I have a site that uses vbindex.
I assume you plop the code in vbindex and mod the vbindex templates? just need a confirm |
Quote:
Is there a way to show 1 to 3 users max and have the flashing note icon clickable to the normal private.php file? I am going out to a club so I guess you guys can huck that up... thanks. |
Many thanks, works nicely.
One slight hiccup though, when there is no PM for the member all displays normally in vBAdvanced portal, but when there IS a PM that whole section disappears from the nav panel (but as I say works perfectly in the forums.) Nothing to worry about, i'll figure it all out when my brain returns from it's winter holidays!! |
Nice, clicked installed :)
|
All times are GMT. The time now is 04:47 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|