New Component: InputPhone

Community Driven Extensions Project
Post Reply
User avatar
Melloware
Posts: 1301
Joined: 22 Apr 2013, 15:48

27 Feb 2019, 15:40

Available in PFE 7.0. Input for entering and validating international telephone numbers. It adds a flag dropdown to any input, detects the user's country, displays a relevant placeholder and provides formatting/validation methods.

Based on: https://github.com/jackocnr/intl-tel-input

usage:

Code: Select all

    
<pe:inputPhone id="txtPhone" 
                   initialCountry="us"
                   value="#{basicInputPhoneController.phoneNumber}"
                   formatOnDisplay="true">
        <p:ajax event="countrySelect" listener="#{basicInputPhoneController.onCountrySelect}"/>
</pe:inputPhone>
PrimeFaces Developer | PrimeFaces Extensions Developer
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 7.0.6 / PF Extensions 7.0.2

djmj
Posts: 388
Joined: 16 Dec 2011, 01:23

09 Sep 2019, 01:48

Thanks for the great control and its very usefull in many projects.

But there is a small bug in the showcase:

When i select germany as a country and input a number and submit the form the submitted value is correct (as shown in message).
But then the US flag is selected automatically?
Primefaces: 6.2
Primefaces-Extension: 6.2.2
OmniFaces: 3.0
Jsf: Mojarra 2.3.2
Server: Glassfish 5.0.0

User avatar
Melloware
Posts: 1301
Joined: 22 Apr 2013, 15:48

09 Sep 2019, 13:16

Can you please report that issue here: https://github.com/primefaces-extension ... com/issues
PrimeFaces Developer | PrimeFaces Extensions Developer
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 7.0.6 / PF Extensions 7.0.2

Post Reply

Return to “Extensions”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 1 guest