- 授权协议: MIT
- 开发语言: PHP
- 操作系统: 跨平台
- 软件首页: https://github.com/toohamster/ws-http
- 软件文档: http://my.oschina.net/vb2005xu/blog/724044
软件介绍
ws-http:简单轻量的HTTP 客户端工具库。
可用于 HTTP API 测试,支持 ssl,basic auth,代理,自定义请求头,以及常用HTTP 请求方法。
$httpRequest = \Ws\Http\Request::create();
$httpResponse = $httpRequest->get("https://api.github.com");
$watcher = \Ws\Http\Watcher::create($httpResponse);
$watcher
->assertStatusCode(200)
->assertHeadersExist(array(
"X-GitHub-Request-Id",
"ETag"
))
->assertHeaders(array(
"Server" => "GitHub.com"
))
->assertBody('IS_VALID_JSON')
->assertTotalTimeLessThan(2);
$httpRequest = \Ws\Http\Request::create();
$httpResponse = $httpRequest->get("https://freegeoip.net/json/8.8.8.8");
$watcher = \Ws\Http\Watcher::create($httpResponse);
$watcher
->assertStatusCode(200)
->assertHeadersExist(array(
"Content-Length"
))
->assertHeaders(array(
"Access-Control-Allow-Origin" => "*"
))
->assertBodyJsonFile(dirname(__DIR__) . "/tests/Ws/Http/_json/freegeoip.net.json");
查看所有例子: https://github.com/toohamster/ws-http/blob/master/tests/Ws/Http/ATest.php.
要求:
-
PHP:版本 5.4.40 以上
-
PHP Extensions:Curl
Linux程序设计
Neil Matthew、Richard Stones / 陈健、宋健建 / 人民邮电出版社 / 201005 / 99.00元
时至今日,Linux系统已经从一个个人作品发展为可以用于各种关键任务的成熟、高效和稳定的操作系统,因为具备跨平台、开源、支持众多应用软件和网络协议等优点,它得到了各大主流软硬件厂商的支持,也成为广大程序设计人员理想的开发平台。 本书是Linux程序设计领域的经典名著,以简单易懂、内容全面和示例丰富而受到广泛好评。中文版前两版出版后,在国内的Linux爱好者和程序员中也引起了强烈反响,这一热潮......一起来看看 《Linux程序设计》 这本书的介绍吧!
