![]() |
pm when member is promoted
I'm trying to make a hack (plugin if possible) that will send a pm to a member when they are promoted to the next higher rank.
I don't even know where to start at though...any ideas? |
The first step would be to find the block(s) of code that are run when a member is promoted, either via automatic promotion because they've hit x number of posts, or manually by an admin.
Once you've found that, look for the closest hook, and write the plugin that will send a PM. If memory serves, there's a tutorial in the 3.5 Mod Tutorials section by Kirby or Marco (I forget which) that shows you how to send a PM. Thanks, ALan. |
ok, little more info about me...
never done a plugin or anything before... what does a hook look like? |
When looking through the vBulletin code, a hook looks like:
PHP Code:
To get started, take a look at some of the tutorials here: https://vborg.vbsupport.ru/showpost....03&postcount=1 Start with the basics, then move up. Thanks, Alan. |
thanks a bunch alan...
now to go get started on my first hack :) |
Good luck :)
|
is there a list of hooks, their locations, and a general synopsis of what they do anywhere?
|
A list of hooks can be found in /includes/xml/hooks_vbulletin.xml
Most of them should be fairly self-explanatory. The <hooktype type> is the general area they are run (editpost, calendar, etc), with each hook having a more specific location. When I'm looking for a hook to add some code to, I find the easiest way is look in the vB PHP files themselves. For example, if I wanted to ruin some code whenever a thread is deleted, I'd go to postings.php which handles the thread tools options, then browse through it until I found the section of code which deletes threads, then find the closest hook. Thanks, Alan. |
All times are GMT. The time now is 10:53 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:
|