【文件属性】:
文件名称:woothee-php:Woothee PHP实现
文件大小:42KB
文件格式:ZIP
更新时间:2021-03-02 02:04:14
PHP
Woothee PHP
Project WootheePHP实现,它是多语言的用户代理字符串解析器。
这个项目几乎是从移植的
安装
使用安装此库。
在项目目录中的以下命令中运行。
$ composer require woothee/woothee
或将此库手动添加到composer.json的require部分中。
{
" require " : {
" woothee/woothee " : " * "
}
}
用法
解析用户代理
<?php
$ classifier = new \ Woothee \ Classifier ;
$ r = $ classifier -> parse ( 'user agent string' );
$ r [ 'name' ];
// => name of browser (or string like name of us
【文件预览】:
woothee-php-master
----composer.json(696B)
----.travis.yml(468B)
----.php_cs.dist(2KB)
----.gitmodules(80B)
----phpunit.xml(800B)
----Guardfile(202B)
----tests()
--------bootstrap.php(72B)
--------Woothee()
--------polyfill.php(226B)
----Gemfile(52B)
----src()
--------Classifier.php(6KB)
--------AgentCategory()
--------DataSet.php(20KB)
----.phan()
--------config.php(15KB)
----.coveralls.yml(39B)
----.gitignore(153B)
----phpstan.neon.dist(102B)
----Makefile(3KB)
----README.md(2KB)
----scripts()
--------.php-cs-fixer()
--------generate_dataset_class.php(3KB)
--------.phan()
--------.phpstan()
--------setup-composer(512B)
----woothee()