本文整理汇总了PHP中BP_Messages_Thread::get_recipient_links方法的典型用法代码示例。如果您正苦于以下问题:PHP BP_Messages_Thread::get_recipient_links方法的具体用法?PHP BP_Messages_Thread::get_recipient_links怎么用?PHP BP_Messages_Thread::get_recipient_links使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类BP_Messages_Thread
的用法示例。
在下文中一共展示了BP_Messages_Thread::get_recipient_links方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: bp_get_message_thread_to
/**
* Generate HTML links to the pages of the current thread's recipients.
*
* @return string
*/
function bp_get_message_thread_to()
{
global $messages_template;
/**
* Filters the HTML links to the pages of the current thread's recipients.
*
* @since 1.0.0
*
* @param string $value HTML links to the pages of the current thread's recipients.
*/
return apply_filters('bp_message_thread_to', BP_Messages_Thread::get_recipient_links($messages_template->thread->recipients));
}
示例2: messages_view_thread
function messages_view_thread($thread_id)
{
global $bp;
$thread = new BP_Messages_Thread($thread_id, true);
if (!$thread->has_access) {
unset($_GET['mode']);
?>
<div id="message" class="error">
<p><?php
_e('There was an error when viewing that message', 'buddypress');
?>
</p>
</div>
<?php
} else {
if ($thread->messages) {
?>
<?php
$thread->mark_read();
?>
<div class="wrap">
<h2 id="message-subject"><?php
echo $thread->subject;
?>
</h2>
<table class="form-table">
<tbody>
<tr>
<td>
<img src="<?php
echo $bp->messages->image_base;
?>
/email_open.gif" alt="Message" style="vertical-align: top;" />
<?php
_e('Sent between ', 'buddypress');
?>
<?php
echo BP_Messages_Thread::get_recipient_links($thread->recipients);
?>
<?php
_e('and', 'buddypress');
?>
<?php
echo bp_core_get_userlink($bp->loggedin_user->id);
?>
.
</td>
</tr>
</tbody>
</table>
<?php
$counter = 0;
foreach ($thread->messages as $message) {
$alt = $counter % 2 == 1 ? ' alt' : '';
?>
<a name="<?php
echo 'm-' . $message->id;
?>
"></a>
<div class="message-box<?php
echo $alt;
?>
">
<div class="avatar-box">
<?php
echo apply_filters('bp_get_message_sender_avatar', bp_core_get_avatar($message->sender_id, 1));
?>
<h3><?php
echo apply_filters('bp_get_message_sender_id', bp_core_get_userlink($message->sender_id));
?>
</h3>
<small><?php
echo apply_filters('bp_get_message_date_sent', bp_format_time(strtotime($message->date_sent)));
?>
</small>
</div>
<?php
do_action('messages_custom_fields_output_before');
?>
<?php
echo apply_filters('bp_get_message_content', stripslashes($message->message));
?>
<?php
do_action('messages_custom_fields_output_after');
?>
<div class="clear"></div>
</div>
<?php
$counter++;
}
?>
<form id="send-reply" action="<?php
bp_messages_form_action();
//.........这里部分代码省略.........
示例3: bp_get_message_thread_to
function bp_get_message_thread_to()
{
global $messages_template;
return apply_filters('bp_message_thread_to', BP_Messages_Thread::get_recipient_links($messages_template->thread->recipients));
}