function asset_emfield_asset_search in Asset 6
Same name and namespace in other branches
- 5.2 contrib/asset_emfield/asset_emfield.module \asset_emfield_asset_search()
File
- contrib/
asset_emfield/ asset_emfield.module, line 171 - Asset Embedded Media Module
Code
function asset_emfield_asset_search($op = 'info', $type = NULL, $a3 = NULL) {
// load all of our provider includes inside the asset_emfield module folder
asset_emfield_system_list('asset_emfield');
$module = 'video_cck';
switch ($op) {
case 'info':
$providers = emfield_system_list($module);
$searches = array();
foreach ($providers as $provider) {
$info = emfield_include_invoke($module, $provider->name, 'asset_search', 'info');
if ($info && is_array($info)) {
$searches = $searches + $info;
}
}
return $searches;
case 'url':
$url = emfield_include_invoke($module, $type['emfield_provider'], 'asset_search', 'url', $type, $a3);
return $url;
case 'feed item':
$asset = emfield_include_invoke($module, $type['emfield_provider'], 'asset_search', 'feed item', $type, $a3);
return $asset;
}
}