I have the following html
<div class="logo"><a href="/">***® text.<sup>TM</sup></a></div>
I would like to get the value of href
with php dom xpath, how would I accomplish that?
This is what I have tried:
$anchors = $domXpath->query("//div[@class='logo']/a");
foreach($anchors as $a)
{
print $a->nodeValue." - ".$a->getAttribute("href")."<br/>";
}