I have this, but it returns the URL of the web page. I want the "href" in a text string.
PATH_DATA = //[@id="vvp-product-details-modal--product-title"][@class="a-link-normal"]
WebElement myData = driver.findElement(By.xpath(PATH_DATA));
String url = myData.getAttribute("href")
It returns the URL of the web page. I want the "href" in a text string.
Snapshot: