Difference between revisions of "Phone Numbers"

From WHMCS Documentation

Line 1: Line 1:
WHMCS 7.4 introduced a new way of entering and storing phone numbers.
+
In WHMCS 7.4 and later, you can easily enter and store international phone numbers.
  
 
[[File:PhoneNumberInputUx.png]]
 
[[File:PhoneNumberInputUx.png]]
  
This new input field experience has been designed to simplify the process of entering international phone numbers and make it clearer and easier for users to know how to indicate the country a phone number is located in.
+
This system ensures a consistent and uniform phone number format combining the country prefix and phone number:
 
 
Using a combination of the country prefix and phone number entered, the phone number will be stored in a consistent and uniform format as follows:
 
  
 
  + '''[Country Code]''' . '''[Phone Number]'''
 
  + '''[Country Code]''' . '''[Phone Number]'''
  
 
==Configuration==
 
==Configuration==
This feature is enabled by default. However it can be disabled if required by unchecking '''Phone Numbers''' in '''Configuration (<i class="fa fa-wrench" aria-hidden="true"></i>) > System Settings > General Settings > Localisation''' or, prior to WHMCS 8.0, '''Setup > General Settings > Localisation'''.
 
  
When enabled, the client's phone number saved in the database will automatically be prefixed by the international country dialling code. When disabled, this will not be added automatically to the database value, but will still be reflected in the UI.
+
In WHMCS 7.4 and later, this feature is enabled by default. The system will save the client's phone number in the database and automatically prefix it with the international country dialing code.
 +
 
 +
To disable this, uncheck '''Phone Numbers''' in the '''[[Localisation Tab|Localisation]]''' tab at '''Configuration (<i class="fa fa-wrench" aria-hidden="true"></i>) > System Settings > General Settings''' or, prior to WHMCS 8.0, '''Setup > General Settings'''. When you disable this feature, the system will not add the prefix in the database but will display it in the Admin Area and Client Area.
  
 
==Automatic Number Formatting==
 
==Automatic Number Formatting==
  
The pre-selected country will default to your WHMCS system default country. The selected country will be automatically updated upon change of the physical address country while-ever the phone number field remains empty.
+
The pre-selected country will default to your WHMCS system default country. The system will update the selected country whenever you change the client's physical address. This change will occur even if the phone number is currently empty.
  
Users can also begin typing a phone number that begins with a country code in the format "+XX" and upon a valid country code being detected, the selected country will be automatically updated.
+
Users can also begin typing a phone number that begins with a country code in the format <tt>+XX</tt> and the system will update the country.
  
Any phone numbers entered into WHMCS prior to the automatic phone number formatting feature will be converted automatically on display within a phone number field. The value stored in the database will not be updated however until the first time the phone number is saved.
+
The update process will automatically convert existing client phone numbers when they display in a phone number field. The phone number value will update in the database the first time that an admin or client saves the phone number.
  
 
==Order Forms==
 
==Order Forms==
  
The screenshot below demonstrates how the phone number input experience is presented within the default Standard Cart order form.
+
For example:
  
 
[[File:PhoneNumberOrderForm.png]]
 
[[File:PhoneNumberOrderForm.png]]

Revision as of 20:44, 27 April 2022

In WHMCS 7.4 and later, you can easily enter and store international phone numbers.

PhoneNumberInputUx.png

This system ensures a consistent and uniform phone number format combining the country prefix and phone number:

+ [Country Code] . [Phone Number]

Configuration

In WHMCS 7.4 and later, this feature is enabled by default. The system will save the client's phone number in the database and automatically prefix it with the international country dialing code.

To disable this, uncheck Phone Numbers in the Localisation tab at Configuration () > System Settings > General Settings or, prior to WHMCS 8.0, Setup > General Settings. When you disable this feature, the system will not add the prefix in the database but will display it in the Admin Area and Client Area.

Automatic Number Formatting

The pre-selected country will default to your WHMCS system default country. The system will update the selected country whenever you change the client's physical address. This change will occur even if the phone number is currently empty.

Users can also begin typing a phone number that begins with a country code in the format +XX and the system will update the country.

The update process will automatically convert existing client phone numbers when they display in a phone number field. The phone number value will update in the database the first time that an admin or client saves the phone number.

Order Forms

For example:

PhoneNumberOrderForm.png