//Well, though this is a repeated question,
//just to quench yo thirst, you can use javascript's RegExp for regular expressions.
//you can create one like:
var RegularExpression = new RegExp("pattern");
//or
var RegularExpression2 = /pattern/;
//check for valid date format as:
var datePattern = /^\w{3}[-]\d{4}$/
//for numerical month value, u could use
//var datePattern = /^\d{1,2}[-]\d{4}$/
if(datePattern.test('my_date_string'))
alert('correct')
else
alert('false')
//or in a jquery way, if your date-holding element is an input with id as dateId
//then you can do:
if(datePattern.test($('#dateId').val()))
alert('correct')
else
alert('false')