I am looking for a selector which applies to any div element that contains an element identified by the p.my selector
<div>
 <p class="my">
  prova
 </p>
</div>
I am looking for a selector which applies to any div element that contains an element identified by the p.my selector
<div>
 <p class="my">
  prova
 </p>
</div>
 
    
    No, there is no specific parent selector in CSS, but I know two other ways:
<div> a class or id.$('p.my').parent().css({/*some css*/});