motm95 Posted August 6, 2004 Posted August 6, 2004 Hello, I have recently moved my Typepad blog over to Movable Type hosted right here on TCH. So far, the experience has been painless as far as the change and wonderful as far as the help I've gotten from TCH! Anyway, here is the issue: Typepad created archives in a silly way -- they are grouped into multiple subfolders in the root directory, so for example, in my root directory (public_html) there is a /2004/ folder containing all archives by date, and multiple subfolders, one for each category in my blog. I'd like to move all my archives into a single /archives/ folder in the root, and then further divided in a manner similar to above. So, rather than a permalink being: http://www.mysite.com/2004/08/05/name_of_post.html it would now be: http://www.mysite.com/archives/2004/08/05/name_of_post.html I know how to do this within MT. My only problem is doing it so outside links to my articles will get automatically redirected to the new location of the archive. I'd also want Google et al to pick up on the change and make the change permanent in their database. I have read that this sort of think is possible with the .htaccess file but I don't know where to start or how to do it. I see that file in my root directory but I have no idea what to put in there. Any help would be greatly appreciated! Charles Quote
schussat Posted August 6, 2004 Posted August 6, 2004 Hi Charles- I think that something like this should work: >redirect permanent /2004 /archives/2004 redirect permanent /2003 /archives/2003 redirect permanent /2002 /archives/2002 ... Putting that code in your .htaccess file should redirect requests to the root-level 2004 directory to the directory within your archives directory, and will do likewise for 2003, 2002, and whatever other directory trees you redirect. This way, external links, or links that are hard-coded within your MT entries should be redirected to the new location (as long as you have the /archives/... tree set up!). Give it a test to see how it works. Quote
motm95 Posted August 8, 2004 Author Posted August 8, 2004 Thanks very much! I ended up doing just that but used the redirect feature in cpanel rather than manually editing the htaccess file and it works great! Thank you! 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.