I have the following code:
<div class="photos-wrapper" id="detailPhoto">
<div class="pseudo">
<a href="#/123456/">fixedTEXT</a>
</div>
<div class="image-wrapper">
<a href="#"></a>
</div>
<div class="activites">
<a href="#"></a>
</div>
<div class="commentaire">
<a href="#"></a>
</div>
</div>
I want to include my own CSS style to this first and main <div class="photos-wrapper" id="detailPhoto">
but the only way to do this is by identify the grandchild selector i.e <a href="#/123456/">
because there are multiple occurrences of the same code.
Maybe it will be a bit more clear when I show what I tried:
a[href*="123456"] > div.pseudo > div.photos-wrapper[id^="detailPhoto"] {
display: none !important;
}
div.photos-wrapper[id^="detailPhoto"] < div.pseudo < a[href*="123456"] {
display: none !important;
}
That's the way I tried to do so but it obviously is not working. The thing I am probably trying to do here is called a parent selector but I'm not quite sure.
@edit Let's take a look on this code, it's actually more detailed: http://jsfiddle.net/60ezqtL7/
The goal is to hide by display: none;
style whole divs that are containing exactly the same values i.e. <a href="#/000000/">PHOTO 1</a>