I need to be able to allow dates in the format MM/DD/YYYY where the leading month and day can have a leading zero or not where appropriate
In other words: 01-09 or 1-9 are acceptable months 01-09 or 1-9 are acceptable days
I am very close with this:
With my limited knowledge I thought doing this would allow for a leading zero (or not)
But that allows for dates such as 13/31/2008, for reasons I can't explain.
Question: I need a regular expression that allows all possible dates in the format MM/DD/YYYY where the month or day can contain leading zeros (or not) where both will pass.
I am working with a 3rd party system that fails downstream if a users input is not a real date. The only tool I have against the input is Regex check. (For those that down voted my question)