blob: 671ee285df3c894363cfd256a96aa8a670915288 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
<html>
<head>
<title>:only-child test</title>
<style>
div:only-child {
color: red;
}
div {
display: inline-block;
margin: 6px;
border-width: 1px;
}
</style>
</head>
<body>
<div>
<div>I am an only child.</div>
</div>
<div>
<div>I am the 1st sibling.</div>
<div>I am the 2nd sibling.</div>
<div>I am the 3rd sibling, <div>but this is an only child.</div></div>
</div>
</body>
</html>
|