求教 关于rewrite 定向的正则问题!

LEIIT 2013-11-15 10:10:01
求个正则表达式关于apache rewrite的

比如网站有当前几个目录
/static/image/aaa.jpg
/template/html/aaa.html
/article/detail/?id=1
/member/login/
/member/register/
....

想要 排除 static 和template 开头的url 其他全部 重定向到 index.php入口处理
如果用匹配article和member 是可以实现,但是网站的模块会越来越多,但是静态的目录就static和template

所以最好的处理方法是 除了static,template实际存在的目录 其他都定向走,就是把static或template作为整体取非.求教大神怎么写
...全文
185 回复 打赏 收藏 转发到动态 举报
写回复
用AI写文章
回复
切换为时间正序
请发表友善的回复…
发表回复

1,978

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术 其他语言讨论
社区管理员
  • 其他语言社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧