You are here

function video_cck_youtube_request in Embedded Media Field 5

this is a wrapper for video_cck_request_xml that includes youtube's api key

File

contrib/video_cck/providers/youtube.inc, line 205

Code

function video_cck_youtube_request($method, $args = array(), $cached = TRUE) {
  $args['dev_id'] = trim(variable_get('video_cck_youtube_api_key', ''));
  $args['method'] = $method;

  // if we've got a secret sign the arguments
  // TODO: doesn't seem to matter
  //  if ($secret = trim(variable_get('video_cck_youtube_api_secret', ''))) {
  //    $args['api_sig'] = md5($secret . $arghash);
  //  }
  $request = module_invoke('emfield', 'request_xml', 'youtube', VIDEO_CCK_YOUTUBE_REST_ENDPOINT, $args, $cached);
  return $request;
}