function hook_video_embed_handler_info in Video Embed Field 7.2
Same name and namespace in other branches
- 7 video_embed_field.api.php \hook_video_embed_handler_info()
@function hook_video_embed_handler_info Can be used to add more handlers for video_embed_field
Return value
an array of handlers, each handler is an array with the following keys: 'title' : required, the untranslated title of the provider, to show to the admin user. 'function' : required, the function used to generate the embed code. 'thumbnail_function' : optional, the function used to provide the thumbnail for a video. 'thumbnail_default : optional, the default thumbnail image to display in case thumbnail_function does not exist or has no results. 'data_function' : optional, the function to return an array of video data. 'form' : required, the function that returns the settings form for your provider. 'form_validate: optional the function that validates the settings form for your provider. 'domains' : required, an array of domains to match against, this is used to know which provider to use. 'defaults' : default values for each setting made configurable in your form function.
See also
hook_video_embed_handler_info_alter()
below for function definitions
3 functions implement hook_video_embed_handler_info()
Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.
- video_embed_brightcove_video_embed_handler_info in video_embed_brightcove/
video_embed_brightcove.module - Implements hook_video_embed_handler_info().
- video_embed_facebook_video_embed_handler_info in video_embed_facebook/
video_embed_facebook.module - Implements hook_video_embed_handler_info().
- video_embed_field_video_embed_handler_info in ./
video_embed_field.handlers.inc - Implements hook_video_embed_handler_info().
1 invocation of hook_video_embed_handler_info()
- video_embed_get_handlers in ./
video_embed_field.module - Creates a hook that other modules can implement to get handlers.
File
- ./
video_embed_field.api.php, line 32
Code
function hook_video_embed_handler_info() {
$handlers = array();
$handlers['ustream'] = array(
'title' => 'UStream',
'function' => 'your_module_handle_ustream',
'thumbnail_function' => 'your_module_handle_ustream_thumbnail',
'thumbnail_default' => drupal_get_path('module', 'your_module') . '/img/ustream.jpg',
'data_function' => 'your_module_handler_ustream_data',
'form' => 'your_module_handler_ustream_form',
'form_validate' => 'your_module_handler_ustream_form_validate',
'domains' => array(
'ustream.com',
),
'defaults' => array(
'width' => 640,
'height' => 360,
),
);
return $handlers;
}