[Solved] i want to extract the href having same classname in selenium [closed]


You can use this code:

String hrefValue = driver.FindElement(By.XPath("//li/span[@class="mreinfp comp-text"]/a[@href]")).getAttribute("href");

You will have the href value in hrefValue

1

solved i want to extract the href having same classname in selenium [closed]