Skip to content

Commit d9a70fc

Browse files
Minor update on readme
1 parent b09d743 commit d9a70fc

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

README.md

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
# php-scrape [![Build Status](https://travis-ci.org/rajanrx/php-scrape.svg?branch=master)](https://travis-ci.org/rajanrx/php-scrape)
1+
# PHP Scrape [![Build Status](https://travis-ci.org/rajanrx/php-scrape.svg?branch=master)](https://travis-ci.org/rajanrx/php-scrape)
22
A scraping framework written in PHP
33

4-
## About PHP-scrape
4+
## About PHP Scrape
55
Php Scrape is a basic scraping framework for PHP based on configuration first
66
concept. i.e once implemented changes should be made on configuration file as far
77
as possible avoiding need for code update/addition.
88

99
## Getting Started
10-
The easiest way to use Php-Scrape is via Composer.
10+
The easiest way to use PHP Scrape is via Composer.
1111
```
1212
composer require --dev rajanrx/php-scrape
1313
```
@@ -25,15 +25,23 @@ code
2525
use Scraper\Scrape\Crawler\Types\GeneralCrawler;
2626
use Scraper\Scrape\Extractor\Types\MultipleRowExtractor;
2727
require_once(__DIR__ . '/../vendor/autoload.php');
28-
date_default_timezone_set('UTC');
28+
29+
// Grab the crawler
2930
$crawler = new GeneralCrawler('https://github.com/trending');
31+
32+
// Get config using configuration manager
3033
$path = __DIR__ . "/Data/git-repo.json";
3134
$configurationManager =
3235
\Scraper\Scrape\ConfigurationManager::getInstance($path);
36+
37+
// Run extractor (Multiple) as we need to grab multiple rows for Github
38+
// trending repos
3339
$extractor = new MultipleRowExtractor(
3440
$crawler, $configurationManager->getConfiguration()
3541
);
3642
$data = $extractor->extract();
43+
44+
// Print retrieved data
3745
print_r($data);
3846
```
3947

@@ -69,7 +77,7 @@ Array
6977
)
7078
...
7179
```
72-
As easy as that. Docs in detail will be updated soon.
80+
As easy as that. Docs in detail will be updated soon.
7381
Interested contributors are hearty welcome.
7482

7583
## Security Vulnerabilities

0 commit comments

Comments
 (0)