A regular expression that matches the various names of the days of the week. This could be useful in checking if the user inputs a valid Day Of the Week.
/\b(?:Tue(?:sday)?|Wed(?:nesday)?|Thu(?:rsday)?|Sat(?:urday)?|(Mon|Fri|Sun)(?:day)?)/gi
Matches:
- Tue
- Tuesday
- tuesday
Non-matches:
- Tu
- Tues
- May
See Also:
- Regular Expression For Year
- Month Regular Expression
- Regex To Match ISO 8601 Dates and Times
- Date (YYYY-MM-DD) Regular Expression
- Regular Expression To Match Month Name