Example #1
0
 public static function GetPhoneCountryStates($country, $type = self::PHONE_TYPE_FIXED)
 {
     $arResult = array();
     if (!in_array($type, array(self::PHONE_TYPE_FIXED, self::PHONE_TYPE_TOLLFREE, self::PHONE_TYPE_TOLLFREE804, self::PHONE_TYPE_MOBILE, self::PHONE_TYPE_MOSCOW495))) {
         return $arResult;
     }
     $viHttp = new CVoxImplantHttp();
     $result = $viHttp->GetPhoneNumberCountryStates($type, $country);
     if ($result && !empty($result->result)) {
         foreach ($result->result as $value) {
             $arResult[$value->country_state] = $value->country_state_name;
         }
     }
     return $arResult;
 }