Hey,
I was just writing some html & css for a site today and I came across what, well, I thought was a problem but perhaps I'm just not doing it right.
So in css, I can style a class like this:
but can I do it something more like this:
Basically I'm just trying to target anything with the .special class that is in a <p> tag.
I always thought you could, but I guess I was wrong, and I just had never done it, as I'm writing in Coda and it really doesn't seem to be doing anything.
Can somebody fill me in on how this can be done?
Cheers.
I was just writing some html & css for a site today and I came across what, well, I thought was a problem but perhaps I'm just not doing it right.
So in css, I can style a class like this:
Code:
ul a {...}
#mylist a {...}
.special .link {...}
but can I do it something more like this:
Code:
p .special {...}
Basically I'm just trying to target anything with the .special class that is in a <p> tag.
I always thought you could, but I guess I was wrong, and I just had never done it, as I'm writing in Coda and it really doesn't seem to be doing anything.
Can somebody fill me in on how this can be done?
Cheers.