Search Results for 'notification user id'
-
Search Results
-
Hello everybody,
I’am currently trying to hide the @mention function to users of my website. So i’ve put the following code in the “bp-custom.php” file :
function modify_bp_core_hide_mention_item(){
global $bp;
bp_core_remove_subnav_item($bp->bp_nav, $bp->bp_options_nav);
}
add_action(‘bp_activity_setup_nav’,’modify_bp_core_hide_mention_item’,0);It seems to work well, the “mention” navigation menu is hidden.
But i have one problem left. There is still a reference to the mention function on the “notifications settings” page, which asks the user if he wants to have an email sent when someone mention him somewhere with the @mention function.
I’ve found out that this display is made by the function “bp_activity_screen_notification_settings” in the “bp-activity.php” file, which basically just prints a table and then is added to the “bp_notification_settings” hook :
add_action( ‘bp_notification_settings’, ‘bp_activity_screen_notification_settings’, 1 );So my question is : shall I remove this action and write another function which doesnt display the mentions settings ? or is there any better solution ?
Oh, i’ve forgot to say that i’m a new buddypress/wp user

Thank you in advance, any help is welcome.
WPMU 2.9.2
BuddyPress 1.2.4I need admins to activate newly registered users, not the users themselves. I haven’t been able to come up with a working plugin – probably because I’ve got MU and BuddyPress both running on my “members only” site.
I’ve modified the bp-core-signup.php file to send an e-mail to the user without the activation link and added an e-mail to the admin e-mail with the activation url. However, the user still ends up with the only e-mail, and it contains the activation url. Furthermore, the e-mail comes from noreplay@ which means that WP thinks I don’t have an admin e-mail set, which is not the case (I have one set).
bp-core-signup.php (originally)
Code:function bp_core_signup_send_validation_email( $user_id, $user_email, $key ) {
$activate_url = bp_get_activation_page() .”?key=$key”;
$activate_url = clean_url( $activate_url );
$admin_email = get_site_option( “admin_email” );if ( empty( $admin_email ) )
$admin_email = ‘noreply@’ . $_SERVER[‘SERVER_NAME’];$from_name = ( ” == get_option( ‘blogname’ ) ) ? ‘BuddyPress’ : wp_specialchars( get_option( ‘blogname’ ) );
$message_headers = “MIME-Version: 1.0n” . “From: “{$from_name}” n” . “Content-Type: text/plain; charset=”” . get_option( ‘blog_charset’ ) . “”n”;
$message = sprintf( __( “Thanks for registering! To complete the activation of your account please click the following link:nn%snn”, ‘buddypress’ ), $activate_url );
$subject = ‘[‘ . $from_name . ‘] ‘ . __( ‘Activate Your Account’, ‘buddypress’ );/* Send the message */
$to = apply_filters( ‘bp_core_activation_signup_user_notification_to’, $user_email );
$subject = apply_filters( ‘bp_core_activation_signup_user_notification_subject’, $subject );
$message = apply_filters( ‘bp_core_activation_signup_user_notification_message’, $message );wp_mail( $to, $subject, $message, $message_headers );
}bp-core-signup.php (my modification, not working)
Code:function bp_core_signup_send_validation_email( $user_id, $user_email, $key ) {
$activate_url = bp_get_activation_page() .”?key=$key”;
$activate_url = clean_url( $activate_url );
$admin_email = get_site_option( “admin_email” );if ( empty( $admin_email ) )
$admin_email = ‘noreply@’ . $_SERVER[‘SERVER_NAME’];/* START MOD */
$from_name = ( ” == get_option( ‘blogname’ ) ) ? ‘BuddyPress’ : wp_specialchars( get_option( ‘blogname’ ) );
$message_headers = “MIME-Version: 1.0n” . “From: “{$from_name}” n” . “Content-Type: text/plain; charset=”” . get_option( ‘blog_charset’ ) . “”n”;
$message = sprintf( __( “Thanks for registering! And admin will confirm your membership.nnYou will receive a separate e-mail after this confirmation.”, ‘buddypress’ ), $activate_url );
$subject = ‘[‘ . $from_name . ‘] ‘ . __( ‘Activate Your Account’, ‘buddypress’ );/* Send the message */
$to = apply_filters( ‘bp_core_activation_signup_user_notification_to’, $user_email );
$subject = apply_filters( ‘bp_core_activation_signup_user_notification_subject’, $subject );
$message = apply_filters( ‘bp_core_activation_signup_user_notification_message’, $message );wp_mail( $to, $subject, $message, $message_headers );
/* END MOD *//* START ADD */
$from_name = ( ” == get_option( ‘blogname’ ) ) ? ‘BuddyPress’ : wp_specialchars( get_option( ‘blogname’ ) );
$message_headers = “MIME-Version: 1.0n” . “From: “{$from_name}” n” . “Content-Type: text/plain; charset=”” . get_option( ‘blog_charset’ ) . “”n”;
$message = sprintf( __( “New registration request fromnnUsername: %snnE-mail: %snnPlease confirm by clicking the link below:nn%snn”, ‘buddypress’ ), $user_id, $user_email, $activate_url );
$subject = ‘[‘ . $from_name . ‘] ‘ . __( ‘Activate Your Account’, ‘buddypress’ );/* Send the message */
$to = apply_filters( ‘bp_core_activation_signup_user_notification_to’, $admin_email );
$subject = apply_filters( ‘bp_core_activation_signup_user_notification_subject’, $subject );
$message = apply_filters( ‘bp_core_activation_signup_user_notification_message’, $message );wp_mail( $to, $subject, $message, $message_headers );
/* END ADD */
}So, after I submit a test registration, I get an with the information below:
[blockquote]
from Members Only <noreply@domain.net>
to user@domain.com
date Thu, Jun 3, 2010 at 3:42 AM
subject [Members Only] Activate Your Accounthide details 3:42 AM (3 minutes ago)
Thanks for registering! To complete the activation of your account please click the following link:
http://members.domain.net/activate?key=xxxxxxxxxxxxxxxx
[/blockquote]Could someone help me by directing me to a plugin or some way to change my code so that I’m able to restrict registration to admin approval?
Hi, I’ve installed bbpress on bluehost using simplescript and all is going well except that user registration doesn’t work. I already tried setting “Allow new registrations” ON and OFF but still the same. It won’t even send a notification to my admin email whenever someone attempted to register.
Please help
Thanks!You can try to register here: http://www.upinteractivesociety.org/register/
PS. The registration form works fine except that when you click “Complete Sign Up” nothing happens except for the notification that says “Sign up success” and then asking for the avatar.
Topic: Admin Bar Links Not Working
Hi guys,
I need to watch and approve every single registration to restrict unwanted access to my private club. Like other social network the ideal form is be informed by notification mail upon user registration and that’s the admin choice to approve or not to approve new request. so how can I do that? I’m using latest version of BuddyPress.
Thanks in Advance.
Topic: BuddyPress Security
Had our first Hacker attack…
WhooHoo…
It was a friend’s acquaintance trying to prove a point
so kinda silly – and taken care of.
But it did bring Security issues to mind.
Thankfully the Group-Notifications plug-in has some anti-spam measures.
Any ideas on how to Baton Down the Hatches for BuddyPress?
We need to keep it open to registration and activity.
But how do we squash and ban certain unruly users quickly and effectively?
I now have WP plug-ins installed: Ban Hammer and WP-Ban
which are good for banning IPs, hostnames, etc.
But what about on the BP side?
How do we moderate Activity feeds especially?
Let us know some thoughts and ideas.
– Avatar –
.
For Cureuphoria (http://cureuphoria.com) I disabled the default admin bar and decided to design a custom one that would fit the design better.
define('BP_DISABLE_ADMIN_BAR', true);When you’re not logged in, the bar displays the login fields, and a link to create an account if you don’t have one.
When you are logged in, the bar displays the member avatar, and links such as: My profile – My messages – My friends – My groups – Settings – Logout.
Now, I’d like to have the notifications system in that bar, like for the default bar I desabled.
First question is: can I do that?
Second question is: if I can, how?
Here’s my code:
<div id="curemates-bar">
<?php if ( is_user_logged_in() ) : //logged in ?>
<?php do_action( 'bp_before_sidebar_me' ) ?>
<a href="<?php echo bp_loggedin_user_domain() ?>"><?php bp_loggedin_user_avatar( 'type=thumb&width=30&height=30' ) ?></a>
<ul id="user-menu">
<li><a href="<?php echo bp_loggedin_user_domain() ?>/profile/edit/">My profile</a></li>
<li>| <a href="<?php echo bp_loggedin_user_domain() ?>/messages/">My messages</a></li>
<li>| <a href="<?php echo bp_loggedin_user_domain() ?>/groups/">My groups</a></li>
<li>| <a href="<?php echo bp_loggedin_user_domain() ?>/friends/">My friends</a></li>
<li>| <a href="<?php echo bp_loggedin_user_domain() ?>/photos/">My photos</a></li>
<li>| <a href="<?php echo bp_loggedin_user_domain() ?>/settings/">Settings</a></li>
<li>| <a id="logout" href="<?php echo wp_logout_url( get_option('home') ) ?>"><?php _e( 'Log Out', 'buddypress' ) ?></a></li>
</ul>
<?php do_action( 'bp_sidebar_me' ) ?>
<?php do_action( 'bp_after_sidebar_me' ) ?>
<?php if ( function_exists( 'bp_message_get_notices' ) ) : ?>
<?php bp_message_get_notices(); /* Site wide notices to all users */ ?>
<?php endif; ?>
<?php else : //not logged in ?>
...stuff...
<?php endif; ?>
</div><!-- end "curemates-bar" -->Now, I now that the code I am looking for is in the “bp-core-adminbar.php” file, and I’ve made a few attempts to extract what needed to re-create the notifications menu, but obviously without success.
Can anybody help me out with this?
Thanks.