Fixed date validation bug for Firefox/IE