Bitrix API

Phone

Class Phone

Table of Contents

Methods

extractNumbers()  : array<string|int, mixed>
getArrayUniqueValidate()  : array<string|int, mixed>
isInArray()  : bool
isSame()  : bool
normalize()  : string|null
Normalize phone number.
parseText()  : array<string|int, mixed>
validate()  : bool
Validate phone number.

Methods

extractNumbers()

public static extractNumbers(mixed $text) : array<string|int, mixed>
Parameters
$text : mixed
Return values
array<string|int, mixed>

getArrayUniqueValidate()

public static getArrayUniqueValidate(mixed $phones) : array<string|int, mixed>
Parameters
$phones : mixed
Return values
array<string|int, mixed>

isInArray()

public static isInArray(mixed $phones, mixed $searchPhone) : bool
Parameters
$phones : mixed
$searchPhone : mixed
Return values
bool

isSame()

public static isSame(mixed $phone1, mixed $phone2) : bool
Parameters
$phone1 : mixed
$phone2 : mixed
Return values
bool

normalize()

Normalize phone number.

public static normalize(string $phone) : string|null
Parameters
$phone : string

Phone number.

Return values
string|null

parseText()

public static parseText(mixed $text) : array<string|int, mixed>
Parameters
$text : mixed
Return values
array<string|int, mixed>

validate()

Validate phone number.

public static validate(string $phone) : bool
Parameters
$phone : string

Phone number.

Return values
bool

        
On this page

Search results