url.redirect = ( "^/show/([0-9]+)/([0-9]+)$" => "http://www.example.org/show.php?isdn=$1&page$2",
"^/get/([0-9]+)/([0-9]+)$" => "http://www.example.org/get.php?isdn=$1&page$2" )
You need to activate required modules i.e. mod_redirect and mod_rewrite in lighttpd.conf
URL redirect can be done using url.redirect directive:
Code:
url.redirect = (
"^/home.html$"$" => "http://domain.com/news.php",
"^/index.html$" => "http://domain.com/news.php",
"^/index.htm$" => "http://domain.com/news.php",
"^/default.html$" => "http://domain.com/news.php",
"^/default.htm$" => "http://domain.com/news.php"
)
Rewrite rules always execute before redirect rules so add them first and followed by redirect rules in following format
Code:
url.rewrite-once = (
"<regex>" => "<relative-uri>",
"<regex>" => "<relative-uri>"
)
Here is sample
Code:
url.rewrite-once = (
"^/download.html$" => "download.php",
"^/downloads([0-9]*)\.html(.*)$" => "download.php?view.$1"
)
You need to test them, usually not a big difference. Following will provider
more info
Docs:ModRewrite - lighttpd - Trac