junit - How can I get the text from a simple HTML tag using Selenium RC? -


how can text simple html tag

<h2>abcdef</h2> 

using selenium rc?

i want match exact text. if use istextpresent() returns true if put selenium.istextpresent("abc").

this in html tag <h2>.

then need following

strtext = selenium.gettext("//h2")  if strtext.equals("abcdef")      system.out.println("textmatch") else      system.out.println("text mismatch") 

Comments

Popular posts from this blog

apache - Remove .php and add trailing slash in url using htaccess not loading css -

javascript - jQuery show full size image on click -