-
-
Notifications
You must be signed in to change notification settings - Fork 897
New issue
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
CSS3 :not() with children selectors #528
Comments
This doesn't appear to be valid CSS. It doesn't work in broswer and doesn't pass the validator. Here's an equivalent, valid code: *:not(.mslg) .r .l Or possibly: (I'm not sure what you want - this is an exact equivalent of what I assume you meant) *:not(.mslg) .r:not(.mslg) .l |
What I am attempting to do is get all of the organic urls on the google page. I am using selector gadget (http://www.selectorgadget.com/) to find an accurate path and it tells me that the path I created is an accurate CSS path. What I am attempting to get is the items in green (http://i.imgur.com/fQ5Jv.png). It could also be that selector gadgets paths are not working properly. I will try your suggestions. |
This is a valid request. Currently the state of our CSS selector parsing is a bit complex, which we're planning on overhauling for the next major release. |
.r .l:not(.mslg .l) This is not valid CSS. |
My previous comment, "This is a valid request" was not referencing the CSS spec -- it was stating my opinion that there's no technological reason we couldn't support this syntax. We already support some jQuery query syntax. |
I'm open to accepting a pull request for this functionality, but am unlikely to do that work myself. Closing. |
When I attempt to use nokogiri with doc.css('.r .l:not(.mslg .l)') I receive the error
I am simply trying to get urls from a google search page. This is what I'm doing
The text was updated successfully, but these errors were encountered: