{"id":1522,"date":"2003-07-27T07:24:41","date_gmt":"2003-07-27T21:24:41","guid":{"rendered":"http:\/\/michaelhans.com\/eclecticism\/2003\/07\/27\/importing-mt-archives-month-by-month\/"},"modified":"2019-12-05T13:14:24","modified_gmt":"2019-12-05T21:14:24","slug":"importing-mt-archives-month-by-month","status":"publish","type":"post","link":"https:\/\/michaelhans.com\/eclecticism\/2003\/07\/27\/importing-mt-archives-month-by-month\/","title":{"rendered":"Importing MT archives: month by month"},"content":{"rendered":"<div class='__iawmlf-post-loop-links' style='display:none;' data-iawmlf-post-links='[]'><\/div>\n<p>I&#8217;m starting work on importing my archives from The Long Letter into Eclecticism.<\/p>\n<p>What I&#8217;m dealing with is simply the fact that I have archives dating back to November of 2000. While Movable Type has an &#8216;export&#8217; feature, it exports <em>everything<\/em>. With fewer posts, that might be less of an issue, but since I&#8217;m going to have to go through post-by-post to double-check URLs, add pictures, and so on, I wanted to see if I could figure out how to import one month&#8217;s worth of posts at a time, instead of the whole kit and kaboodle.<\/p>\n<p>Here&#8217;s what I ended up with\u2026<\/p>\n<ol>\n<li>Create a new Archive Template, and put the following code into the template:\n<pre><code> TITLE:\n AUTHOR:\n DATE:\n PRIMARY CATEGORY:\n CATEGORY:\n -----\n BODY:\n\n -----\n EXTENDED BODY:\n\n -----\n EXCERPT:\n\n -----\n COMMENT:\n\n AUTHOR:\n\n EMAIL:\n\n URL:\n\n IP:\n\n DATE:\n\n -----\n PING:\n\n TITLE:\n\n URL:\n\n IP:\n\n BLOG NAME:\n\n DATE:\n\n -----\n --------\n<\/code><\/pre>\n<\/li>\n<li>In MT, under the &#8216;Weblog Config&#8217; button, go to the &#8216;Archiving&#8217; section. Click the &#8216;Add new&#8230;&#8217; button, set the Archive Type to &#8216;Monthly&#8217;, and the &#8216;Template&#8217; to the name of the new template that you just created, then click &#8216;Add.&#8217;<\/p>\n<\/li>\n<li>\n<p>You should now have two options under the &#8216;Monthly&#8217; archive type. Switch over to the new archive template that you just created, and put the following in the &#8216;Archive File Template&#8217; box:<\/p>\n<p><code>export\/.txt<\/code><\/p>\n<\/li>\n<li>\n<p>Click the &#8216;Rebuild Site&#8217; option, choose the &#8216;Rebuild Monthly Archive Only&#8217; option, and click the &#8216;Rebuild&#8217; button.<\/p>\n<p>Once MT is done rebuilding, you should have a series of files inside an &#8216;export&#8217; directory inside your site&#8217;s archives directory (in my case, that ended up being <code>\/longletter\/archives\/export\/<\/code>, your configuration may be slightly different). There will be one file for each month, named something like <code>2003-07.txt<\/code>.<\/p>\n<\/li>\n<li>\n<p>In TypePad, under the &#8216;Manage&#8217; tab for your weblog, choose the &#8216;Import\/Export&#8217; option. In box A, put in the URL for your first month&#8217;s export file (for me, this was <code>http:\/\/www.djwudi.com\/longletter\/archives\/export\/2000-11.txt<\/code>). Leave the &#8216;Encoding&#8217; drop-down menu set to &#8216;Unicode&#8217;, and hit the &#8216;Import&#8217; button.<\/p>\n<\/li>\n<li>\n<p>There is no step 6. You&#8217;re done!<\/p>\n<\/li>\n<\/ol>\n<p>So that&#8217;s it. Now that I can go month by month, I&#8217;ll import one month, go through each post to make sure all the links are correct, then move on to the next month. This will probably take a while, as I&#8217;ve got close to three years of posts to check, but I&#8217;m on my way!<\/p>\n<blockquote><p>\n  And the word &#8216;PROJECT&#8217; flashed before my eyes\u2026\n<\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;m starting work on importing my archives from The Long Letter into Eclecticism. I wanted to see if I could figure out how to import one month&#8217;s worth of posts at a time, instead of the whole kit and kaboodle. Here&#8217;s what I ended up with.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2040],"tags":[812,921,25],"class_list":["post-1522","post","type-post","status-publish","format-standard","hentry","category-blog","tag-movabletype","tag-typepad","tag-website"],"_links":{"self":[{"href":"https:\/\/michaelhans.com\/eclecticism\/wp-json\/wp\/v2\/posts\/1522","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/michaelhans.com\/eclecticism\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/michaelhans.com\/eclecticism\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/michaelhans.com\/eclecticism\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/michaelhans.com\/eclecticism\/wp-json\/wp\/v2\/comments?post=1522"}],"version-history":[{"count":0,"href":"https:\/\/michaelhans.com\/eclecticism\/wp-json\/wp\/v2\/posts\/1522\/revisions"}],"wp:attachment":[{"href":"https:\/\/michaelhans.com\/eclecticism\/wp-json\/wp\/v2\/media?parent=1522"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/michaelhans.com\/eclecticism\/wp-json\/wp\/v2\/categories?post=1522"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/michaelhans.com\/eclecticism\/wp-json\/wp\/v2\/tags?post=1522"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}