Hey all.

I ran into this, I have a feeling it's something simple, but I can't find a post that answers my question yet. I am in the process of upgrading, just made a test site. I got everything working on it except for my clean URLs. It's a pain to make sure everything works manually!

I did indeed copy over the .htaccess file. I know mod rewrite is enabled because I have the clean URLs working fine on the public site. I do not have root and cannot access httpd.conf.

Is it possible there is a change I need to make that I am not aware of to the .htaccess file? Or do I need to contact my systems administrator for help with something in the httpd.conf file?

Also, by and by, I am going from 4.7.4 to 5, and I am wondering if I should go to 4.7.6 first to be safe.
Thanks so much.

Comments

cog.rusty’s picture

How are Clean URLs broken?
- Are they enabled in /admin/settings/clean-urls and links like "http://example.com/user" don't work
- Are they disabled in /admin/settings/clean-urls and you can't enable them because the "Run the clean URL test" link fails to activate the "Enable" radiobutton?
- What are the "broken links" mentioned in the title?

I have the clean URLs working fine on the public site.

To make sure that this matters, where is your new test site and where is the old public one with the working Clean URLs? I mean, is the new one a fresh Drupal installation in a subdirectory of the first one or in a subdomain? Or are they both parts of a multisite?

Is it possible there is a change I need to make that I am not aware of to the .htaccess file? Or do I need to contact my systems administrator for help with something in the httpd.conf file?

Normally nothing of the above is needed, except if there is something "unusual" in your setup. Now, what "unusual" means... that's another story.

I am going from 4.7.4 to 5, and I am wondering if I should go to 4.7.6 first to be safe.

Drupal 5 is designed to update from any 4.7 release, so you should be safe. The only difficult part is replacing all your additional modules and themes with their Drupal 5 versions. The old ones just won't work.

Some people feel safer going first to the latest and most stable release of a version (4.7.6), but anyway this first step is trivial. It takes only a few seconds to run update.php and there is no need to replace or update modules and themes in this step.

mosa’s picture

thanks for replying!

i am unable to use clean urls because i fail the clean url test.

i am running a completely separate install of drupal for upgrades. it is a multi-site configuration.

in terms of unusual things in my setup, it's possible that my sys-admin has limited something on his end. what are the possibilities in terms of strange settings i can look for?

i don't mind that they are not working for the test site, but i want to make sure that the real site won't have problems when i move everything over. do you think that clean urls will work again once i move the upgraded version of the site to be the public/live one?

thanks for the advice about upgrades! I am on 5.2 now. I am resolving lots of other issues, but still can't figure it out.

any more advice would be great!

cog.rusty’s picture

There is a handbook page about what Clean URLs need to work. Two things are needed: A correct server configuration, and Drupal's .htaccess file.

http://drupal.org/node/15365

- You said that they work in your first site. This means that the server configuration is probably OK.
- You also said that you have copied Drupal's .htaccess file to the second site's directory, so that is OK as well, but you may need to make some change.

Is the second site accessed as a subdirectory? (http://example.com/sub) Then try to change the RewriteBase / line in its .htaccess file to RewriteBase /sub. I have never needed to do that but sometimes it helps. Don't do this if you are accessing the site as a subdomain.

If that fails, check also the second site's settings.php file, the $base_url line, to see if it is commented out with a # or if the correct subdirectory (or subdomain) is specified. Try both.

There are several "IFs" there, but I have no idea where you have placed your sites and how you access them.