how to parse data from others website classes? Thats my code:
public function index()
{
$response = Curl::to('http://www.espn.com/nba/game?gameId=400874421')->get();
return dd($response);
}
In example I need score, what commands will filter the code that the score will only be left?
There are plenty of html parsers that can do this, though I would recommend Symfony DomCrawler Component.
http://symfony.com/doc/current/components/dom_crawler.html
$crawler = new Crawler($html);
$crawler = $crawler->filter('.score-class');