【发布时间】:2014-09-01 05:48:38
【问题描述】:
我知道这很简单,但我想不通,如果我用 telnet 发出这样的请求:
machine:~ user$ telnet localhost 80
Trying ::1...
Connected to localhost.
Escape character is '^]'.
POST / HTTP/1.1
Host: localhost
Content-Length: 7
vari=e3
HTTP/1.1 200 OK
Date: Thu, 10 Jul 2014 18:06:33 GMT
Server: Apache/2.2.26 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.6 PHP/5.5.10 mod_ssl/2.2.26 OpenSSL/0.9.8y DAV/2 mod_perl/2.0.8 Perl/v5.18.2
X-Powered-By: PHP/5.5.10
Content-Length: 7
Content-Type: text/html
VARI =
没有设置 vari 变量...响应应该有 VARI = e3 因为我有一个输出它的 PHP 行:
echo "VARI = ".$_POST['vari'];
exit;
但是变量没有出现。我错过了什么吗?
【问题讨论】: