I want to make input text box in primefaces which only can take mobile number with country code. The format is +NN-NNNNNNNNNN, e.g., +91-9876123456. User could not type any other characters except the mentioned. I've tried with some Javascript, but the result did not satisfy me. By, How to disable special characters and alphabets in Primefaces input text?
In this question, they have mentioned all the thing is perfect, but delete and movement of cursor is not happened here.
Moreover I do not want to use inputMask, behavior of this component is not exact with the text, although you have any better suggestion with this component then kindly provide.