Tell me more ×
WordPress Answers is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

very weird things happening to my permalinks. its showing me 404 error when i switch to permalinks then when i change to default and then back to permalinks its fine until i actually edit url to specific page then its all goes 404 so when I repeat changing to default and back to permalinks its all fine again. Its even happening when i try to add new page Its never happen before it cannot be the server settings cos i run several WP sites on that server and the rest are fine.

Here is my .htaccess

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

Many thanks for help

share|improve this question
I also noticed that when that's happening my .htaccess embeds and extra rule so it looks as follows: <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress Any idea anyone – jmysona Sep 9 '11 at 17:28
get rid of the .htaccess rules you have pasted in there and just let WordPress add them when you edit your permalink settings. WP looks for # BEGIN WordPress and # END WordPress to add its own rules. – Milo Sep 9 '11 at 18:02
Thanks Milo, could you be more specific, sorry i didn't really get it – jmysona Sep 9 '11 at 18:31

closed as too localized by toscho Jul 14 '12 at 22:00

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, see the FAQ.

1 Answer

This weird problem I also faced, don't know how it came, but I tried this solution and it worked for me.

http://webstutorial.com/wordpress-publish-new-post-redirecting-to-homepage-while-saving-edited-code-redirecting-to-home-page/content-management-system-cms

But in my case scenario was not exactly same, my some pages were giving me 404 and editing any theme and post used to give me 404.

share|improve this answer
i found one solution which isnt perfect but it works when i add /index.php/%postname% to permalinks it works fine but obviously now i'm getting this sort of URL's /index.php/lifec/about-us – jmysona Sep 9 '11 at 18:30
@jmysona the thing which you are doing is known as pretty permalinks, now I found the solution to your problem, email your hosting people to enable mod_rewrite fully, currently its enabled or may be not check with your hosting people – ntechi Sep 10 '11 at 4:44
as i mentioned above its not server issue as I'm hosting several Wordpress websites on that server and all of them don't have any issue only that one – jmysona Sep 10 '11 at 8:15
can you paste here your permalink structure, that you are using – ntechi Sep 10 '11 at 10:45

Not the answer you're looking for? Browse other questions tagged or ask your own question.