Php obtains video information and supports multiple websites.

Source: Internet
Author: User
Provides various official and user-released code examples. For code reference, you are welcome to exchange and learn about php to obtain video information and support multiple websites.

The usage is as follows: /**
* Parse video information
*
* Supports Youku and Tudou cool 6 56 Sina qq podcasts letv
**/



$ All ['url'] = 'parse ';
$ All ['youku'] = 'youku ';
$ All ['tuu'] = 'tuu ';
$ All ['ku6'] = 'ku6 ';
$ All ['56'] = '_ 56 ';
$ All ['sina '] = 'sina ';
$ All ['qq'] = 'qq ';
$ All ['lettv '] = 'lettv ';
$ All ['sohu '] = 'sohu ';

$ Value = empty ($ _ GET ['value'])? '': (String) $ _ GET ['value'];
$ Type = empty ($ _ GET ['type']) |! Is_string ($ _ GET ['type']) | empty ($ all [$ _ GET ['type'])? 'Url': $ _ GET ['type'];
?>




PHP parses video information


$ Select ='';Foreach ($ all as $ k => $ v ){$ Selected = $ type = $ k? 'Selected = "selected "':'';$ Select. =''. $ K .'';}$ Select. ='';
Echo '';
If (! $ Value ){
Die;
}

$ Class_video = new class_video;

Echo'
';
echo "\n\n\n";
print_r( call_user_func_array( array( $class_video, $all[$type] ), array( $value ) ) );
echo "\n\n\n";

?>

Source: http://www.chunci.cn/php-for-video-information-support-multiple-web-sites

Video.rar (6.29 KB download: 171 times)

AD: truly free, domain name + VM + enterprise mailbox = 0 RMB

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.