I hope someone will be able to help me out a little, because I am stuck for 2 days now. I was moving my blog over to new host from another server. the database was full of bugs thanks to all the wonderful plug ins I used, so I had a hell of a time trying to restore the database. Finally, after a lot of tweaking, I managed to import it without errors. but, I am only able to view the front page, but any link I click, is broken. My guess was that it has something to do with rewrite rules for wordpress, so I manually added .htaccess file with: PHP Code: # BEGIN wordpress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END wordpress But it did not help. The blog I am moving is originally pointing to toptut.com (I changed the DNS back to old server for now, to avoid downtime, while I am experimenting.). On the Servint server, I installed and restored the database to http://loreleiweb.com/25 (and yes I changed to home directory in phpmyadmin for loreleiweb.com/25, just to make it work) The structure remained the same, for example, http://loreleiweb.com/25/2009/04/10/ramiro-coffee-neat-and-light-weight-magazine-theme/ and http://www.toptut.com/2009/04/10/ramiro-coffee-neat-and-light-weight-magazine-theme/ Only that loreleiweb.com/25's inner pages redirect to loreleiweb.com's front page. HOW do I make the permalinks work? I'd be grateful if anyone can help me please. I already tried adding loreleiweb.com/25 to rewrite base and rewriterule, no luck. Thanks, Liza
There are two places in the database and in phpmyadmin to change the home setting! Did you find and change both of those or in just the one place? The second setting location is not as easy to find as the main one, have to page the options table with button like this [>] at bottom to go to other entries. Boulder
Hi Boulder, thanks for your reply. Yes I changed it in both places, but that only brings the front page to work
Something is wrong, that's for sure. Did links and such function as intended before you imported the database? (I'm thinking here of the original installation of WP, with the sample "hello world" post and such.) I tried accessing your posts with the direct links (/?p=<number>) but it still just redirects to the front page.
Thanks for all your replies guys! @ Bohra, .htaccess is on 777, and I tried to update but it did not help. @Boulder, I did but in any way it was one of the settings restored with the old database. I tried saving it once more like that, but still nada. @PoPSiCLe you can see the site now on toptut.com, it works fine, all links are functioning. Wordpress installation I believe is fine, the database itself kept generating an error upon importing, so it took a massive effort (and a few re installations) to get it to at least get imported with all the posts properly. I had a similar problem once with some other blog and I was told that rewrite rules for wordpress were missing, but in this case I do have them in htaccess file, right?
Turn off completely the permalinks and set it back to default setting than Save! Than go back to front of blog and see if links work right then? If they do? Than you will know that the problem is with the .htaccess file rules? If the links still do not work, after switching to default, than the problem is probably not with the .htaccess but would be some other config setting issue someplace else. Boulder
WOW! it works!!! http://loreleiweb.com/25/?p=1870 <--- yay, that one didn't work previously! okay so this means problem is with .htaccess, but where? this is my entire .htaccess file: # BEGIN wordpress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END wordpress # BEGIN WordPress # END WordPress Code (markup): that second past at the end: # BEGIN WordPress # END WordPress I think appeared only recently, it was not there before. CMOD is set to 777 for this file, and I think 755 for the entire blog.
Place this rules in the .htaccess file in the 25 directory and try it. # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase /25/ RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /25/index.php [L] </IfModule> # END WordPress Let me know if this works? Make sure to turn back on the permalinks and set this in the field = /%postname%/ Boulder
yep, that worked perfect! I switched the permalinks back to old version, and it worked!! thank you so much!!! Now, I would want to change the toptut.com domain to point into the /25/ folder. So once I change the DNS, I: change both locations in phpmyadmin to toptut do i also need to changed the htaccess file in any way?
Kool glad it worked... LOL Okay NO! you will not need to change anything in the .htaccess file when you change the main part to toptut.com. You would only need to change the rules if you were to change the "25" sub folder name! Also you should change the permissions back to 644 or 666 on the .htaccess file. There is not a reason what so ever to have that file set at 777 and it would be a security risk to leave it set that way.. All my .htaccess files are at 644. Boulder
Just run test.php with this code inside Once it loads, look carefully for mod_rewrite under apache modules. If it is listed then mod_rewrite is installed.
Instead since u are on a dedicated server do this Find and Open your httpd.conf Find LoadModule rewrite_module modules/mod_rewrite.so and see whether it has # before it if it does remove # Restart Apache Server
Boulder, thank you so much, you are a real angel! I changed the htaccess to 644 and won't touch it anymore. So I will just change 'siteurl' and 'home' values at phpmyadmin and I am set. yay, it took a bloody week to move this webiste and all thanks to one plug in that totally overwrote stuff in my database! Thanks Bohra and olddocks for your kind help too!!