Question
I'm trying to implement shorter URL by following instructions in
ShorterUrlCookbook (for current Dakar on hosted Apache 1.3 on CentOS). I've got this in my doc root
.htaccess
file:
RewriteEngine on
RewriteRule ^/([A-Z].*) /home/globalle/public_html/bin/view/$1 [L]
and this in
LocalSite.cfg
$TWiki::cfg{ScriptUrlPaths}{view} = '';
Apache gives me a "Not Found". The error log gives me the rewritten file path without
/bin/view
. Eg:
File does not exist: /home/blah/public_html/Main/WebHome
But: if I manually stick another slash in the browser's URL, it works. Eg:
http://my.domain.name//Main/WebHome
All the page links are rendered without the extra slash, and don't work of course, but they will if I double-slash them.
I've read a lot of doco and Codev topics.
-
configure
is clean.
- I've tried full file paths to the
view
script and relative.
- I've messed around with
$TWiki::cfg{ScriptUrlPaths}{view}
.
- I've got
FollowSymlinks
in .htaccess.
mod_rewrite
gurus: what am I doing wrong?
Environment
--
MarcusLeonard - 19 Nov 2006
Answer
If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.
Sorry, closing this after more than 30 days...
--
PeterThoeny - 29 Dec 2006