I am new at testing so my apologies in advance if my question sounds a bit primary.
I am using Selenium and Java to write a test.
I know that
webElement.getAttribute("innerHTML");
brings me the innerHTML, for example for the element below:
<a href="#" class="ui-dialog-titlebar-close ui-corner-all" role="button" style="position: absolute; border-radius: 0px 0px 4px 4px;">
<span class="ui-icon ui-icon-closethick">close</span>
</a>
it returns:
<span class="ui-icon ui-icon-closethick">close</span>
but I need something that brings me the inner attribute of WebElement "a", something like below:
href="#" class="ui-dialog-titlebar-close ui-corner-all" role="button" style="position: absolute; border-radius: 0px 0px 4px 4px;"
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…