/^\\d{1,2}[:][0-5][0-9]$/
is what I have. this limits minutes to 00-59. It does not, however, limit hours to between 0 and 12. For similarity and unifo
Thanks!!! I use this Javascript code now:
function Check_arrival(time) { //Assuming you are working in 12 hour time, 0 is not a valid var patt = new RegExp("^(0?[1-9]|1[012]):[0-5][0-9]$"); var res = patt.test(time); return res; }
res=true|false