【文件属性】:
文件名称:units-api:计量单位转换 API
文件大小:14KB
文件格式:ZIP
更新时间:2021-07-03 10:12:29
api php conversion units measurement
单位 API
度量单位转换 API,基于所做的工作,虽然与 Drupal 分离并可用作托管服务和 PHP 库。
用作托管服务:
转换请求:
GET http://host/convert.php?value=5&from=km&to=miles
回复:
{
" from " : {
" value " : " 5 " ,
" unit " : {
" singular " : " kilometer " ,
" plural " : " kilometers " ,
" symbol " : " km "
}
},
" to " : {
" value " : " 3.107 " ,
" unit " : {
" singular " : " mile " ,
" pl
【文件预览】:
units-api-master
----src()
--------unitsapi.php(4KB)
--------units.json(19KB)
--------convert.php(410B)
----LICENSE(18KB)
----README.md(1007B)
----tests()
--------convertTest.php(2KB)
--------unitsapiTest.php(2KB)
----.editorconfig(208B)