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


PHP BP_Activity_Activity::check_exists_by_content方法代碼示例

本文整理匯總了PHP中BP_Activity_Activity::check_exists_by_content方法的典型用法代碼示例。如果您正苦於以下問題:PHP BP_Activity_Activity::check_exists_by_content方法的具體用法?PHP BP_Activity_Activity::check_exists_by_content怎麽用?PHP BP_Activity_Activity::check_exists_by_content使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在BP_Activity_Activity的用法示例。


在下文中一共展示了BP_Activity_Activity::check_exists_by_content方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: test_check_exists_by_content

 /**
  * @group check_exists_by_content
  */
 public function test_check_exists_by_content()
 {
     $content = 'A classy girl who know how to enjoy the freedom of a cup of coffee';
     $activity = $this->factory->activity->create(array('content' => $content, 'type' => 'activity_update'));
     $result = BP_Activity_Activity::check_exists_by_content($content);
     $this->assertEquals($activity, $result);
 }
開發者ID:JeroenNouws,項目名稱:BuddyPress,代碼行數:10,代碼來源:class.BP_Activity_Activity.php

示例2: bp_activity_check_exists_by_content

/**
 * Check whether an activity item exists with a given content string.
 *
 * @since BuddyPress (1.1.0)
 *
 * @uses BP_Activity_Activity::check_exists_by_content() {@link BP_Activity_Activity}
 * @uses apply_filters() To call the 'bp_activity_check_exists_by_content' hook.
 *
 * @param string $content The content to filter by.
 * @return int|null The ID of the located activity item. Null if none is found.
 */
function bp_activity_check_exists_by_content($content)
{
    return apply_filters('bp_activity_check_exists_by_content', BP_Activity_Activity::check_exists_by_content($content));
}
開發者ID:eresyyl,項目名稱:mk,代碼行數:15,代碼來源:bp-activity-functions.php

示例3: bp_activity_check_exists_by_content

/**
 * Check whether an activity item exists with a given content string.
 *
 * @since 1.1.0
 *
 * @uses BP_Activity_Activity::check_exists_by_content() {@link BP_Activity_Activity}
 * @uses apply_filters() To call the 'bp_activity_check_exists_by_content' hook.
 *
 * @param string $content The content to filter by.
 * @return int|null The ID of the located activity item. Null if none is found.
 */
function bp_activity_check_exists_by_content($content)
{
    /**
     * Filters the results of the check for whether an activity item exists by specified content.
     *
     * @since 1.1.0
     *
     * @param BP_Activity_Activity $content_exists ID of the activity if found, else null.
     */
    return apply_filters('bp_activity_check_exists_by_content', BP_Activity_Activity::check_exists_by_content($content));
}
開發者ID:humanmade,項目名稱:BuddyPress,代碼行數:22,代碼來源:bp-activity-functions.php


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