Info
- 3 posts
- 2 voices
- Started 5 years ago by actorjiml
- Latest reply from actorjiml
- This topic is not a support question
Looking for the right hook
-
- Posted 5 years ago #
I am fleshing out my plugin Graphic-display-ranks and I'm looking for the right hook to use to do the following:
I want to find out if a topic author is the Key Master or a moderator. Here is what I have so far --
function get_special_rank () {
global $special_rank, $use_special_rank, $bbdb;if ($use_special_rank==1)
{$title_for_rank=<strong>I NEED THIS HOOK</strong>( get_post_author_id() );
switch ($title_for_rank) {
case "keymaster" :
$special_rank=1;
break;
case "moderator" :
$special_rank=2;
break;
default :
$special_rank=0;
}
}
else
{
$special_rank = 0;
}
return $special_rank;}
Can anyone point me in the right directon?
-
- Posted 5 years ago #
I don't think you want a hook, you want
get_user_type($id) -
- Posted 5 years ago #
That's got it. Thanks. I'll be uploading the updated version in a few minutes.
-
You must log in to post.