0

I have an html element that can have either a child with id='slideshow'

<div id='content'>
   <div id='slideshow'>
   </div>
</div>

or a different child

<div id='content'>
   <div id='other'>
   </div>
</div>

I want to apply a style to #content only if it has a child #slideshow.

Is it possible?

Maurizio Pozzobon
  • 2,804
  • 7
  • 32
  • 42

1 Answers1

0

Unfortunately this is not (yet?) possible in CSS alone. You can however do it with a couple of lines in jquery or almost any other javascript framework.

Simone Gianni
  • 10,588
  • 36
  • 45