Download the PHP package jasmine/id-card-of-china without Composer
On this page you can find all versions of the php package jasmine/id-card-of-china. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download jasmine/id-card-of-china
More information about jasmine/id-card-of-china
Files in jasmine/id-card-of-china
Download jasmine/id-card-of-china
More information about jasmine/id-card-of-china
Files in jasmine/id-card-of-china
Vendor jasmine
Package id-card-of-china
Short Description 中华人民共和国身份证(The identity card of the people's Republic of China)
License MIT
Package id-card-of-china
Short Description 中华人民共和国身份证(The identity card of the people's Republic of China)
License MIT
Please rate this library. Is it a good library?
Informations about the package id-card-of-china
Identity Card Of China (PHP)
中华人民共和国身份证(The identity card of the people's Republic of China)
id-card-of-china
是一个基于「公民身份号码」规则获取公民身份号码中包含的基础信息组件。
安装
- 你的 PHP 版本应该
>= 7.0
我们使用 Composer 安装:
使用
遵循 PHP-MD 原则,这个工具不提供静态调用,所以使用需要进行对象实例化:
APIs
基于
jasmine2\IdentityCard\China\IdentityInterface
实例
legal
:检查公民身份号码是否合法birthday
:获取公民身份号码中包含的生日信息gender
:获取身份证包含的性别信息region
: 获取身份证包含的地区信息,返回jasmine2\IdentityCard\China\Region\RegionInterface
实例
region
对象 APIs
code
: 获取 GB/T 2260 的地区行政代码province
:获取省份名称或者直辖市名称city
:获取城市名称,如果是直辖市则返回''
county
:获取区县名称tree
:获取地区层级数组treeString
:获取地区完整字符串,支持传递一个参数作为省市区的分隔符
演示
致谢
该扩展对上面扩展使用的数据字典做了完善, 增加了行政区划变更前的数据.
LICENSE
This component follows the MIT open source agreement.
All versions of id-card-of-china with dependencies
PHP Build Version
Package Version
No informations.
The package jasmine/id-card-of-china contains the following files
Loading the files please wait ....