Download the PHP package khakimjanovich/uz-phone without Composer

On this page you can find all versions of the php package khakimjanovich/uz-phone. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package uz-phone

uz-phone

Latest Version PHP Version Tests

Strict Uzbek phone parsing for PHP. UzPhoneNumber wraps brick/phonenumber internally, adds Uzbekistan prefix data, and exposes a small Brick-style object API without leaking Brick classes.

Why

Most apps only need one thing from Uzbek phone input: parse it into a canonical object, identify its prefix type, and then decide what their own domain should accept. uz-phone keeps that surface small, strict, and framework-agnostic.

Installation

Requires PHP 8.2 or newer.

Usage

Prefix Data

Prefix data reflects original numbering allocation, not a guaranteed current operator or location after number portability. Geographic PSTN prefixes return null from getOperator() because the ITU table names the region, not a specific operator.

Supported Input

All accepted input normalizes to +998901234567.

The parser is intentionally strict. It accepts digits, a leading +, spaces, parentheses, and hyphens. It rejects unknown prefixes, wrong country codes, unsupported separators, letters, overlong numbers, and incomplete numbers.

Uzbek Prefixes

Source: ITU Uzbekistan numbering plan update.

Prefix Type Operator
20 MOBILE_GSM OQ_BEELINE
33 MOBILE_GSM HUMANS
36 FIXED_NETWORK_SERVICE_PROVIDER BUZTON
50 MOBILE_GSM UCELL_COSCOM
55 SIP UZTELECOM
61 GEOGRAPHIC_PSTN
62 GEOGRAPHIC_PSTN
65 GEOGRAPHIC_PSTN
66 GEOGRAPHIC_PSTN
67 GEOGRAPHIC_PSTN
69 GEOGRAPHIC_PSTN
70 GEOGRAPHIC_PSTN
71 GEOGRAPHIC_PSTN
72 GEOGRAPHIC_PSTN
73 GEOGRAPHIC_PSTN
74 GEOGRAPHIC_PSTN
75 GEOGRAPHIC_PSTN
76 GEOGRAPHIC_PSTN
77 MOBILE_GSM UZMOBILE_GSM
78 FIXED_NETWORK_SERVICE_PROVIDER
79 GEOGRAPHIC_PSTN
80 MOBILE_GSM PERFECTUM_MOBILE
87 MOBILE_GSM MOBIUZ_UMS
88 MOBILE_GSM MOBIUZ_UMS
90 MOBILE_GSM BEELINE_UNITEL
91 MOBILE_GSM BEELINE_UNITEL
92 MOBILE_GSM BEELINE_UNITEL
93 MOBILE_GSM UCELL_COSCOM
94 MOBILE_GSM UCELL_COSCOM
95 MOBILE_CDMA_GSM UZMOBILE_CDMA
97 MOBILE_GSM MOBIUZ_UMS
98 MOBILE_CDMA PERFECTUM_MOBILE
99 MOBILE_GSM

API

parse() throws ParseException when the input is not a valid Uzbek phone number. The exception exposes ParseErrorType through $exception->error_type.

UzPhoneNumber methods:

Parse error types:

Testing

License

MIT.


All versions of uz-phone with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
brick/phonenumber Version ^0.8
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package khakimjanovich/uz-phone contains the following files

Loading the files please wait ...