I am using PHPCRAWL and SIMPLEHTMLDOMPARSER to get some data from a public website. It has taken me forever to figure this out, but now I have another question that I am lost on.
Using the code below I can get the $first item for each page, but here is the catch there are multiple $first (maybe 2 or 3). I am trying to catch all $firsts for a given page as one variable, lets say $allfirst . Any guidance, advice is greatly appreciated.
$html=file_get_html("$DocInfo->url");
foreach ($html->find('div[id=sidebar] h4') as $e) {
$first = $e->next_sibling();
echo $first;
}