* @copyright Prateek Choudhary */ $videodiv = ''; $width = "600"; $height = "400"; $file = $vars['entity']; if(isset($vars['entity'])) { $videos = get_entity($vars['entity']); $title = $videos->title; $url = $videos->url; $videoid = $videos->video_id; $videodiv = "

".$title."

"; if ($videos->videotype == "youtube") { $videodiv .= "
"; } else if($videos->videotype == "metacafe"){ $videoid_id = $videoid; $path = explode("/", $videos->thumbnail); $path = array_reverse($path); $thumbnailArray = explode(".", $path[0]); $videoid = $videoid_id."/".$thumbnailArray[0].".swf"; $videodiv .= "
"; } else if($videos->videotype == "vimeo") { $videodiv .= "
"; } $videodiv .= "
"; $videodiv .= elgg_view_likes($videos); $videodiv .= elgg_view_comments($videos); print $videodiv; //echo elgg_view_comments($videos); }