プロジェクトは一時的に作成されました。改善すべき点:
switch ($type){
case 'youku' :
if( $domain == 'player' ) {
$swf = $url;
}else if( $domain == 'v' ) {
preg_match_all(' /http://v.youku.com/v_show/id_(.*)?.html/',$url,$url_array);
$swf = 'http://player.youku.com/player.php/ sid/'.str_replace('/','',$url_array[1][0]).'/v.swf';
}else{
$swf = $url;
}
}
休憩;
case 'tudou ' :
if($isswf){
$swf = $url;
}else{
$method = = 'p' ? 'v' : $method ;
preg_match_all('/http://www.tudou.com/(.*)?/(.*)?/',$url,$url_array);
$str_arr =explode(' /',$url_array[1][0]);
$count = count($str_arr);
if($count == 1) {
$id =explode('.',$url_配列[2][0 ])[0];
}else if($count == 2){
$id = $str_arr[1];
}else if($count == 3){
$id = $str_arr[2];
}
$swf = 'http://www.tudou.com/'.$method.'/'.$id.'/v.swf';
}
ブレーク;
デフォルト:
$swf = $url ;
Break;
}
return $swf;
}