<div class="siteList"><a href="https://test.com" target="_blank" rel="noopener nofollow"><div class="badge" style="background:transparent; position:absolute;"><img src="/img/ran.png" width="30" height="30"></div><li class="siteLogo"><img src="/data723_250x70.png" alt width="250" height="auto" title></li><li class="siteInfo"><h3 style="color:#000;font-weight:bold;">TestSite</h3></li></a></div>
I want to parse DIV.siteList in a href and text in H3
https://test.com, TestSite
foreach($html->find('div.siteList') as $element) {
echo $element->href . '<br>';
}
this is can’t
foreach($html->find('div.siteList') as $element) {
echo $element->href . '<br>';
}
but no data
New contributor
KOOLKOOLMAN is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.