當前位置: 首頁>>代碼示例>>PHP>>正文


PHP unknown_type::output方法代碼示例

本文整理匯總了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;
}
開發者ID:hypenotic,項目名稱:slowfood,代碼行數:14,代碼來源:bp-em-activity.php

示例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;
}
開發者ID:hypenotic,項目名稱:slowfood,代碼行數:20,代碼來源:bp-em-activity.php

示例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;
}
開發者ID:batruji,項目名稱:metareading,代碼行數:21,代碼來源:bp-em-activity.php


注:本文中的unknown_type::output方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。