Fix for Drupal Clean URL Test Failure

DrupalEnabling Clean URLs in Drupal means getting rid of the URL parameters in your URL. Instead of the visitor will see

I’ve run into the Clean URL Test failure a few times now since I’ve been using Drupal (not long). Both times the solution has been the same (prompting me to blog the issue as a reminder).

Both times I’ve encountered the problem, it’s been while building a new site for a client on a temporary domain. When setting up hosting for a client I usually set up a new hosting account on a shared server and reference it by IP address until I’m ready to point the DNS servers at it.

The problem I run into is that, since the server is shared, a folder name is appended to the IP address, such as . That folder name is the reason that the Clean URL test fails.

If you install Drupal into a subfolder of your domain, you have to uncomment the RewriteBase line in your .htaccess file and change “/drupal” to your subfolder name. After doing so, your Clean URL test should pass.