pr- pr- - 1 year ago 97
CSS Question

Input box for changing IP Address

I am trying to create an input field for an IP address, broadcast, and subnet. The inputs are used to change the ip of the server. Its an internal website.

I want to make it so that the user gets an input box that has the periods hardcoded into the text box. This way when they start typing, they only have to input the numbers and be able to tab to the next part of the ip. Or if the user enters 3 characters, it automatically sends him to the next part of the ip.

I don't know if this is something that can only be done with html and css or if this is more of a javascript application.


Answer Source

You can use a mask plugin - DEMO

   $("input").mask("9?99.9?99.9?99.9?99", {placeholder:" "});
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download