I am unable to scrape this website
Through browser, I am able to get only after I do a search and then I can navigate to any page.
Through code, I am unable to get data.
Below is my code:
$url = "http://assessor.islandcountywa.gov/propertyaccess/SearchResults.aspx?cid=0&rtype=address&page=";
for($i=1; $i<=1239 ; $i++)
{
$starturl = $url.$i;
echo "
Scrpaing URL -> $starturl
";
$context = stream_context_create();
stream_context_set_params($context, array('user_agent' => 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.86 Safari/537.36'));
$dom = file_get_html($starturl, 0, $context);
$rows = $dom->find("table[id=propertySearchResults_resultsTable]/td/tr");
echo "
** Rows is ***
".count($rows);
I am getting 0 rows, and the html page that is retrieved is that of this URL