Some good troubleshooting stuff on the Permalinks page.
In particular, confirm with your host that mod_rewrite and AllowOverride are both on and enabled.
Thread Starter
HTT
(@htt)
My htaccess file reads:
RewriteEngine On
RewriteRule x.html y.html
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
Does that mean its enabled and on?
And if you go to x.html, do you actually get y.html?
Thread Starter
HTT
(@htt)
I don’t know what you mean, sorry.
Your .htaccess has this line:
RewriteRule x.html y.html
If you have mod_rewrite working, browsing to http
://yourdomain.com/x.html should result in display y.html.
If you create an x.html and a y.html file and upload them, does it?
Thread Starter
HTT
(@htt)
I’ve just created both y and x.html files uploaded them and when I type them into my browser I get those files and not switched around, does that mean I don’t have mod-rewrite enabled on my server?
Thread Starter
HTT
(@htt)
Still no nearer to solving this, does anyone have any ideas? We have modrewrite turned on. The thing is, it was working on the old server, only when we moved has it started doing this yet the paths are all correct, everything.
I went to your x.html. If your mod_rewrite was working, your server should’ve presented me with y.html.
It didn’t.
Thus, the other piece I suggested: Check with your host and make sure AllowOverride is enabled for your domain.
Thread Starter
HTT
(@htt)
Hi Solo, thanks for your reply. Just fired this thread off to the server guys. My spellchecker, anti-spam comments images and my imagemanager aren’t working either, could this be down to mod_rewrite do you think, too, like with the permalinks?
It’s conceivable that those are all related.
If you visit Options -> Permalinks and set ’em to “Default”, do any of the other things start working?
Thread Starter
HTT
(@htt)
No they don’t, they don’t work for any comination of permalink set up strangely enough. I’ll get my server team to take a look at the other things or I’ll uninstall them and reinstall them as I’ve read from others who’ve moved servers of having success that way.
Thread Starter
HTT
(@htt)
Hmm, my current settings in “Options”, “General” are:
WordPress address (URI): My full domain name
Blog address (URI): My full domain name
Now if I change the Blog address URI to this: http://www.newcastle-online.com/index.php
And then go to “Permalinks” in “Options” and set it to this: “Date and name based”
My Permalink structure looks like this: http://www.newcastle-online.com/index.php/2006/10/21/sample-post/
But when I press Update a blue warning says: You should update your .htaccess now.
And at the bottom the following is printed out:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /index.php/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php/index.php [L]
</IfModule>
What do I do?
That is the structure I want but without the index.php bit in so it just does this instead: http://www.newcastle-online.com/2006/10/21/sample-post/
Thread Starter
HTT
(@htt)
Also, clicking http://www.newcastle-online.com/2006/10/21/sample-post/ takes me to a server generated 404 where as clicking http://www.newcastle-online.com/index.php/2006/10/21/sample-post/ takes me to a WordPress generated 404
Am I getting close to what is the problem or is this just even more problems?
Ok, you’re on the right track…
First off, remove index.php from your Options -> General settings.
Head back to Options -> Permalinks and set your permalinks as desired. Presumably, you’ll get that warning again. That’s WP telling you that it can’t write to the .htaccess file (or create one).
So, look in your blog directory for the file (it’s hidden, so if using an FTP client, make sure you tell it to show hidden files). If you don’t find it, create one and upload it with the contents that WP told you to put in there. If there is one there, just add that block of code.
Thread Starter
HTT
(@htt)
I did what you said but this time it didn’t say I needed to update htaccess, it says Permalink structure updated.
But going back to my site the links head to 404s again, not WordPress generated 404s but server ones.
For example: http://www.newcastle-online.com/2006/10/20/a-message-to-newcastle-fans-from-palermo-fans/
What does that mean?