![]() |
Buddy & Ignore List Add/Remove in Postbit
Buddy & Ignore List Add/Remove in Postbit
What is it? Just a little add-on to replace the static "Add (user) to your Buddy List" menu option on the username drop-down menu with "Add (user) to your Buddy List" and "Add (user) to your Ignore List" (if the user isn't already on the list) and "Remove (user) from your Buddy List" and "Remove (user) from your Ignore List" if they are. :) It's just three steps: A few new phrases, a plugin and a template edit. 1. Create these phrases (How to add a phrase): Phrase Type: Postbit Varname: remove_x_from_buddylist Text: Remove {1} from Your Buddy List Phrase Type: Postbit Varname: add_x_to_ignorelist Text: Add {1} to Your Ignore List Phrase Type: Postbit Varname: remove_x_from_ignorelist Text: Remove {1} from Your Ignore List 2. Upload the attached .xml plugin. 3. In postbit (and/or postbit_legacy) template, FIND: HTML Code:
<tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=addlist&userlist=buddy&u=$post[userid]"><phrase 1="$post[username]">$vbphrase[add_x_to_buddy_list]</phrase></a></td></tr> HTML Code:
<if condition="!in_array($post['userid'], $GLOBALS['buddyarray'])"> |
It's a very simple but very useful hack. Believe it or not, I had a member on a forum that I go to (but I don't admin, sadly) who commented that something like this would be quite useful.
*Hits Install* EDIT - You might want to note that, if a user is using the `postbit_legacy` template, they should edit that instead. I know it is pretty obvious, but, in my years of software development, I've met some pretty idiotic users, and it is better to be safe than sorry. :D |
Quote:
Quote:
|
when I added this hack, it would cause an error when using Quick Reply.
Quote:
|
Quote:
|
Nope. And once I removed this hack and reverted my templates, the problem disappeared. I got the same thing in both IE and in FF
|
oh, and the problem existed in both Beta 1 and 2
|
Hm. Well for reasons I can't explain it seems to work okay if you move the plugin to global_start.
|
ok. thanks :)
|
Quote:
|
All times are GMT. The time now is 01:51 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:
|