!!blue Posted October 7, 2004 Posted October 7, 2004 I need to permanently redirect all pages under the public_html/blog/archives/ folder to blog/archives.php. A good friend of mine said I should use mod_rewrite in conjuction with the 301 redirect. The pages that were under the archives folder (created by movable type) were created like so: 18-Oct-2003-8:10PM.shtml. So, it had the date separated with dashes and then the time with the shtml extension. I want to permanently redirect all those pages to the new archives page (a great plugin for wordpress created this page): h**p://blog.zoblue.com/archives.php I was using this: >Redirect 301 /blog/archives/ http://blog.zoblue.com/ but that doesn't work on all the pages *in* that folder. It might be wrong all together. How can I do the permanent redirect w/mod_rewrite for any pages that previously existed under the archive folder? And please go easy on my brain, ok? thanks, !!blue Quote
MikeJ Posted October 7, 2004 Posted October 7, 2004 (edited) Something like this should work if you just want to blanket redirect all requests for /archives/* to archives.php (make sure this goes into the .htaccess that's in your blog/ directory): >RewriteEngine On RewriteBase / RewriteRule ^archives/(.*)$ archives.php [L,R=permanent] Wordpress, however, *does* have the ability to translate MT entries to WP entries through .htaccess rules so you can still have links that are in search engines go to the correct entry. Edited October 7, 2004 by TCH-MikeJ Quote
!!blue Posted October 7, 2004 Author Posted October 7, 2004 ah, yes, I found this link in the WP wiki: h**p://wiki.wordpress.org/MT-Redirect I'll have to try that tonight. For now the redirect you gave worked wonderfully. So, if I do try what the wiki suggests, will that take place of the lines you just suggested? thanks, !!blue Quote
MikeJ Posted October 7, 2004 Posted October 7, 2004 Yea... I'm actually using Alex's method (I guess I did republish all my mt-blog entries as redirects). I haven't tried that new method yet. Quote
!!blue Posted October 9, 2004 Author Posted October 9, 2004 I've figured out I can't use either of those methods. I did the whole thing backwards. Movable Type was in the blog folder and once I got WordPress up and running: I moved MT to blogMT and moved WP to blog (not really moved, more of renaming folders). Now I can't log in to movable type to republish my entries and redirect them appropriately. Oh well, it's not that big of a deal. later, !!blue Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.