bp_get_send_public_message_link()
Return the public message link for the displayed user.
Description Description
Return Return
(string) The public message link for the displayed user.
Source Source
File: bp-activity/bp-activity-template.php
function bp_get_send_public_message_link() {
// No link if not logged in, not looking at someone else's profile.
if ( ! is_user_logged_in() || ! bp_is_user() || bp_is_my_profile() ) {
$retval = '';
} else {
$args = array( 'r' => bp_get_displayed_user_mentionname() );
$url = add_query_arg( $args, bp_get_activity_directory_permalink() );
$retval = wp_nonce_url( $url );
}
/**
* Filters the public message link for the displayed user.
*
* @since 1.2.0
*
* @param string $retval The URL for the public message link.
*/
return apply_filters( 'bp_get_send_public_message_link', $retval );
}
Changelog Changelog
| Version | Description |
|---|---|
| 1.2.0 | Introduced. |