Trying looking at the onchange() event for the input field. With the onchange, you can check each change to the field and validate if there are 2 characters in the field, then print the colon, 4 characters, print another colon.
For a valid time, you could create another function that parses...