0

我遇到了与使用 Brightcove 媒体 API 在我的 Drupal 网站上制作视频库相关的问题。有人可以告诉我如何提取作者的详细信息,发布日期以及我需要在我的页面上与视频一起显示的视频的详细信息。我以某种方式设法在我的页面上显示视频,但我仍在努力提取其他详细信息并将其与我的视频一起显示在页面上。供您参考,我正在使用 Drupal 6。有人可以帮我解决这个问题吗?

4

1 回答 1

1

您可能想查看以下有用的链接:

http://opensource.brightcove.com/project/PHP-MAPI-Wrapper/ http://developer.brightcove.com/en/documentation

我不确定我理解您所说的“作者”是什么意思,Brightcove 目前不跟踪审计跟踪类型信息。例如,您无法查询是谁上传了视频。仅属于视频的元数据。

假设“作者”是一个自定义字段,您可以通过如下调用来获取该信息:

/**
 * function custom_search() - search specified field for given value
 * @param string [$term] - Required. The value to search for.
 * @param string [$criteria] - any, all, or none.  Default: any.
 * @param string [$search_field] - Specify the field to look for the search term in. Default: search_text.
 */
/** Available search fields: display_name, reference_id, tag, custom_fields, search_text. 
 *  Using search_text is the equivalent of searching displayName, shortDescription and longDescription fields
 *  and is also the same as omitting the field name altogether
 */
function custom_search($term, $criteria = 'any', $search_field = 'search_text') { 
    $bc = create_bcmapi();
    $params = array(
        'video_fields' => 'id,name,shortDescription,referenceId,tags,custom_fields'
      );
    $terms = array($criteria => $search_field.':'.$term); 

    $data['videos'] = $bc->search('video', $terms, $params);
    return $data;
}

对不起,这已经晚了,但也许它会帮助别人。

于 2012-03-20T18:08:34.067 回答