Update v1.0.6

This commit is contained in:
Bhanu Slathia
2016-02-16 23:24:52 +05:30
parent c710c20b9e
commit b1f62846ab
7662 changed files with 1361647 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
<?php
use Illuminate\Support\Facades\App;
use libphonenumber\PhoneNumberFormat;
if (!function_exists('phone_format')) {
/**
* Formats a phone number and country for display.
*
* @param string $phone
* @param string $country
* @param int|null $format
* @return string
*/
function phone_format($phone, $country, $format = PhoneNumberFormat::INTERNATIONAL)
{
$lib = App::make('libphonenumber');
$phoneNumber = $lib->parse($phone, $country);
return $lib->format($phoneNumber, $format);
}
}