This is a discussion on How to redirect with Rewrite rules ? within the Apache Web Server forums, part of the Web Server and Related Forums category; I'm running a local apache v2.2.6 with full access. I'm trying to make apache redirect all ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
I'm running a local apache v2.2.6 with full access.
I'm trying to make apache redirect all non-direct to an index file in a subfolder of documentroot. Without luck so far. Currently have done the same but the index is in the root of documentroot, which works like a charm. RewriteEngine on RewriteRule ^(.+)/$ index.php Because I have multiple projects, then I want to redirect to the index file of the project. RewriteEngine on RewriteRule ^(.+)/$ Project1/index.php Above code doesnt work. I restarted apache on each try. Any idea what Im doing wrong ? |
|
|||
|
Kim a écrit :
> Above code doesnt work. I restarted apache on each try. Any idea what > Im doing wrong ? No, but adding RewriteLog /tmp/rewrite.log and tracing it might help. -- Nicolas Bouthors -=- Tel : 06 20 71 62 34 -=- Fax : 01 46 87 21 99 NBi SARL -=- http://nbi.fr -=- nbouthors@nbi.fr |
|
|||
|
On Mar 10, 5:36 pm, Nicolas BOUTHORS <nico...@bouthors.org> wrote:
> Kim a écrit : > > > Above code doesnt work. I restarted apache on each try. Any idea what > > Im doing wrong ? > > No, but adding RewriteLog /tmp/rewrite.log and tracing it might help. > > -- > Nicolas Bouthors -=- Tel : 06 20 71 62 34 -=- Fax : 01 46 87 21 99 > NBi SARL -=-http://nbi.fr-=- nbouth...@nbi.fr I keep getting 500 errors when adding rewritelog to .htaccess. The error.log file reports "RewriteLog not allowed here" RewriteEngine on RewriteLog "C:/Apache 2.2/rewritelog.log" RewriteRule ^(.+)/$ Project1/index.php |
| Thread Tools | |
| Display Modes | |
|
|