Mod_Rewrite类别目录

时间:2010-05-14 15:13:30

标签: mod-rewrite

我想从根目录转发类别到index.php;这是一个例子;

domain.com/en/category1/category2/ ---> ?的index.php郎= EN&安培; CAT1 =类别1&安培; CAT2 =类别2

我该怎么做?

1 个答案:

答案 0 :(得分:0)

试试这个

RewriteEngine On
RewriteRule /([a-z]+)/([a-zA-Z0-9]+)/([a-zA-Z0-9]+).*  /index.php?lang=$1&cat1=$2&cat2=$3 [QSA,NC]