Options +Indexes +Includes +FollowSymLinks +MultiViews
It looks likeWhy are you may have a conflict withexplicitly enabling MultiViewsMultiViews
in your server config? This is likely the cause of your problem. Try removing +MultiViews
from your server config (above), and/or disable MultiViews at the top of your .htaccess
:
Options -Indexes -MultiViews
MutliViews is disabled on a default Apache install, however, some (shared) hosts do seem to enable it. So, disabling it in .htaccess
as a matter of course is probably recommended.
(But also, why are you enabling Includes
- is this really necessary? Since you are using PHP, this is unlikely.)
The effect of MultiViews is noticeable because you have effectively removed the file extension to create your user-friendly URLs.
With MultiViews enabled (part of mod_negotiation)... when you request Page/13/Page-Title
, Apache tries to find a matching file in the current/root directory that matches the basename Page
, by trying various extensions that would return the appropriate mime-type. This occurs before mod_rewrite is able to rewrite your friendly URL. So, MultiViews ends up rewriting your request to Page.php
without passing any of the URL params (the rest of the URL will likely be seen as PATH_INFO), hence your "Undefined index" PHP notice.
(Although you should also be checking for the existence of this $_GET
variable in your PHP script, which you don't seem to be doing.)