|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Simple CSS selectors question.
Ok I have these CSS classes which I only want to be applied if the occur within an element already assigned a class i.e.
<div class="toplevel"> <div class="intop1">Stuff</div> <div class="intop2">Stuff</div> </div> Now how I expected it to be formated in my CSS is probably not right, here's how I put it at the moment: .toplevel { } .toplevel.intop1 {} .toplevel.intop2 {} But I discovered if I have something else with one of the intop classes which is not within an element with toplevel class it still takes the intop settings. Any help would be greatly appreciated. -D |
|
#2
|
|||
|
|||
|
hi
try this: .toplevel {} .toplevel .intop1 {} .toplevel .intop2 {} you didn't put a space between the selectors ![]()
__________________
/delta |
|
#3
|
|||
|
|||
|
That seems to make no difference to me here.
-D |
![]() |
| Viewing: Dev Shed Forums > Web Design > CSS Help > Simple CSS selectors question. |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|