Ticket #2566: jeffsayre_2566_button.patch
File jeffsayre_2566_button.patch, 4.2 KB (added by , 15 years ago) |
---|
-
buddypress/bp-themes/bp-default/members/single/member-header.php
25 25 <?php bp_add_friend_button() ?> 26 26 <?php endif; ?> 27 27 28 <?php if ( is_user_logged_in() && !bp_is_my_profile() && function_exists( 'bp_send_public_message_link' ) ) : ?> 29 <div class="generic-button" id="post-mention"> 30 <a href="<?php bp_send_public_message_link() ?>" title="<?php _e( 'Mention this user in a new public message, this will send the user a notification to get their attention.', 'buddypress' ) ?>"><?php _e( 'Mention this User', 'buddypress' ) ?></a> 31 </div> 28 <?php if ( function_exists( 'bp_send_public_message_link' ) ) : ?> 29 <?php bp_send_public_message_link() ?> 32 30 <?php endif; ?> 33 34 <?php if ( is_user_logged_in() && !bp_is_my_profile() && function_exists( 'bp_send_private_message_link' ) ) : ?> 35 <div class="generic-button" id="send-private-message"> 36 <a href="<?php bp_send_private_message_link() ?>" title="<?php _e( 'Send a private message to this user.', 'buddypress' ) ?>"><?php _e( 'Send Private Message', 'buddypress' ) ?></a> 37 </div> 31 32 <?php if ( function_exists( 'bp_send_private_message_link' ) ) : ?> 33 <?php bp_send_private_message_link() ?> 38 34 <?php endif; ?> 39 35 </div><!-- #item-buttons --> 40 36 -
buddypress/bp-activity/bp-activity-templatetags.php
839 839 } 840 840 function bp_get_send_public_message_link() { 841 841 global $bp; 842 843 if ( is_user_logged_in() && !bp_is_my_profile() ) { 844 845 $button = '<div class="generic-button" id="post-mention">'; 846 847 $button .= '<a href="' . wp_nonce_url( $bp->loggedin_user->domain . $bp->activity->slug . '/?r=' . bp_core_get_username( $bp->displayed_user->user_id, $bp->displayed_user->userdata->user_nicename, $bp->displayed_user->userdata->user_login ) ) . '" title="' . __( 'Mention this user in a new public message, this will send the user a notification to get their attention.', 'buddypress' ) . '">' . __( 'Mention this User', 'buddypress' ) . '</a>'; 842 848 843 return apply_filters( 'bp_get_send_public_message_link', $bp->loggedin_user->domain . $bp->activity->slug . '/?r=' . bp_core_get_username( $bp->displayed_user->user_id, $bp->displayed_user->userdata->user_nicename, $bp->displayed_user->userdata->user_login ) ); 849 $button .= '</div>'; 850 851 return apply_filters( 'bp_get_send_public_message_link', $button ); 852 } 853 return; 844 854 } 845 855 846 856 function bp_activity_post_form_action() { -
buddypress/bp-messages/bp-messages-templatetags.php
481 481 } 482 482 function bp_get_send_private_message_link() { 483 483 global $bp; 484 485 if ( is_user_logged_in() && !bp_is_my_profile() ) { 486 487 $button = '<div class="generic-button" id="send-private-message">'; 488 489 $button .= '<a href="' . wp_nonce_url( $bp->loggedin_user->domain . $bp->messages->slug . '/compose/?r=' . bp_core_get_username( $bp->displayed_user->user_id, $bp->displayed_user->userdata->user_nicename, $bp->displayed_user->userdata->user_login ) ) . '" title="' . __( 'Send a private message to this user.', 'buddypress' ) . '">' . __( 'Send Private Message', 'buddypress' ) . '</a>'; 484 490 485 return apply_filters( 'bp_get_send_public_message_link', $bp->loggedin_user->domain . $bp->messages->slug . '/compose/?r=' . bp_core_get_username( $bp->displayed_user->user_id, $bp->displayed_user->userdata->user_nicename, $bp->displayed_user->userdata->user_login ) ); 491 $button .= '</div>'; 492 493 return apply_filters( 'bp_get_send_private_message_link', $button ); 494 } 495 return; 486 496 } 487 497 488 498 function bp_send_message_button() {