感谢您抽出宝贵时间帮助我!
我正在尝试设置姐妹 div 的样式,但不使用此 ID #rooms-booking-manager-change-search-form
例子
div + #rooms-booking-manager-change-search-form {
padding:10px;
font-size:18px;
}
<div>Arrival Date: 19/09/2013</div>
<div>Departure Date: 21/09/2013</div>
<div>Nights: 2</div>
<form id="rooms-booking-manager-change-search-form"></form>
解决方案:
div ~ #rooms-booking-manager-change-search-form {
background: red;
}