Why is z-index ignored with position:static?

Because position: static means “Ignore all the positioning instructions from left, top, z-index, etc.”. ‘z-index’ Value: auto | <integer> | inherit Initial: auto Applies to: positioned elements — http://www.w3.org/TR/CSS21/visuren.html#z-index An element is said to be positioned if its ‘position’ property has a value other than ‘static’. — http://www.w3.org/TR/CSS21/visuren.html#positioned-element

How can I style a file input field in Firefox?

Many of the answers above are quite old. In 2013 a much simpler solution exists: nearly all current browsers… Chrome IE Safari Firefox with a few-line fix pass through click events from labels. Try it here: http://jsfiddle.net/rvCBX/7/ Style the <label> however you you would like your file upload to be. Set for=”someid” attribute on the … Read more

How do you detect when CSS animations start and end with JavaScript?

Bind the appropriate events to the element, e.g. el.addEventListener(“animationstart”, function() {}, false); el.addEventListener(“animationend”, function() {}, false); el.addEventListener(“animationiteration”, function() {}, false); https://developer.mozilla.org/en-US/docs/CSS/Tutorials/Using_CSS_animations#Using_animation_events Note: You may need to add the appropriate prefixed-events as well, e.g. webkitAnimationEnd

IE7 relative/absolute positioning bug with dynamically modified page content

This is related to the “hasLayout bug” of IE. The relatively positioned #panel parent doesn’t have layout and hence IE forgets to redraw its children when it get resized/repositioned. The problem will go if you add overflow: hidden; to the relatively positioned #panel parent. #panel { position: relative; overflow: hidden; border: solid 1px black; } … Read more