We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I'm trying to generate the following xpath string (so that I get the deepest element that contains the text I need)
(//*[contains(normalize-space(string(.)), 'Text')]/@id)[position() = last()]
but
XPath.anywhere[XPath.string.n.contains('Text')].attr(:id)[XPath.position.equals(XPath.last)]
generates
//*[contains(normalize-space(string(.)), 'Text')]/@id[(position() = last())]
which is kinda logical, considering how the XPath gem works in general, but not what I want :)
I've looked through the code and looks like there's no way to add parenthesis to the on in a where expression, but maybe I'm missing something
on
where
I can't do the filtering in the ruby-land because this is only a part of my bigger XPath selector so I need it to return only one node
The text was updated successfully, but these errors were encountered:
Interesting! I don't think this is currently possible, unfortunately.
Sorry, something went wrong.
yeah, that's what i was afraid of :)
thx for the response
No branches or pull requests
I'm trying to generate the following xpath string (so that I get the deepest element that contains the text I need)
but
generates
which is kinda logical, considering how the XPath gem works in general, but not what I want :)
I've looked through the code and looks like there's no way to add parenthesis to the
on
in awhere
expression, but maybe I'm missing somethingI can't do the filtering in the ruby-land because this is only a part of my bigger XPath selector so I need it to return only one node
The text was updated successfully, but these errors were encountered: