Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/255.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 使用htaccess在我的域末尾添加斜杠_Php_.htaccess_Redirect - Fatal编程技术网

Php 使用htaccess在我的域末尾添加斜杠

Php 使用htaccess在我的域末尾添加斜杠,php,.htaccess,redirect,Php,.htaccess,Redirect,我的名字是 我想使用.htaccess在域的末尾添加斜杠。它应该是这样的 提前感谢下次请使用谷歌,不要这么快问 答复来源: 在.htaccess中: RewriteCond %{REQUEST_URI} !\.(php|html?|jpg|gif)$ RewriteRule ^(.*)([^/])$ http://%{HTTP_HOST}/$1$2/ [L,R=301]

我的名字是

我想使用.htaccess在域的末尾添加斜杠。它应该是这样的


提前感谢

下次请使用谷歌,不要这么快问

答复来源:

在.htaccess中:

RewriteCond %{REQUEST_URI}  !\.(php|html?|jpg|gif)$
RewriteRule ^(.*)([^/])$ http://%{HTTP_HOST}/$1$2/ [L,R=301]