The original format is embedded in the country_code_source field of the PhoneNumber object
passed in. If such information is missing, the number will be formatted into the NATIONAL
format by default. When the number contains a leading zero and this is unexpected for this
country, or we don't have a formatting pattern for the number, the method returns the raw input
when it is available.
Note this method guarantees no digit will be inserted, removed or modified as a result of
formatting.
public formatInOriginalFormat ( |
||
$number | the phone number that needs to be formatted in its original number format | |
$regionCallingFrom | string | the region whose IDD needs to be prefixed if the original number has one |
return | string | the formatted phone number in its original number format |