Quote:
Originally Posted by AlanHK
But what does omitting the comma do?
|
Think of it as a descendant selector.
will match all img tags that are inside of p tags that are inside of div tags. Although the p could be inside of something else that's inside the div, likewise for the img; it's a descendant selector meaning the p could be a child, grandchild, great grandchild, etc. For immediate descendant (child) you'd use >;
Code:
div > p > img { ... }