I am new to javascript regular expressions.Any-way i want to valiadate a string that matches some conditions
Here are the conditions
1.String contains only 9 characters
2.First two letters must be alphabets.
3.third letter must be '-' this.
4.Remaining 6 letters must be digits
function validateInput(str){
if(str.length>9){
alert("Exeeds maximum limit");
}
}
How can i do the rest of the validations using regex?