获取子元素

1、纯css  获取子元素 #test1>div {background-color:red;} #test1 div {font-size:14px;} #test1>div:first-child {color:#ccc;} <div id="test1"> <div>性别</div><div>男</div> </div> 因1示例中为#test1下的子元素 #test1>div 余#test
相关文章
相关标签/搜索