Function : get_thumb File : functions_videos.php Since : v2.x

This function is used to get thumbnails of a video.

This function will get all video thumbnails and list them in array, you can single thumbnail using incremental number or all thumbnails in an array or just count how many thumbnails are available. This function has few limitations that we will try to cover in upcoming updates.




  • default_thumb();

  • MyQuery->get_video_details();

paramater marked with * is required

Parameter Name


$vdetails (Array|Int) *

It can either be an array of video details or just videoid and it will automatically fetch video details

$num (Int)

incremental number of thumb, default is 1, depends on how many thumbs generation you have set, by default there are 3 thumbs that clipbucket generates so you can set this between 1 to 3.if set to 2 it will return http://website.tld/files/thumbs/filename-2.jpg

$multi (Boolean)

default is false, on setting true it will return a complete list of thumbs in an array.

$count (Boolean)

default is false, if set to true, this function will only return number of thumbs of videos (int)

$return_full_path (Boolean)

default is true, it will return thumbail with complete URL i.e, if set to false it will only return filename-1.jpg

$return_big (Boolean)

default is false, if set to true it will return big thumbnail of video, depends on what resolution you have set in configuration default is 320×240 and file name will be filename-big-1.jpg

$size (String)

default is null, depends on what size you want, it can be 120×90 or whatever sizes you have set for thumbs generation



	//set your videoid, it can also bevideokey
	$vid = 1236;
	$vdetails = get_video_details($vid);
	$default_thumb = get_thumb($vdetails);
	$second_thumb = get_thumb($vdetails,2);
	$all_thumbs = get_thumb($vdetails,NULL,true);
	$count_thumbs = get_thumb($vdetails,NULL,false,true);

	echo '<pre>';
	echo '</pre>';

Last updated