在URL重写htaccess中需要帮助


Need help in URL rewriting htaccess

大家好,我需要关于URL重写的帮助我的实际URL是{www.mysub.domain.com/other?Name=Some Product Name&code=12312312}在.htaccess文件中添加代码后,URL将是{www.mysub.domain.com/other/Some Product Name/12312312}。这在我的本地主机上运行良好,但在我的域主机上出现错误。下面是我的代码,请查看并让我知道是错误的。我感谢你的帮助。

<pre>
RewriteEngine on<br>
RewriteRule ^itm/([A-Za-z0-9's+!@$%&*._%+-/'(){}#='"`~|;:<>]+)/([0-9]+)$ itm.php?ItemName=$1&code=$2<br>
</pre>

谢谢。

尝试使用以下方法:

Options +SymLinksIfOwnerMatch
RewriteEngine on
RewriteRule ^([a-zA-Z-]+)$ index.php?action=$1 [NC,L]
RewriteRule ^(member)-([0-9-]+)$ index.php?action=member&id=$2 [NC,L]
RewriteRule ^([a-zA-Z-]+)/([a-zA-Z-]+)-([0-9-]+)$ index.php?action=$1&saction=$2&sid=$3 [NC,L]
RewriteRule ^([a-zA-Z-]+)/([0-9-]+)$ index.php?action=$1&id=$2 [NC,L]
RewriteRule ^([0-9-]+)/([a-zA-Z0-9-]+)/([a-zA-Z0-9-]+)/([a-zA-Z0-9-]+)/(.*).html$ index.php?action=details&id=$1&p1=$2&p2=$3&p3=$4 [NC,L]