这个是借力打力,只是抓去朋友网的内容!!!

不过相当好用哦!

看代码:

<?php
$videourl='http://v.youku.com/v_show/id_XMjA5MjQ0OTQ0.html';
function get_content($url ,$data){
	if(is_array($data)){
		$data = http_build_query($data, '', '&');	
	}
	$ch = curl_init();
	curl_setopt($ch, CURLOPT_RETURNTRANSFER, true );
	curl_setopt($ch, CURLOPT_POST, 1);
	curl_setopt($ch, CURLOPT_HEADER, 0);
	curl_setopt($ch, CURLOPT_URL,$url);
	curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
	$result = curl_exec($ch);
	return $result;
}
$str = get_content('http://share.pengyou.com/json.php?mod=usershare&act=geturlinfo',array('url'=>$videourl));
$str=json_decode($str);
var_dump($str);
?>