For some reason, only the last filter is working. Here's what it is:
function get_pm_bb_location(){
if ( bb_find_filename($_SERVER['PHP_SELF']) == 'pm.php' )
return 'pm-page';
}
function is_pm() {
if ('pm-page' == get_bb_location() )
return true;
else
return false;
}
function get_mess_bb_location(){
if ( bb_find_filename($_SERVER['PHP_SELF']) == 'message.php' )
return 'message-page';
}
function is_message() {
if ('message-page' == get_bb_location() )
return true;
else
return false;
}
bb_add_filter('get_bb_location', 'get_mess_bb_location');
bb_add_filter('get_bb_location', 'get_pm_bb_location');
I swear they're both the same. And whichever filter I put last works, and the other doesn't.
Also, what's the deal? is bb_add_filter and add_filter the same damn thing? They both seem to be interchangable.
I might just change the way I'm doing this. My current way is so beautiful though :(
And for whoever sees what these functions would be used for, the answer to your question is this: I'm very close.