Function __global->mask_phone_number
Definitions
sources/crypt.php
- Replace all but the last 3 digits in a phone number with the @ symbol.Since phone numbers can be saved in a wide variety of formats depending on the country, it can be difficult to mask phone numbers.
- Visibility: public
- Is abstract?: No
- Is static?: No
- Is final?: No
- Returns: string
Parameters
| Name | Type | Passed by reference? | Variadic? | Default | Set | Range | Description |
|---|---|---|---|---|---|---|---|
| $phone_number | SHORT_TEXT | No | No | required parameter | N/A | N/A | The phone number to mask |
Returns
- The masked phone number
- Type: SHORT_TEXT
- Set: N/A
- Range: N/A
Preview
Code (PHP)
/**
* Replace all but the last 3 digits in a phone number with the @ symbol.Since phone numbers can be saved in a wide variety of formats depending on the country, it can be difficult to mask phone numbers.
*
* @param SHORT_TEXT $phone_number The phone number to mask
* @return SHORT_TEXT The masked phone number
*/
function mask_phone_number(string $phone_number) : string
* Replace all but the last 3 digits in a phone number with the @ symbol.Since phone numbers can be saved in a wide variety of formats depending on the country, it can be difficult to mask phone numbers.
*
* @param SHORT_TEXT $phone_number The phone number to mask
* @return SHORT_TEXT The masked phone number
*/
function mask_phone_number(string $phone_number) : string

