How can I select the next node after an defined comment? I know the text of the comment and need the next nodes.
Best regards
Christoph
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Supposing the comment is a child of the current node, and the comment’s text is
"comment-text", then the following XPath expression selects the first element (sibling) that follows the comment node:If we want the following element to be selected (regardless if it is sibling of the comment or not), the corresponding XPath expression is: