Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/taogogo/geohash-php-extention
A php extension for geohash conversion, it's writen in C Language, very fast to convert between geohash and coord.(一个转换经纬度和geohash的PHP扩展) - MIT License
https://github.com/taogogo/geohash-php-extention
Last synced: about 2 months ago
JSON representation
A php extension for geohash conversion, it's writen in C Language, very fast to convert between geohash and coord.(一个转换经纬度和geohash的PHP扩展) - MIT License
- Host: GitHub
- URL: https://github.com/taogogo/geohash-php-extention
- Owner: taogogo
- License: mit
- Created: 2014-01-13T13:42:34.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2022-03-10T02:12:55.000Z (almost 3 years ago)
- Last Synced: 2024-08-03T20:07:23.334Z (5 months ago)
- Language: C
- Homepage:
- Size: 7.81 KB
- Stars: 81
- Watchers: 13
- Forks: 29
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-php-extensions - geohash-php-extension - 经纬度和 geohash 转换 (地理)
README
geohash-php-extension
=====
## Introducegeohash is a php extension,it can convert between “longitude and latitude” and "geohash".
geohash是一个用于转换经纬度和geohash的php扩展。
相似的代码,使用扩展进行转换的速度比使用纯php代码快10倍以上。
## Install:
```shell
phpize
./configure
make
make install
echo "extension=geohash.so" >> /etc/php.ini```
## Example:
Geohash::decode(geohash string);
Geohash::encode(latitude,longtitude);
Geohash::encode(latitude,longtitude,precision=12);
```php
```
## output:```php
Array
(
[latitude] => 30.635780068114
[longitude] => 104.03160111979
)wm3yr31d2524
```
##contact
e-mail: love(a)taogogo.info##docs
google专利: http://www.google.fr/patents/US20130097163
维基百科: http://en.wikipedia.org/wiki/Geohash