Added non-safari compatibility.