【发布时间】:2015-09-21 15:43:18
【问题描述】:
我的网址已更改为
http://example.com/course.php?id=1001
到
http://example.com/course/1001
但是在更改所有css js和图像的url后不起作用
我用过这个代码
RewriteEngine On
RewriteRule ^course/([A-Za-z0-9-]+)/?$ coursedetails.php?id=$1 [NC,L]
【问题讨论】:
-
那么您应该免除 css/image url 的重写...例如
RequestCond -f %{REQUEST_URI}
标签: html css apache .htaccess mod-rewrite