Im using HtmlAgilityPack/HAP so that I can use Xpath with HTML documents.
I need help selecting the preceding-sibling of div class=”address” in this url:
http://www.yellowpages.ca/search/si-geo/1/sh/Ottawa,+ON
The sibling that I want is h3 class=”listingTitleLine”
Here is a screenshot:
http://i55.tinypic.com/25gc4qo.png
Can I get some help please.
-Dd,
To select the
preceding-siblingH3 element with the class attribute value of “listingTitleLine”:To select each of the H3 elements with a class attribute value of “linstingTitleLine” that are preceding-siblings of div elements with a class attribute value of “address”: