【phpstudy2016】apache配置Tp5.0,获取表单数据老是多了一个路由变量,解决

一、用的apahce配置tp5.0的php环境php

二、发现input()过来的数据,老是多了一个变量,那就是路由变量,html

相似【array(2) { ["/index/index/form_submit_html"]=> string(0) "" ["username"]=> string(6) "sakura" }????????   多了/index/index/form_submit_html这个参数,,,】spa

三、解决:把项目根路径下的 .htaccess文件中的 RewriteRule ^(.)$ index.php?/$1 [QSA,PT,L] 改为 RewriteRule ^(.*)$ index.php [L,E=PATH_INFO:$1]orm

相关文章
相关标签/搜索