I’m trying to create regex for the following validation:
- 5 to 15 characters
- only letters and numbers allowed
- no numbers at the beginning or the end
/^[A-Za-z][A-Za-z0-9]([A-Za-z0-9]+)$/
this for the 2nd & 3rd validation
so how can I add 5 to 15 characters validation to this regexp
I tried to write it like that but it doesn’t work
/^[A-Za-z][A-Za-z0-9]([A-Za-z0-9]+){5,15}$/