CSS相邻选择器

CSS相邻选择器

by Wang Peng

HTML

<div>
    <p>I live in Duckburg.</p>
</div>
<p>My best friend is Mickey.</p>
<p>I will not be styled.</p>

CSS

div + p {
    color: red;
}