【发布时间】:2011-02-12 16:52:49
【问题描述】:
我正在尝试使用 Lighttpd 进行 url 重写。我有我需要的部分工作。现在我有这个: http://domain.com/name/a/123 重写为 http://domain.com/name/a.php?pid=123
我使用此重写一次规则来执行此操作:"^/name/a/([^/]+)"=> "/name/a.php?pid=$1"
该 php 页面具有未被重写的外部资源,例如 JavaScript 和 CSS 文件。有没有办法我也可以让重写执行以下操作?
http://domain.com/name/a/js/file.js => http://domain.com/name/js/file.js
【问题讨论】:
标签: regex mod-rewrite rewrite lighttpd