Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
Kaji20976yHad to solve a similar issue with a table once. Is there some algorithmic pattern you can use that would allow nth-child?
Also, is it possible to put your own wrapper around the offending bit, perhaps? -
Salim3486y@devTea @stop @mt3o @buitrung @Kaji Thanks y'all for your suggestions.
tl;dr: It's a wor*press mess, I used nth-child, can't js.
Long talk:
The element I was trying to select was generated by a js script that's encapsulated in an another element generated by a wor*press theme. Aaaand I had control only over the element's children and the page wrapper.
I ended up by using nth-child like some of you suggested, even though I don't like it since the thing's order might change in the future.
It would have been a lot simpler if we had parent selectors... -
devTea219106y@Salim yeah but I’ve read it’s not possible since css render from top to bottom or something like that
Related Rants
CSS has no parent selectors... and the codebases' element I'm working on has no classes nor an id...
kill me
rant
killme