10-06-a
The above are the only characters i want the user to enter, as in 2 numeric characters, a hyphen, 2 more numeric characters, a hyphen and a letter.
I managed to do the following
$valid_month = preg_match('/^[0-90-9]+\-\[0-90-9]+\-\[a-z]$/', $_POST['month_id']);
is that correct so far?