本文整理匯總了PHP中KalturaClient::doMultiRequest方法的典型用法代碼示例。如果您正苦於以下問題:PHP KalturaClient::doMultiRequest方法的具體用法?PHP KalturaClient::doMultiRequest怎麽用?PHP KalturaClient::doMultiRequest使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類KalturaClient
的用法示例。
在下文中一共展示了KalturaClient::doMultiRequest方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: KalturaMetadataFilter
//return only the relevant profile
$client->metadata->listAction($filter);
//since we're limiting to entry id and profile this will return at most 1 result
//Request #3: get the entry's payment metadata
$filter = new KalturaMetadataFilter();
$filter->metadataObjectTypeEqual = KalturaMetadataObjectType::CATEGORY;
//search for all category metadatas
$filter->objectIdIn = '{1:result:categoriesIds}';
//return metadata for all categories of the given entry (categories taken from result of request #1)
$filter->metadataProfileIdEqual = PAYPAL_CATEGORY_METADATA_PROFILE_ID;
//return only the relevant profile
$pager = new KalturaFilterPager();
$pager->pageSize = 500;
$pager->pageIndex = 1;
$client->metadata->listAction($filter, $pager);
$multiRequest = $client->doMultiRequest();
//Call the server with the bundeled requests
$metaResults = $multiRequest[1];
//get result of response #2 (payment metadata of the given entry)
$price = 0;
$currencyCode = 'USD';
$tax = 0;
$also = "";
//Checks to see if the individual video has a price and displays it
if ($metaResults->totalCount > 0) {
$metaResult = $metaResults->objects[0];
$xml = simplexml_load_string($metaResult->xml);
$price = (double) $xml->Price;
$currencyCode = (string) $xml->CurrencyCode;
$tax = (double) $xml->TaxPercent;
$also = 'also ';