Skip to content

Commit

Permalink
Update scraper.php
Browse files Browse the repository at this point in the history
  • Loading branch information
vikash12345 committed Sep 28, 2017
1 parent 6151569 commit 2abb7f9
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions scraper.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,14 @@
for($page = 0; $page < 100; $page+=50)
{
$NEWLINK = 'http://www.worldlii.org/cgi-bin/sinosrch.cgi?method=auto;meta=%2Fworldlii;mask_path=;mask_world=;query=a;results=50;submit=Search;rank=on;callback=off;legisopt=;view=relevance;offset='.$page;
$url = file_get_html($NEWLINK);
$ch = curl_init();
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_VERBOSE, 0);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/4.0 (compatible;)");
curl_setopt($ch, CURLOPT_URL, urlencode($url));
curl_setopt($ch, CURLOPT_URL, urlencode($NEWLINK));
$response = curl_exec($ch);
curl_close($ch);

echo $url;
}


Expand Down

0 comments on commit 2abb7f9

Please sign in to comment.