PHP $_SERVER['argv' ] 出现notice
程序员文章站
2024-02-02 17:05:55
...
php $_SERVER[argv] http://localhost/demo/demo.php?a=123&b=132
输出出现:
Notice: Undefined index: args in F:\php\www\demo\demo.php on line 35
这是怎么回事呀,请明白人指点
输出出现:
Notice: Undefined index: args in F:\php\www\demo\demo.php on line 35
这是怎么回事呀,请明白人指点
回复讨论(解决方案)
$_SERVER['argv'] 用于 cli 方式下获取命令行参数
$_GET 才是用于获取 url 参数的
嗯,谢谢了,刚刚查到一个
http://*.com/questions/9270030/serverargv-with-http-get-and-cli-issue
有点明白了,英语不中
推荐阅读
-
php出现Notice : Use of undefined constant 的解决方法
-
PHP $_SERVER['argv' ] 出现notice解决思路
-
PHP运行出现Notice : Use of undefined constant 的完美解决方案分享_PHP教程
-
Windows server 2003 IIS6.0 搭在PHP 经常出现空白页
-
PHP运行出现Notice : Use of undefined constant 的完美解决方案_PHP
-
PHP中出现Notice: Undefined index的三种解决方法
-
linux下配置lamp时候出现The requested URL /info.php was not found on this server问题
-
PHP运行出现Notice : Use of undefined constant 的解决方法
-
linux下配置lamp时候出现The requested URL /info.php was not found on this server问题
-
PHP运行出现Notice : Use of undefined constant 的完美解决方案_PHP