albertkampde/youtube-downloader
Composer 安装命令:
composer require albertkampde/youtube-downloader
包简介
PHP library for download videos from Youtube
关键字:
README 文档
README
This library is a PHP implementation of Youtube-dl for downloading video from Youtube and other sites.
Installation
Youtube-dl has must be installed first.
Installation using Composer:
{
"require": {
"albertkampde/youtube-downloader": "dev-master"
}
}
Examples
Download
use Youtubedl\Youtubedl; $youtubedl=new Youtubedl(); $youtubedl->getOption() ->setOutput("\"/tmp/%(title)s.%(ext)s\""); $youtubedl->download('BaW_jenozKc') ->execute();
Multiple Download
use Youtubedl\Youtubedl; $youtubedl=new Youtubedl(); $youtubedl->getOption() ->setOutput("\"/tmp/%(title)s.%(ext)s\""); $youtubedl->download(array('BaW_jenozKc','dOibtqWo6z4')) ->execute();
Extractor List
use Youtubedl\Youtubedl; $youtubedl=new Youtubedl(); $youtubedl->getOption() ->getListExtractors(); echo $youtubedl->execute();
Extractor Descriptions
use Youtubedl\Youtubedl; $youtubedl=new Youtubedl(); $youtubedl->getOption() ->getExtractorDescriptions(); echo $youtubedl->execute();
User Agent
use Youtubedl\Youtubedl; $youtubedl=new Youtubedl(); $youtubedl->getOption() ->setUserAgent('Opera/9.80 (Windows NT 6.0) Presto/2.12.388 Version/12.14') ->dumpUserAgent(); echo $youtubedl->execute();
统计信息
- 总下载量: 84
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 2
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2016-01-27