Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: Trying to stop spam email


jfcarter
Participant

@jfcarter

Hi r-a-y,

Thanks. I was hoping not to have to use this function, because alot of our users are getting to know each other and are sending messages.

The problem is that someone keeps creating accounts and spamming all of our members (well over 100) and I have to keep going in and deleting all of the messages. And I have to watch the user signups like a hawk.

So, anyway, this was my first time using it. I changed the functions, but still can’t get it working. I think it may be how I’m adding it to my bp-custom.php. Here’s what I’ve added:

function bp_send_message_to_friend_button() {
global $bp;
if ( bp_is_home() || !is_user_logged_in() || !friends_check_friendship($bp->loggedin_user->id,$bp->displayed_user->id) )
return false;
$ud = get_userdata( $bp->displayed_user->id );
?>
<div class="generic-button">
<a class="send-message" title="<?php _e( 'Send Message', 'buddypress' ) ?>" href="<?php echo $bp->loggedin_user->domain . $bp->messages->slug ?>/compose/?r=<?php echo $ud->user_login ?>"><?php _e( 'Send Message', 'buddypress' ) ?></a>
</div>
<?php
}

But I’m a bit confused. Shouldn’t it start with <?php and end with ?>

Thanks for your help,

jfcarter

Skip to toolbar