I am trying to identify a WebElement
in Mozilla browser using the xpath. Below is the html code:
<div id="address-book" class="grid-12" style="display:none;">
<!-- END ADDRESS BOOK -->
<!-- BEGIN PAYMENT OPTIONS -->
<div id="paymentSection" class="grid-12 form-section">
<div class="grid-contentx">
<div class="hd header-container">
<h3>Payment Information</h3>
</div>
</div>
<!-- BEGIN: CC FORMS -->
<div class="grid-6">
The relevant xpath I wrote in the page object factory is:
@FindBy(xpath = "//*[@id='paymentSection']/div[1]/div/h3")
private WebElement paysection;
Upon running the script, I am getting an error message "unable to identify the element". Please help me if there is any correction to be done to the identified xpath.