1

На страничке есть такой элемент по содержащему в нем тексту, т.е. нужно составить запрос, что бы в нем был Jacqueline Cako и 11/4

<div class="ipe-Participant ">
   <span class="ipe-Participant_OppName">Jacqueline Cako</span>
   <span class="ipe-Participant_OppOdds ">11/4</span>
</div>

Как найти именно div?

Результатов не дает:

webEngine.executeScript("document.evaluate('//*[contains(text(), \"Jacqueline Cako\") and contains(text(), \"13/8\")]', document, null, XPathResult.ANY_TYPE, null).iterateNext().innerText;");

Заранее спасибо

1 ответ 1

2

Столько времени убил, задал вопрос, тут же нашел то, что мне помогло. Решение document.evaluate('//div[contains(@class, "ipe-Participant") and contains(., "Jacqueline Cako") and contains(., "11/4")]', document, null, XPathResult.ANY_TYPE, null).iterateNext().innerText;);

Ваш ответ

By clicking “Отправить ответ”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Всё ещё ищете ответ? Посмотрите другие вопросы с метками или задайте свой вопрос.