Fixed minor cross browser compatibility issues.