Using getAttribute in Selenium 2 Webdriver 

In this example I will tell you how you can use selenium command getAttribute in Selenium 2 Webdriver. I had to use this as selenium.getAttribute was not working on Webdriver when I was using HtmlUnitDriver. It was working when I was using FirefoxDriver. I had to convert the selenium.getAttribute to make it work on both HtmlUnitDriver and FirefoxDriver.

Here is the HTML code I that I want to check:


Selenium Webdriver Forum -The Online Community for Selenium Webdriver and Selenium RC Users and Professionals

Leave a Reply