Corrected some cross browser compatibility issues.