315920-3c.html (495B)
1 <!DOCTYPE html> 2 <html> 3 <head> 4 <style> 5 input {color: red} 6 #two { color: green } 7 input[disabled]:not(:enabled) {color: green} 8 input:not([disabled]):enabled + #two:enabled {color: red} 9 </style> 10 </head> 11 <body onload='var elem = document.getElementById("one"); 12 elem.setAttribute("disabled", "disabled");'> 13 <input type="button" id="one" value="Should be no red"/> 14 <input type="button" id="two" value="Should be no red"/> 15 </body> 16 </html>