1 Commits
1.0.2 ... 1.0.3

Author SHA1 Message Date
James
432acb7475 add setUserAgent support
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing
2020-11-16 12:58:28 +00:00

View File

@@ -28,6 +28,10 @@ class Crawler{
$this->crawler->setCrawlProfile(new CrawlAllUrls()); $this->crawler->setCrawlProfile(new CrawlAllUrls());
} }
public function setUserAgent($agent){
$this->crawler->setUserAgent($agent);
}
public function crawl($url){ public function crawl($url){
$this->crawler->startCrawling($url); $this->crawler->startCrawling($url);
} }