Anybody have an answer to this?
I finally got it too work! Is there a way to make admins be able to make working links? Or it has to be nobody/everyone? Hope you guys can answer.
Thanks you
untested, but this should make the filter only removed if they are not a keymaster
if ( !bbp_is_user_keymaster()) {
remove_filter( 'bbp_get_reply_content', 'bbp_make_clickable', 4 );
remove_filter( 'bbp_get_topic_content', 'bbp_make_clickable', 4 );
}
did not work
can you specify? any? all? admins?
no one can post links, wich is good, but the code : !bbp_is_user_keymaster, did not let keymaster be able to do so.
oh and by the way, bbpress links still works on my forum wich is normal I suppose?
ok, try
$user_id = wp_get_current_user()->ID;
if ( !bbp_is_user_keymaster($user_id )) {
remove_filter( 'bbp_get_reply_content', 'bbp_make_clickable', 4 );
remove_filter( 'bbp_get_topic_content', 'bbp_make_clickable', 4 );
}
oh and by the way, bbpress links still works on my forum wich is normal I suppose?
can you explain what you mean by that ?
Thanks again Robin, i’ve tryed this but is doesnt work either: $user_id = wp_get_current_user()->ID;
I think the problem is that website that doesn’t use the www. doesnt get blocked and still can be clickable.Exeple: bbpress.org is clickable. but http://www.google.ca isn’t. etc.
now confused – you seem to be stating issues with both admin access and www. vs non www
can you state clearly what is and isn’t working
Alright, when I block links with: remove_filter( ‘bbp_get_reply_content’, ‘bbp_make_clickable’, 4 );remove_filter( ‘bbp_get_topic_content’, ‘bbp_make_clickable’, 4 );
it seems to work BUT admins can’t post links either even with the code you have sent me.
Secondly, the links doesn’t work wich is good BUT site that doesn’t provide a “www” can still be clickable so when someone type:” https://bbpress.org ” this link is clickable and both admins and user can do that, and if you type: “www.google.ca” then both admins and user can do that and it WONT be clickable.
I would like the admins to be able to send link, AND be able to block non www links too.
Thanks you.