Download the PHP package hanhan/address-parser without Composer
On this page you can find all versions of the php package hanhan/address-parser. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package address-parser
hanhan/address-parser
中文地址解析 PHP 库,支持省/市/区/乡镇识别与口岸等标志地区识别。
核心能力包括:
- 省/市/区识别
- 口岸等标志地区优先识别
- 直辖市
city回填(避免空值) - 乡镇分片加载(对应 JS 的异步分片策略)
- 口岸歧义处理(
口岸不误匹配口岸街道)
安装
快速使用
外部扩展口岸
API
parse(string $rawAddress, array $options = []): array- 同步基础解析,不自动加载乡镇分片
parseWithChunkTownships(string $rawAddress, array $options = []): array- 先基础解析,再按省份加载
data/region/townships/*.json做二次解析
- 先基础解析,再按省份加载
$options 支持:
divisionTree:自定义省市区树landmarks:追加/覆盖标志地区(按name去重,后者覆盖前者)townships:额外乡镇数据
All versions of address-parser with dependencies
PHP Build Version
Package Version
Requires
php Version
>=8.0
ext-mbstring Version *
ext-json Version *
ext-mbstring Version *
ext-json Version *
The package hanhan/address-parser contains the following files
Loading the files please wait ...