function youtube($video, $largura=640, $altura=480) { $video = explode("=", $video); $video = $video[1]; $video = explode("&", $video); $video = $video[0]; $video = str_replace("?v=", null, $video); return '<object width="'.$largura.'" height="'.$altura.'"><param name="movie" value="http://www.youtube.com/v/'.$video.'&hl=pt_BR&fs=1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/'.$video.'&hl=pt_BR&fs=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="'.$largura.'" height="'.$altura.'"></embed></object>'; } function youtube_title($video) { $video = get_meta_tags($video); return $video['title']; } function youtube_description($video) { $video = get_meta_tags($video); return $video['description']; }