aminulbd / spider
Grab latest feed from search engine like Google, Bing, WordPress, etc.
0.0.1
2023-08-27 10:39 UTC
Requires
- php: >=7.4.0
- symfony/css-selector: ^5.0
- symfony/dom-crawler: ^5.0
- symfony/http-client: ^5.0
This package is auto-updated.
Last update: 2024-04-27 12:08:53 UTC
README
Grab latest feed from search engine like Google, Bing, WordPress, etc.
Installation
Install the package using composer by using this command below.
composer require aminulbd/spider
Usage
Just import \AminulBD\Spider\Spider
package and construct it with supported driver and call the find
method like as below.
// require '../vendor/autoload.php'; // if you are going with standalone mode. use AminulBD\Spider\Spider; $engine = 'wordpress'; // supported: google, bing and wordpress $config = [ 'base_uri' => 'https://aminul.net/wp-json/wp/', // This is required for wordpress. ]; $spider = new Spider($engine, $config); $finder = $spider->find(['q' => 'WordPress']); $results = $finder->next(); // Here is your results. print_r($results);