本文整理汇总了PHP中unknown_type::output方法的典型用法代码示例。如果您正苦于以下问题:PHP unknown_type::output方法的具体用法?PHP unknown_type::output怎么用?PHP unknown_type::output使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类unknown_type
的用法示例。
在下文中一共展示了unknown_type::output方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: bp_em_record_activity_event_save
/**
* Records new events to the activity stream.
* @param unknown_type $result
* @param unknown_type $EM_Event
* @return unknown
*/
function bp_em_record_activity_event_save($result, $EM_Event)
{
if ($result && $EM_Event->status == 1 && ($EM_Event->previous_status == 0 || !empty($EM_Event->is_new))) {
$user = get_userdata($EM_Event->owner);
bp_em_record_activity(array('user_id' => $user->ID, 'action' => sprintf(__('%s added a the event %s', 'dbem'), "<a href='" . get_bloginfo('wpurl') . '/' . BP_MEMBERS_SLUG . '/' . $user->user_login . "/'>" . $user->display_name . "</a>", $EM_Event->output('#_EVENTLINK')), 'primary_link' => $EM_Event->output('#_EVENTURL'), 'type' => 'new_event', 'item_id' => $EM_Event->id));
}
return $result;
}
示例2: bp_em_record_activity_event_save
/**
* Records new events to the activity stream.
* @param unknown_type $result
* @param unknown_type $EM_Event
* @return unknown
*/
function bp_em_record_activity_event_save($result, $EM_Event)
{
if ($result && $EM_Event->status == 1 && ($EM_Event->previous_status == 0 || !empty($EM_Event->is_new))) {
$user = get_userdata($EM_Event->owner);
bp_em_record_activity(array('user_id' => $user->ID, 'action' => sprintf(__('%s added the event %s', 'dbem'), "<a href='" . get_bloginfo('wpurl') . '/' . BP_MEMBERS_SLUG . '/' . $user->user_login . "/'>" . $user->display_name . "</a>", $EM_Event->output('#_EVENTLINK')), 'primary_link' => $EM_Event->output('#_EVENTURL'), 'type' => 'new_event', 'item_id' => $EM_Event->id));
//group activity
if (!empty($EM_Event->group_id)) {
//tis a group event
$group = new BP_Groups_Group($EM_Event->group_id);
bp_em_record_activity(array('user_id' => $user->ID, 'action' => sprintf(__('%s added the event %s of the %s group.', 'dbem'), "<a href='" . get_bloginfo('wpurl') . '/' . BP_MEMBERS_SLUG . '/' . $user->user_login . "/'>" . $user->display_name . "</a>", $EM_Event->output('#_EVENTLINK'), '<a href="' . bp_get_group_permalink($group) . '">' . bp_get_group_name($group) . '</a>'), 'component' => 'groups', 'type' => 'new_event', 'item_id' => $EM_Event->group_id));
}
}
return $result;
}
示例3: bp_em_record_activity_event_save
/**
* Records new events to the activity stream.
* @param unknown_type $result
* @param unknown_type $EM_Event
* @return unknown
*/
function bp_em_record_activity_event_save($result, $EM_Event)
{
if ($result && $EM_Event->event_status == 1 && $EM_Event->get_previous_status() != 1) {
$user = get_userdata($EM_Event->event_owner);
$member_link = bp_core_get_user_domain($user->ID);
if (empty($EM_Event->group_id)) {
bp_em_record_activity(array('user_id' => $user->ID, 'action' => sprintf(__('%s added the event %s', 'dbem'), "<a href='" . $member_link . "'>" . $user->display_name . "</a>", $EM_Event->output('#_EVENTLINK')), 'primary_link' => $EM_Event->output('#_EVENTURL'), 'type' => 'new_event', 'item_id' => $EM_Event->event_id, 'hide_sitewide' => $EM_Event->event_private));
} else {
//tis a group event
$group = new BP_Groups_Group($EM_Event->group_id);
bp_em_record_activity(array('user_id' => $user->ID, 'action' => sprintf(__('%s added the event %s to %s.', 'dbem'), "<a href='" . $member_link . "'>" . $user->display_name . "</a>", $EM_Event->output('#_EVENTLINK'), '<a href="' . bp_get_group_permalink($group) . '">' . bp_get_group_name($group) . '</a>'), 'component' => 'groups', 'type' => 'new_event', 'item_id' => $EM_Event->group_id, 'hide_sitewide' => $EM_Event->event_private));
}
}
return $result;
}