RewriteRule not working, 404 error obtained

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi.

Using Apache/2.2.31, I created the following rule on my '.htaccess' file:
----------
RewriteEngine on
RewriteRule ^([^/]+)/$ /do.php?label=$1 [L]
--------------

However, when accessing 'http://foo.com/whatever/', I get a 404 error message. I've checked my error log and:
-------
[Mon Jun 27 11:12:15 2016] [error] [client 192.168.1.132] File does not exist: /path-to-web/whatever, referer: http://foo.com/
-----------

'http://foo.com' works ok, and 'http://foo.com/do.php?label=whatever' works ok as well.

I've checked phpinfo, and 'mod_rewrite' is loaded in Apache. Additionally, I tried to enable it via 'http.conf', but Apache tells me that "module rewrite_module is built-in and can't be loaded".

What am I doing wrong? This same '.htaccess' works ok in two other Apache servers.

I tried with "Options +FollowSymLinks -MultiViews" as well. Thank you very much


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux