sephxd/php-readability
Composer 安装命令:
composer require sephxd/php-readability
包简介
Back the fun of reading - PHP Port of Arc90′s Readability: http://graceco.de/readability/
README 文档
README
Back the fun of reading
The PHP port of Readability.js by Arc90.
Requirements
- PHP Version >= 5
- PHP has builded with DOM(Document Object Model)
Live demo
http://graceco.de/readability/
Usage
require 'lib/Readability.inc.php';
$Readability = new Readability($html, $html_input_charset); // default charset is utf-8
$ReadabilityData = $Readability->getContent(); // throws an exception when no suitable content is found
// You can see more params by var_dump($ReadabilityData);
echo "<h1>".$ReadabilityData['title']."</h1>";
echo $ReadabilityData['content'];
PS: For Node.js port, You can check this.
统计信息
- 总下载量: 13
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: Unknown
- 更新时间: 2015-01-22