Validate a date using a regular expression(RegExp)