Search Results for 'private message button'
-
AuthorSearch Results
-
October 30, 2013 at 9:11 am #173600
In reply to: Private Message button only appears sometimes
Anonymous User 13302461
InactiveAhh yes. seems to appear every time with default template. I will go to the theme support forum and ask there. Thanks.
October 29, 2013 at 7:32 pm #173573In reply to: Private Message button only appears sometimes
shanebp
ModeratorSwitch to the BP default theme or a WP theme like Twenty Thirteen.
Does the problem still exist?
If not, then the problem is in your custom theme.October 29, 2013 at 6:26 pm #173567In reply to: Private Message button only appears sometimes
Amid Dadgar
Participantthere should be 3 buttons (Add Friend,Public Message,private message) but as you said It just appears sometimes and I have a same problem 🙁
October 8, 2013 at 12:17 pm #172471In reply to: Private message users
chur74
ParticipantThank you very much for the reply, and I understand.
On the other hand I have seen that also can send public messages, but I can not display the button to send them, just see the private message when I activate the option.
thank you.
September 30, 2013 at 9:14 pm #172062In reply to: Duplicate Avatars in Activity Stream
Uncle Jimmy
Participant@Shanebp and @mercime [RESOLVED]
The following file was responsible. Comments marked !!!IMPORTANT!!! are where I made changes.
wp-content/plugins/gantry-buddypress/bpt-functions.php
<?php /** * @version 1.3 November 8, 2012 * @author RocketTheme, LLC http://www.rockettheme.com * @copyright Copyright © 2007 - 2012 RocketTheme, LLC * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only */ // Sets up WordPress theme for BuddyPress support. function gantry_bp_tpack_theme_setup() { global $bp, $gantry_bp_path; // Load the default BuddyPress AJAX functions if it isn't explicitly disabled require_once( $gantry_bp_path . '/_inc/ajax.php' ); if ( !is_admin() ) { ///!!!IMPORTANT!!!/// COMMENTED OUT BY UNCLEJIMMY [[FIXED MEMBER HEADER DUPLICATE BUTTONS Friends/Public Message/Private Message]] ///!!!IMPORTANT!!!/// ///!!!IMPORTANT!!!/// [[ALSO REDUCED QUADRUPAL MESSAGES/COMMENTS/REPLIES TO DUPLICATES]] ///!!!IMPORTANT!!!/// // Register buttons for the relevant component templates // Friends button //if ( bp_is_active( 'friends' ) ) //add_action( 'bp_member_header_actions', 'bp_add_friend_button' ); // Activity button //if ( bp_is_active( 'activity' ) ) //add_action( 'bp_member_header_actions', 'bp_send_public_message_button' ); // Messages button //if ( bp_is_active( 'messages' ) ) //add_action( 'bp_member_header_actions', 'bp_send_private_message_button' ); // Group buttons if ( bp_is_active( 'groups' ) ) { ///!!!IMPORTANT!!!/// COMMENTED OUT BY UNCLEJIMMY [[FIXED DUPLICATE GROUP BUTTON Join/Leave ]] ///!!!IMPORTANT!!!/// //add_action( 'bp_group_header_actions', 'bp_group_join_button' ); add_action( 'bp_group_header_actions', 'bp_group_new_topic_button' ); add_action( 'bp_directory_groups_actions', 'bp_group_join_button' ); } // Blog button if ( bp_is_active( 'blogs' ) ) add_action( 'bp_directory_blogs_actions', 'bp_blogs_visit_blog_button' ); } } add_action( 'after_setup_theme', 'gantry_bp_tpack_theme_setup', 11 ); // Enqueues BuddyPress JS and related AJAX functions function gantry_bp_enqueue_scripts() { // Enqueue the global JS - Ajax will not work without it wp_enqueue_script( 'dtheme-ajax-js', get_template_directory_uri() . '/_inc/global.js', array( 'jquery' ), bp_get_version() ); // Add words that we need to use in JS to the end of the page so they can be translated and still used. $params = array( 'my_favs' => __( 'My Favorites', 'buddypress' ), 'accepted' => __( 'Accepted', 'buddypress' ), 'rejected' => __( 'Rejected', 'buddypress' ), 'show_all_comments' => __( 'Show all comments for this thread', 'buddypress' ), 'show_x_comments' => __( 'Show all %d comments', 'buddypress' ), 'show_all' => __( 'Show all', 'buddypress' ), 'comments' => __( 'comments', 'buddypress' ), 'close' => __( 'Close', 'buddypress' ), 'view' => __( 'View', 'buddypress' ), 'mark_as_fav' => __( 'Favorite', 'buddypress' ), 'remove_fav' => __( 'Remove Favorite', 'buddypress' ), 'unsaved_changes' => __( 'Your profile has unsaved changes. If you leave the page, the changes will be lost.', 'buddypress' ), ); wp_localize_script( 'dtheme-ajax-js', 'BP_DTheme', $params ); // Maybe enqueue comment reply JS if ( is_singular() && bp_is_blog_page() && get_option( 'thread_comments' ) ) wp_enqueue_script( 'comment-reply' ); } add_action('wp_enqueue_scripts', 'gantry_bp_enqueue_scripts'); // Enqueues BuddyPress basic styles function gantry_bp_enqueue_styles() { global $gantry_bp_url; // Do not enqueue CSS if it's disabled if (get_option( 'gantry_bp_disable_css' )) return; // BP 1.5+ if ( version_compare( BP_VERSION, '1.3', '>' ) ) { $stylesheet = 'bp.css'; // Bump this when changes are made to bust cache $version = '20110918'; } // Add the wireframe BP page styles wp_enqueue_style( 'bp', $gantry_bp_url . '/' . $stylesheet, array(), $version ); // Enqueue RTL styles for BP 1.5+ if ( version_compare( BP_VERSION, '1.3', '>' ) && is_rtl() ) wp_enqueue_style( 'bp-rtl', $gantry_bp_url . '/' . 'bp-rtl.css', array( 'bp' ), $version ); } add_action('wp_enqueue_scripts', 'gantry_bp_enqueue_styles'); // Gantry BuddyPress plugin doesn't use bp-default's built-in sidebar login block, // so during no access requests, we need to redirect them to wp-login for // authentication. if (!function_exists('gantry_bp_use_wplogin')) { function gantry_bp_use_wplogin() { // returning 2 will automatically use wp-login return 2; } add_filter('bp_no_access_mode', 'gantry_bp_use_wplogin' ); } // Hooks into the 'bp_get_activity_action_pre_meta' action to add secondary activity avatar support function gantry_bp_activity_secondary_avatars( $action, $activity ) { // sanity check - some older versions of BP do not utilize secondary activity avatars if ( function_exists( 'bp_get_activity_secondary_avatar' ) ) : switch ( $activity->component ) { case 'groups' : case 'friends' : // Only insert avatar if one exists if ( $secondary_avatar = bp_get_activity_secondary_avatar() ) { $reverse_content = strrev( $action ); $position = strpos( $reverse_content, 'a<' ); $action = substr_replace( $action, $secondary_avatar, -$position - 2, 0 ); } break; } endif; return $action; } ///!!!IMPORTANT!!!/// COMMENTED OUT BY UNCLEJIMMY [[FIXED DUPLICATE AVTIVITY STREAM AVATARS]] ///!!!IMPORTANT!!!/// ///!!!IMPORTANT!!!/// [[ALSO FIXED DUPLICATE MESSAGES/COMMENTS/REPLIES]] ///!!!IMPORTANT!!!/// //add_filter('bp_get_activity_action_pre_meta', 'gantry_bp_activity_secondary_avatars', 10, 2);Thank you for your time and attention, please let me know if I could’ve done this better.
God Bless
September 22, 2013 at 10:38 pm #171677In reply to: Two installations have failed
Eric J T
ParticipantSorry I didn’t include the code for that. Yes, it is in the wp functions.php file, but it is relevant to bp theme. Here is the full function that line 100 is found in. Line 100 is the third to last, which starts with “add action”.
/** * Sets up theme defaults and registers support for various WordPress and BuddyPress features. * * Note that this function is hooked into the after_setup_theme hook, which runs * before the init hook. The init hook is too late for some features, such as indicating * support post thumbnails. * * To override bp_dtheme_setup() in a child theme, add your own bp_dtheme_setup to your child theme's * functions.php file. * * @global BuddyPress $bp The one true BuddyPress instance * @since BuddyPress (1.5) */ function bp_dtheme_setup() { // Load the AJAX functions for the theme require( get_template_directory() . '/_inc/ajax.php' ); // This theme styles the visual editor with editor-style.css to match the theme style. add_editor_style(); // This theme comes with all the BuddyPress goodies add_theme_support( 'buddypress' ); // This theme uses post thumbnails add_theme_support( 'post-thumbnails' ); // Add default posts and comments RSS feed links to head add_theme_support( 'automatic-feed-links' ); if ( ! is_admin() || ( defined( 'DOING_AJAX' ) && DOING_AJAX ) ) { // Register buttons for the relevant component templates // Friends button if ( bp_is_active( 'friends' ) ) add_action( 'bp_member_header_actions', 'bp_add_friend_button', 5 ); // Activity button if ( bp_is_active( 'activity' ) && bp_activity_do_mentions() ) add_action( 'bp_member_header_actions', 'bp_send_public_message_button', 20 ); // Messages button if ( bp_is_active( 'messages' ) ) add_action( 'bp_member_header_actions', 'bp_send_private_message_button', 20 ); // Group buttons if ( bp_is_active( 'groups' ) ) { add_action( 'bp_group_header_actions', 'bp_group_join_button', 5 ); add_action( 'bp_directory_groups_actions', 'bp_group_join_button' ); } // Blog button if ( bp_is_active( 'blogs' ) ) add_action( 'bp_directory_blogs_actions', 'bp_blogs_visit_blog_button' ); } } add_action( 'after_setup_theme', 'bp_dtheme_setup' ); endif; if ( !function_exists( 'bp_dtheme_enqueue_scripts' ) ) :In the first install the failed bp had been installed and working for a few days. It suddenly gave errors when I edited a css color code on line 1211 in this file and uploaded it to the server by ftp. Yeah, I know you might say I made a mistake, but I know I did it correctly. And they you might say the file got corrupted in transfer, except that the second install on godaddy had no such changes or transfers and in short order – less than an hour of use with no other plugins or style changes – gave the same final error for line 100 when I changed my public name in the buddypress members listing, at which point neither the front nor back ends were accessible.
Looking forward to your insights.
August 25, 2013 at 8:51 pm #170404In reply to: Private Message Button Label Change
funmi omoba
Participantthanks for your reply I thought as much but I think it get wiped during the plugin update.
Thanks for your input anyways.
Best Regards
August 25, 2013 at 8:41 pm #170403In reply to: Private Message Button Label Change
shanebp
ModeratorOpen the plugin file, find the text, replace the text
August 25, 2013 at 7:48 pm #170400In reply to: Private Message Button Label Change
funmi omoba
ParticipantThanks for your snippet which works great with standard buddypress message system but did not work if using BP Profile Message UX plugin, is there anyway to make it work please
https://wordpress.org/plugins/bp-profile-message-ux/
tahnks
August 25, 2013 at 5:00 pm #170392In reply to: Private Message Button Label Change
Henry
Member@shanebp good point about using the bp_send_private_message_link approach. Although you would avoid double buttons by using a translation file.
August 25, 2013 at 4:44 pm #170389In reply to: Private Message Button Label Change
shanebp
Moderator@henrywright-1
And how would you avoid double buttons due to this call in member-header.php?
do_action( ‘bp_member_header_actions’ );
@tayenewm
Use the provided apply_filters:function tweak_button_label ( $args ) { $args[link_text] = 'Something'; return $args; } add_filter( 'bp_get_send_message_button_args', 'tweak_button_label', 1, 1 );August 25, 2013 at 4:28 pm #170387In reply to: Private Message Button Label Change
Henry
Memberactually you could make use of the
bp_send_private_message_linkfunction and do it like this:<a href="<?php bp_send_private_message_link() ?>" title="Private Message">Private Message</a>You can change the “Private Message” text to whatever you like. You’d just paste the code into your theme where ever you’d like the button to appear
August 25, 2013 at 4:20 pm #170386In reply to: Private Message Button Label Change
Henry
MemberYou could do it like that but each time you update BuddyPress you’ll lose the changes you’ve made to bp-messages-template.php. I’d try to avoid making changes to the plugin core.
August 25, 2013 at 4:18 pm #170385In reply to: Private Message Button Label Change
tayenewm
ParticipantThat process seems beyond me and very long (and I cannot find the /plugins/buddypress/bp-languages folder) I just want to change the “Private Message” button label. Can I access/change it quickly like this:
1. access buddypress/bp-messages/bp-messages-template.php
2. change the ‘link text’ to the new label name in this block of code?function bp_get_send_message_button() {
// Note: ‘bp_get_send_message_button’ is a legacy filter. Use
// ‘bp_get_send_message_button_args’ instead. See #4536
return apply_filters( ‘bp_get_send_message_button’,
bp_get_button( apply_filters( ‘bp_get_send_message_button_args’, array(
‘id’ => ‘private_message’,
‘component’ => ‘messages’,
‘must_be_logged_in’ => true,
‘block_self’ => true,
‘wrapper_id’ => ‘send-private-message’,
‘link_href’ => bp_get_send_private_message_link(),
‘link_title’ => __( ‘Send a private message to this user.’, ‘buddypress’ ),
‘link_text’ => __( ‘Private Message’, ‘buddypress’ ),
‘link_class’ => ‘send-message’,
) ) )August 25, 2013 at 1:58 pm #170380In reply to: Private Message Button Label Change
Henry
MemberThis will help you. It shows you how to change most of the text labels and messages outputted by BuddyPress:
https://codex.buddypress.org/developer/customizing/customizing-labels-messages-and-urls/
July 28, 2013 at 11:19 am #168939In reply to: BuddyPress 1.8 Issue
GhostPool
ParticipantI already have the following in my custom BP functions file:
if(bp_is_active('friends')) add_action('bp_member_header_actions', 'bp_add_friend_button'); if(bp_is_active('activity') && bp_activity_do_mentions()) add_action('bp_member_header_actions', 'bp_send_public_message_button'); if(bp_is_active('messages')) add_action('bp_member_header_actions', 'bp_send_private_message_button'); // Group Buttons if(bp_is_active('groups')) { add_action('bp_group_header_actions', 'bp_group_join_button'); add_action('bp_group_header_actions', 'bp_group_new_topic_button'); add_action('bp_directory_groups_actions', 'bp_group_join_button'); }As I say these buttons displayed in the theme in v1.7.3, they only disappear in v1.8. I think you’re right of course, it looks like a theme issue, I just cannot figure out what changed in v1.8 to stop these buttons working in my theme.
July 27, 2013 at 2:44 pm #168900In reply to: BuddyPress 1.8 Issue
GhostPool
ParticipantNobody else has had the same issue? Lets try a different tact. Has there been any changes made to private message, add friend and public message buttons in 1.8?
July 1, 2013 at 10:11 am #167336In reply to: show header item when user not login in buddypress
designweb
Participant@bphelp Thank for your reply. my question is simple. i need to show member header item which include (add friend, send private message etc). which are not showing when user are not login. i need to remove login to see header item button condition . any way to do this.
June 28, 2013 at 10:35 pm #167154In reply to: Private Message Button in Member List Loop
Henry
MemberI’m still scratching my head with this one. It must be my install playing games. In the end I got it working with
Anyway I thought why not just build the link and throw it directly in the friends template?
June 28, 2013 at 4:16 pm #167111In reply to: Private Message Button in Member List Loop
kizmark
Participant@Henry, Did you got it solved?
I’m having the same question.. I want to get the link to have a send private message button
April 27, 2013 at 5:30 pm #162886In reply to: Private Message Button in Member List Loop
Henry
Member@shanebpdev
For the life of me I cannot figure out why it doesn’t work for the friends loop. Am I missing something glaringly obvious?
Anyway I thought why not just build the link and throw it directly in the friends template?
echo wp_nonce_url( bp_loggedin_user_domain() . bp_get_messages_slug() . '/compose/?r=' . bp_core_get_username( bp_get_member_user_id() ) );April 27, 2013 at 3:29 pm #162881In reply to: Private Message Button in Member List Loop
shanebp
ModeratorI’m not going to spoon-feed this to you.
But you’re on the right track.
( I should have said ‘ The clue is in your reply…’ )
You’ve found what is the same in those two situations.
So what is different about them ?Sometimes it’s easier to start anew.
For example – instead of ‘how to I change this to do that’, start with ‘how do I do that’.Use echo to confirm the required variables.
Use var_dump to expose all the fields in objects.April 27, 2013 at 2:40 pm #162878In reply to: Private Message Button in Member List Loop
Henry
Member@shanebp you mean the bp_directory_members_item is different? That is the same in both the members directory and the friends list (both use the members loop)…
April 27, 2013 at 2:00 pm #162876In reply to: Private Message Button in Member List Loop
shanebp
Moderator@henrywright-1
What’s different? The answer is in your reply “Thanks for that… ”
@valuser
That usage makes sense and has been mentioned by others.
But it’s not a simple tweak.
And would require an admin screen so you could choose to show / not show the button in loops.
And etc. etc.
I’ll write an article in the next week or so on
PhiloPressApril 27, 2013 at 11:17 am #162868In reply to: Private Message Button in Member List Loop
valuser
ParticipantThanks for function https://gist.github.com/shanebp/5391229
works bp 1.7, wp 3.5.1, bbPress 2.3.1 Theme: Child of bp Befault
Any chance that it might call up your BP Profile Message UX 1.1.3
-
AuthorSearch Results