https://github.com/mozilla/gecko-dev
Raw File
Tip revision: 34a1b4131d013e9f9417f947e92a83992679e0cf authored by ffxbld on 06 January 2015, 04:54:46 UTC
Added FIREFOX_31_4_0esr_RELEASE FIREFOX_31_4_0esr_BUILD1 tag(s) for changeset 60d7a6f78402. DONTBUILD CLOSED TREE a=release
Tip revision: 34a1b41
348809-2h.html
<!DOCTYPE html>
<html>
<head>
<style>
span { color: green }
:default + span { color: red }
span.reverse { color: red }
:default + span.reverse { color: green }
input { display: none }
</style>
</head>
<body>
<form>
<div>
  <input type="radio" checked="checked" id="foo">
  <span>There should be no red.</span>
</div>
<div>
  <input checked="checked" id="bar">
  <span class="reverse">There should be no red.</span>
</div>
</form>
<script>
  var foo = document.body.offsetWidth;
  document.getElementById("foo").removeAttribute("type");
  document.getElementById("bar").setAttribute("type", "radio");
</script>
</body>
</html>
back to top