好吧,首先代碼:另一個Xpath的困境
<tr class="tableControlDataRow evenRow twTableTR">
<td class="twTableTD details" align="center" rowspan="2">
<td class="twTableTD details" align="center" rowspan="2">
<p>
<br>
**<p>**
<b>Model Number:</b>
QA GM 05132014 1038 Item 1 Model Number
</p>
<p>
<p>
<p>
<p>
</td>
<td class="twTableTD" align="center" rowspan="2">May-27-2014</td>
<td class="twTableTD" align="center">France</td>
<td class="twTableTD" align="center">Yes</td>
<td class="twTableTD" align="center">
<input id="hiddenCountryAuthorizationField0_0" type="hidden" name="tw#local#quoteComparison#0#country#0#authorizationStatusId#" value="0">
<input id="CountryAuthorizationYES0_0" class="qclCheckbox" type="checkbox" onclick="chooseAuthorization(0,0,'Yes','1')">
Yes
<br>
<input id="CountryAuthorizationNO0_0" class="qclCheckbox" type="checkbox" onclick="chooseAuthorization(0,0,'No','2')">
No
<br>
</td>
現在的問題......我已經做了
//p[contains(., "QA GM 05132014 1038 Item 1 Model Number")]
這讓我的**部分找到正確的出發點的代碼。現在我需要遍歷到<tr class="tableControlDataRow evenRow twTableTR">
頂部,然後乘車返回環比下跌點擊
<input id="CountryAuthorizationYES0_0" class="qclCheckbox" type="checkbox" onclick="chooseAuthorization(0,0,'Yes','1')">
文本框。有什麼建議麼?
試過在FirePath並沒有返回匹配的節點... – GregMa
@GregMa可能大家分享一個鏈接到你解析的頁面? – alecxe
它是內部的,所以不能。但我確實弄清楚了。看起來像我粘貼的代碼是不正確的。我使用@id,'CountryAuthorizationYES',它工作。 – GregMa