hedii/extractors 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

hedii/extractors

Composer 安装命令:

composer require hedii/extractors

包简介

Extractor is a package that find targeted types of resources in html dom.

README 文档

README

Build Status

Extractors

Extractor is a package that find targeted types of resources in html dom. Currently, only 2 types of resources are available: urls and emails. The found resources are returned as an array.

The Extractor class can be extended to add more resources types.

Install

Via Composer

composer require hedii/extractors

Usage

Currently, only 2 types of resources are available: urls and emails.

// require composer autoloader
require '/path/to/vendor/autoload.php';

// instantiate 
$extractor = new \Hedii\Extractors\Extractor();

// get all the urls on example.com page dom
$urls = $extractor->searchFor(['urls'])
    ->at('http://example.com')
    ->get();

// get all the emails on example.com page dom
$emails = $extractor->searchFor(['emails'])
    ->at('http://example.com')
    ->get();

// get all the urls and emails on example.com page dom
$urlsAndEmails = $extractor->searchFor(['urls', 'emails'])
    ->at('http://example.com')
    ->get();

Testing

composer test

统计信息

  • 总下载量: 1.63k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 7
  • 点击次数: 1
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 7
  • Watchers: 1
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2016-02-22

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固