哪位老大能帮着写一个apache rewrite的正则 我想把www.abc.com/index.php/ 301重定向至www.abc.com/请问在.htaccess中如何写查了半天,只把www.abc.com/index.php改成www.abc.com了而www.abc.com/index.php/改不了 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 这是我的代码,请问如何实现 www.abc.com/index.php/ 301重定向至www.abc.com/上RewriteCond %{THE_REQUEST} ^.*/index.php RewriteRule ^(.*)index.php$ http://www.abc.com/$1 [R=301,L] RewriteCond %{http_host} ^abc.com [NC] RewriteRule ^(.*)$ http://www.abc.com/$1 [R=301,NC] RewriteRule / index\.php [L] 试试这个?在我这里可以RewriteRule index\.php/? / [R=301] 完整的话这样应该可以了:RewriteCond %{HTTP_HOST} =www.abc.com [NC]RewriteRule index\.php/? / [R=301]不过不知道楼主这个匹配的目的是什么,index.php前面还有东西么?(.*)index.php closure老大,不瞒您说,我是在网上找了一个抄的,不懂啥意思,惭愧惭愧!我现在要实现www.abc.com/index.php 301 www.abc.com/www.abc.com/index.php 301 www.abc.com/abc.com/index.php 301 www.abc.com/abc.com 301 www.abc.com/以及所有index.php/的都要定向到www.abc.com,不知道这个完整的该怎么写向您学习了谢了 修改一下index.php/的都要定向到www.abc.com/ RewriteCond %{HTTP_HOST} =www.abc.com [NC]RewriteRule index\.php/? / [L,R=301]RewriteCond %{HTTP_HOST} =abc.com [NC]RewriteRule .* http://www.abc.com/$0 [L,R=301] PHP无法获得post数据 mysql_real_escape_string 发现一个乱码的中文字,见内 360度全景展示效果,如何搞这个? 武汉地区招聘 PHP开发工程师 请教php从业人员,我的一些入职困惑 高分求助——php中form页面的action,点击提交后,出现空白页面,在1台服务器正常,在另外一台服务器只出现空白 关于PHP表单中字符串的问题 再给分:怎样判断checkbox被选中了? 请各位高手session的用法,最好是举点例子 php 总是查询数据失败,到底哪里错了?? 请问一条关于MySQL的查询问题~望高手指导~感激不尽 关于用php抓取阿里巴巴的企业信息
www.abc.com/index.php/ 301重定向至www.abc.com/上RewriteCond %{THE_REQUEST} ^.*/index.php
RewriteRule ^(.*)index.php$ http://www.abc.com/$1 [R=301,L] RewriteCond %{http_host} ^abc.com [NC]
RewriteRule ^(.*)$ http://www.abc.com/$1 [R=301,NC]
RewriteRule / index\.php [L]
RewriteRule index\.php/? / [R=301]
不过不知道楼主这个匹配的目的是什么,index.php前面还有东西么?
(.*)index.php
我现在要实现
www.abc.com/index.php 301 www.abc.com/
www.abc.com/index.php 301 www.abc.com/
abc.com/index.php 301 www.abc.com/
abc.com 301 www.abc.com/
以及所有
index.php/的都要定向到www.abc.com,
不知道这个完整的该怎么写
向您学习了
谢了
index.php/的都要定向到www.abc.com/
RewriteCond %{HTTP_HOST} =www.abc.com [NC]
RewriteRule index\.php/? / [L,R=301]RewriteCond %{HTTP_HOST} =abc.com [NC]
RewriteRule .* http://www.abc.com/$0 [L,R=301]