jafaripur / varzesh3-crawler
Crawler for varzesh3.com livescore
Installs: 48
Dependents: 0
Suggesters: 0
Security: 0
Stars: 3
Watchers: 1
Forks: 1
Open Issues: 0
pkg:composer/jafaripur/varzesh3-crawler
Requires
- fabpot/goutte: dev-master
This package is not auto-updated.
Last update: 2022-01-08 20:54:54 UTC
README
Varzesh3.com one of popular sport news agency in Iran. This crawler fetch the infomation from this website.
Install
Install using composer:
composer require "jafaripur/varzesh3-crawler"
Usage
After installing add this line in top of page
use jafaripur\varzesh3\Varzesh3Crawler;
And create new instance from Varzesh3Crawler
$crawler = new Varzesh3Crawler();
If you want to add fetching url use this one
$crawler = new Varzesh3Crawler('http://www.varzesh3.com/livescore');
Livescore
Fetching livescore for football
$crawler = new Varzesh3Crawler(); $data = $crawler->getFootballLiveScore();
for fetch all available sport like an footbal, volleyball,...
$data = $crawler->getLiveScore();
The structure of $data
variable similar to this one for football score:
(
[start_time] => start time
[start_date] => start date
[match_status] => match status, time or finished,...
[team_right] => Array
(
[name] => right team name
[score] => socre to this time
)
[team_left] => Array
(
[name] => left team name
[score] => socre to this time
)
[events] => Array
(
[team_left] => Array
(
[name] => name of event like an goal, own_goal,...
[time] => time of event
[player] => name of player
)
[team_right] => Array
(
[name] => name of event like an goal, own_goal,...
[time] => time of event
[player] => name of player
)
)
)