<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
		xmlns:xhtml="http://www.w3.org/1999/xhtml"
>

<channel>
	<title>ぷりどうぐ &#187; wordpress</title>
	<atom:link href="http://prius.cc/d/tag/tag-wordpress/feed" rel="self" type="application/rss+xml" />
	<link>http://prius.cc/d</link>
	<description>1981年生まれのITエンジニアがスノーボードや技術情報を書いているブログ。</description>
	<lastBuildDate>Fri, 18 May 2012 21:38:38 +0000</lastBuildDate>
	<language>ja</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1.4</generator>
<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://prius.cc/d/tag/tag-wordpress/feed" />
		<item>
		<title>WordPressのバージョンを2.7.8→2.8.4にアップデート</title>
		<link>http://prius.cc/d/20090920wordpress_2-7-8to2-8-4.html</link>
		<comments>http://prius.cc/d/20090920wordpress_2-7-8to2-8-4.html#comments</comments>
		<pubDate>Sat, 19 Sep 2009 15:44:50 +0000</pubDate>
		<dc:creator>tera</dc:creator>
				<category><![CDATA[BlogやSNS]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://prius.cc/d/?p=2086</guid>
		<description><![CDATA[				2.8.4以前には深刻な脆弱性があるらしいので連休を利用してアップデートしてみました。…30分くらいで終わりましたが。
				
				参考にした記事：WordPressのバージョンを2.8.2から2.8.4に [...]]]></description>
			<content:encoded><![CDATA[				<p>2.8.4以前には深刻な脆弱性があるらしいので連休を利用してアップデートしてみました。…30分くらいで終わりましたが。</p>
				
				<p>参考にした記事：<a href="http://www.ideaxidea.com/archives/2009/09/upgraded_to_latest_version_of_wp.html" title="WordPressのバージョンを2.8.2から2.8.4にあげたよ - IDEA*IDEA ～ 百式管理人のライフハックブログ">WordPressのバージョンを2.8.2から2.8.4にあげたよ &#8211; IDEA*IDEA ～ 百式管理人のライフハックブログ</a></p>
				
				<p>ちなみにWordPressには自動アップデート機能がついていますが、<strong>恐ろしくて誰も使っていません。</strong></p>
				
				<h3>手順メモ</h3>
				
				<p>1.サーバにsshログイン<br />
				2.ディレクトリをコピー</p>
				
				<p>cp -r d d-20090920</p>
				
				<p>3.SQLデータベースのバックアップ<br />
				mysqldump exco -uexco -pPASSWORD -hDATABASENAME > /home/exco/20090920_sqlbackup.txt</p>
				
				<p><a href="http://suishodo.net/archives/2007/09/mysql.html" title="水晶堂: さくらインターネットでのmySQLデータ自動バックアップ">水晶堂: さくらインターネットでのmySQLデータ自動バックアップ</a></p>
				
				<p>4.プラグインを停止<br />
				5.テーマをデフォルトに戻す<br />
				6.最新版のWordpressをダウンロードして上書き！<br />
				7.管理画面にログイン。</p>
				
				<p>2.7.8→2.8.4とバージョンを跨いだせいかデータベースのアップデートを要求される…が、あっさり終わりました。</p>
				
				<p>8.プラグインとテーマを元に戻す</p>
				
				<h3>問題点</h3>
				
				<p>思った以上にスムーズだったけどちょっとした問題が。</p>
				
				<h4>1.wp-dbmanagerがエラー出力</h4>
				
				<blockquote>
				  <p>Your backup folder MIGHT be visible to the public</p>
				  
				  <p>To correct this issue, move the .htaccess file from wp-content/plugins/wp-dbmanager to /home/exco/www/d/wp-content/backup-db</p>
				</blockquote>
				
				<p>調べてみると、バックアップ領域にダイレクトでアクセスできちゃって危険だよ！というメッセージ。バックアップ領域に以下の.htaccessを置くことで解決。</p>
				
				<p><pre class="brush: ruby; title: ;">
&amp;lt;files ~ &amp;quot;.&lt;em&gt;..&lt;/em&gt;&amp;quot;&amp;gt;
order allow,deny
deny from all
&amp;lt;/files&amp;gt;
</pre></p>
				
				<p>参考：<a href="http://wordpress.b-cures.net/archives/178/" title="WordPressのバックアップをとるwp-dbmanager ≪ wordpress*design*b">WordPressのバックアップをとるwp-dbmanager ≪ wordpress<em>design</em>b</a></p>
				
				<h4>2.WordPress.com StatsがAPIキーを要求</h4>
				
				<p>データベースをアップデートした影響か、アクセス解析プラグインのWordPress.com StatsがAPIキーを要求。そんなの覚えてねぇ！ってことで「WordPress.com API」で過去メールを検索したところ、AkismetのAPIキーとして発行されてました。キーを入力して終了。</p>
				
				<p>以上。細かい所はこれから見ていくので、何かあれば追記する予定です。</p>
]]></content:encoded>
			<wfw:commentRss>http://prius.cc/d/20090920wordpress_2-7-8to2-8-4.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://prius.cc/d/20090920wordpress_2-7-8to2-8-4.html" />
	</item>
		<item>
		<title>実際の移行レポートとその後</title>
		<link>http://prius.cc/d/20090322_sb_wordpress_switch7html.html</link>
		<comments>http://prius.cc/d/20090322_sb_wordpress_switch7html.html#comments</comments>
		<pubDate>Sun, 22 Mar 2009 13:33:03 +0000</pubDate>
		<dc:creator>tera</dc:creator>
				<category><![CDATA[BlogやSNS]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://prius.cc/d/?p=1374</guid>
		<description><![CDATA[				目次
				
				
				旧ブログのアクセスを引き継ぎつつ、個別記事ページを生成していないSereneBach(sb)からWordPressへ移行する方法(このエントリ)
				新ブログのパーマリンク作 [...]]]></description>
			<content:encoded><![CDATA[				<h3>目次</h3>
				
				<ol>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch1.html">旧ブログのアクセスを引き継ぎつつ、個別記事ページを生成していないSereneBach(sb)からWordPressへ移行する方法</a>(このエントリ)</li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch2.html">新ブログのパーマリンク作成(投稿名ベース)</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch3.html">旧ブログ→新ブログへのパーマリンク対応作成</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch4.html">SereneBachからエクスポートしたデータを編集</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch5.html">WordPressにSereneBachからエクスポートしたデータをインポート</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch6.html">旧ブログ(sb)→新ブログ(WordPress)へのリダイレクト設定</a></li>
				<li>実際の移行レポートとその後←今ここ</li>
				</ol>
				
				<hr />
				
				<p>今までに説明した手順で実際に移行した結果を報告します。</p>
				
				<p>1.新サイト(wordpress)のbasic認証解除</p>
				
				<p>構築中に.htaccessで検索に引っかからないようにしていたのを解除します。</p>
				
				<p>2.旧サイト(sb)→新サイト(wordpress)へのリダイレクト開始</p>
				
				<p>旧サイトの.htaccessを有効にし、新サイトにリダイレクトできるようにします。</p>
				
				<p>3.念のため旧サイトのURLでアクセスして新サイトに飛ばされるか確認。</p>
				
				<p>旧サイトでアクセスの多いページをpickupし、新サイトにリダイレクトされるか確認します。</p>
				
				<p><strong>終わり。</strong>作業時間は5分くらいでした。後は検索エンジンの登録が切り替わるのを待つのみ。</p>
				
				<h3>Web型RSSリーダーのURL変更</h3>
				
				<p>これは速攻でリダイレクトされました。リダイレクトを開始したのがAM5時なので4～5時間以内にリダイレクトされた事になります。</p>
				
				<ul>
				<li>Bloglines 03/18 09:15:37 </li>
				<li>livedoor Reader 10:00:42 </li>
				<li>DELCO READER rss2 11:07:03 </li>
				<li>FreshReader 03/18 10:30:13 </li>
				<li>Google Reader 03/18 10:31:04 </li>
				<li>Yahoo RSSリーダー 03/18 06:53:53 </li>
				<li>Fastladder 03/18 14:06:28</li>
				<li>はてなRSS 3/18 16:46:32</li>
				</ul>
				
				<h3>検索エンジンのURL変更</h3>
				
				<p>移転から5日経った3月22日に、「ぷりどうぐ」で検索したら新URLが一番上に来るようになりました。ただ個別ページは旧URLの方が上に来ます。旧URLから新URLへの移転はちょっと時間がかかりそうです。</p>
				
				<p>(2009/3/25追記)
				個別ページの登録も切り替わり始めました。Yahoo!はhttp://prius.cc/d/以下の個別ページに切り替わって完璧。Googleはhttp://prius.cc/d/temp以下まで切り替わり。META refresh分だけ遅れてるようです。MSNは…全然切り替わらない！なんとかしろよ～(汗 まぁMSN経由で来る人少ないからいいけどさ。</p>
				
				<p>(2009/3/30追記)
				googleも完全に切り替わりました。MSNはダメです。</p>
				
				<h3>アクセス数について</h3>
				
				<p>変化なし。旧URLからのアクセスが全て飛ばされてくるので当然ですが…。ただこれから新規記事を書いても旧URLほど検索エンジンで上位に来ないかもしれません。</p>
				
				<hr />
				
				<p>以上で移行手順は終了です。5年近く使用した旧URLは大手ニュースサイトからリンクが張られたりと価値も高くちょっと名残惜しいですが、こればっかりは時間が解決するほかないと思います。これからは地道にこのURLでエントリ書いて、5年後には旧URLで書いたエントリ数を抜きたいですね。</p>
]]></content:encoded>
			<wfw:commentRss>http://prius.cc/d/20090322_sb_wordpress_switch7html.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://prius.cc/d/20090322_sb_wordpress_switch7html.html" />
	</item>
		<item>
		<title>旧ブログ(sb)→新ブログ(WordPress)へのリダイレクト設定</title>
		<link>http://prius.cc/d/20090322_sb_wordpress_switch6html.html</link>
		<comments>http://prius.cc/d/20090322_sb_wordpress_switch6html.html#comments</comments>
		<pubDate>Sun, 22 Mar 2009 13:32:24 +0000</pubDate>
		<dc:creator>tera</dc:creator>
				<category><![CDATA[BlogやSNS]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://prius.cc/d/?p=1371</guid>
		<description><![CDATA[				目次
				
				
				旧ブログのアクセスを引き継ぎつつ、個別記事ページを生成していないSereneBach(sb)からWordPressへ移行する方法(このエントリ)
				新ブログのパーマリンク作 [...]]]></description>
			<content:encoded><![CDATA[				<h3>目次</h3>
				
				<ol>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch1.html">旧ブログのアクセスを引き継ぎつつ、個別記事ページを生成していないSereneBach(sb)からWordPressへ移行する方法</a>(このエントリ)</li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch2.html">新ブログのパーマリンク作成(投稿名ベース)</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch3.html">旧ブログ→新ブログへのパーマリンク対応作成</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch4.html">SereneBachからエクスポートしたデータを編集</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch5.html">WordPressにSereneBachからエクスポートしたデータをインポート</a></li>
				<li>旧ブログ(sb)→新ブログ(WordPress)へのリダイレクト設定←今ここ</li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch7.html">実際の移行レポートとその後</a></li>
				</ol>
				
				<hr />
				
				<p>ここからが本番。旧ブログから新ブログへのリダイレクト設定を行います。SereneBachで個別記事htmlを作成していない場合はキツいです。</p>
				
				<h3>個別記事htmlを作成している場合</h3>
				
				<p>まずは簡単な方から。<strong>個別記事htmlを作成している場合、.htaccessのRedirect permanet機能のみでリダイレクトを行う事が可能です。</strong>検索エンジン相手にはステータスコード301を返し移動した事を知らせ、人間が普通にブラウザでアクセスしてきたら、移動先のURLに速攻で飛ばします。URL移転の際に、過去のアクセスを引き継ぐ一番良いと言われている方法です。</p>
				
				<p>今回の場合なら、
				<pre>
Redirect permanent /sb/log/eid858.html http://prius.cc/d/20090312_heisei20nembunnokakuteishinkok.html
Redirect permanent /sb/log/eid857.html  http://prius.cc/d/20090311_union_bindgin_forceotsukattemi.html
Redirect permanent /sb/log/eid856.html  http://prius.cc/d/20090310_choukoii.html</p>

<p>～</p>

<p>Redirect permanent /sb/log/eid3.html  http://prius.cc/d/20040422_tanjunnanamaedana_internet2.html
Redirect permanent /sb/log/eid2.html  http://prius.cc/d/20040415_bokobokoboko.html
Redirect permanent /sb/log/eid1.html  http://prius.cc/d/20040414_torakkubakkuyattemimashita.html
Redirect permanent /sb/log/eid0.html  http://prius.cc/d/20040412_akuachitannekku_fuaiten.html
</pre></p>
				
				<p>と延々書いて行けばOKです</p>
				
				<p>※参考URL</p>
				
				<ul>
				<li><a href="http://w3g.jp/others/htaccess/redirect">HTTPリダイレクト Others .htaccess</a></li>
				<li><p><a href="http://www.shtml.jp/htaccess/redirect.html">.htaccessでリダイレクト機能を利用する方法</a></p></li>
				<li><p><a href="http://mikeneko.creator.club.ne.jp/~lab/web/htaccess/redirect.html">ミケネコの htaccess リファレンス</a></p></li>
				<li><a href="http://kazuizm.com/2005/12/13-180703.php">.htaccessによる旧URLのリダイレクト方法 (Kazuの挑戦日記)</a></li>
				</ul>
				
				<h3>個別記事htmlを作成していない場合</h3>
				
				<p>しかし個別記事htmlを作成せず、sb.cgi + パラメータでアクセスしている場合<strong>この方法は使えません。</strong>なぜなら</p>
				
				<p><pre>
Redirect permanent /sb/sb.cgi?eid=858 http://prius.cc/d/20090312_heisei20nembunnokakuteishinkok.html
Redirect permanent /sb/sb.cgi?eid=857  http://prius.cc/d/20090311_union_bindgin_forceotsukattemi.html
Redirect permanent /sb/sb.cgi?eid=856  http://prius.cc/d/20090310_choukoii.html</p>

<p>～</p>

<p>Redirect permanent /sb/sb.cgi?eid=3  http://prius.cc/d/20040422_tanjunnanamaedana_internet2.html
Redirect permanent /sb/sb.cgi?eid=2  http://prius.cc/d/20040415_bokobokoboko.html
Redirect permanent /sb/sb.cgi?eid=1  http://prius.cc/d/20040414_torakkubakkuyattemimashita.html
Redirect permanent /sb/sb.cgi?eid=0  http://prius.cc/d/20040412_akuachitannekku_fuaiten.html
</pre></p>
				
				<p>と.htaccessに記載した場合、<strong>「?」以降は移転先のURLのパラメータとして処理されます。</strong>つまり実質下記のようになってしまいます。</p>
				
				<p><pre>
Redirect permanent /sb/sb.cgi http://prius.cc/d/20090312_heisei20nembunnokakuteishinkok.html?eid=858
Redirect permanent /sb/sb.cgi http://prius.cc/d/20090311_union_bindgin_forceotsukattemi.html?eid=857
Redirect permanent /sb/sb.cgi http://prius.cc/d/20090310_choukoii.html?eid=856</p>

<p>～</p>

<p>Redirect permanent /sb/sb.cgi http://prius.cc/d/20040422_tanjunnanamaedana_internet2.html?eid=3
Redirect permanent /sb/sb.cgi http://prius.cc/d/20040415_bokobokoboko.html?eid=2
Redirect permanent /sb/sb.cgi http://prius.cc/d/20040414_torakkubakkuyattemimashita.html?eid=1
Redirect permanent /sb/sb.cgi http://prius.cc/d/20040412_akuachitannekku_fuaiten.html?eid=0
</pre></p>
				
				<h3>対処方法</h3>
				
				<p>まずこういう.htaccessを作ります。</p>
				
				<p><pre>
DirectoryIndex sb.cgi
RewriteEngine on
RewriteBase /sb
RewriteRule sb&#46;cgi http://prius.cc/d/temp/ [R=301,L]
RewriteRule log\/index&#46;rdf http://prius.cc/d/feed/ [R=301,L]
RewriteRule log\/atom&#46;xml http://prius.cc/d/feed/ [R=301,L]
</pre></p>
				
				<p>これで「http://prius.sakura.ne.jp/sb/sb.cgi?eid=858」へのアクセスは、「http://prius.cc/d/temp/?eid=858」へのアクセスになります。なお、最後の2行でRSSのリダイレクトを行っています。RSSはファイルへのアクセスなのでこれでリダイレクト完了です。</p>
				
				<p>※Redirect parmanentでもできるかもしれませんが、僕がやった時は上手くいきませんでした。RewriteRuleBase、RewriteRuleについては、以下のURLを参考にしてください。</p>
				
				<ul>
				<li><a href="http://q.hatena.ne.jp/1122115909">mod_rewriteを用いて「http://www.hoge.jp/index.php?abc=XXXXXX」を「http://www.hoge.jp/abc/XXXXXX.html」に変換したいのですが、以下のように行うと404エラーとなりま.. &#8211; 人力検索はてな</a></li>
				<li><a href="http://blogn.3co.jp/tip_seo_html.php#sakura_alias">Blogn（ぶろぐん）を静的生成なブログにする方法 &#8211; ブログンサポート</a></li>
				<li><a href="http://nai.homelinux.net/apache_rewrite.html">Kung Noi:rewriteモジュールでURLを書き換えろ！</a></li>
				<li><a href="http://tech.bayashi.net/svr/doc/apache/mod_rewrite.html">mod_rewrite</a></li>
				<li><a href="http://webtech.akijapan.com/htaccess/rewrite.phtml">.htaccess &#8211; Rewrite</a></li>
				</ul>
				
				<h3>meta refreshを使う</h3>
				
				<p>では「http://prius.cc/d/temp/?eid=858」へのアクセスを「http://prius.cc/d/20090312_heisei20nembunnokakuteishinkok.html」に飛ばしてやれば良い。これにはmeta refreshを使います。</p>
				
				<p><a href="http://www.suzukikenichi.com/blog/alternative-to-301-redirect/">301リダイレクトが使えないときの転送方法 ≫ 海外SEO情報ブログ・メルマガ</a></p>
				
				<p>具体的には「http://prius.cc/d/temp/?eid=858」にアクセスがあると以下のようなHTMLを出力するようなcgiを作ります。</p>
				
				<p><pre class="brush: xml; title: ;">
&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.1//EN&quot; &quot;http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd&quot;&gt;
&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; xml:lang=&quot;ja&quot;&gt;
&lt;head&gt;&lt;/p&gt;

&lt;script src=&quot;http://www.google-analytics.com/urchin.js&quot; type=&quot;text/javascript&quot;&gt;
&lt;/script&gt;

&lt;script type=&quot;text/javascript&quot;&gt;
_uacct = &quot;UA-72342-1&quot;;
urchinTracker();
&lt;/script&gt;

&lt;p&gt;&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=UTF-8&quot; /&gt;
&lt;meta http-equiv=&quot;Content-Script-Type&quot; content=&quot;text/javascript&quot; /&gt;
&lt;meta http-equiv=&quot;Content-Style-Type&quot; content=&quot;text/css&quot; /&gt;
&lt;meta HTTP-EQUIV=&quot;Refresh&quot; CONTENT=&quot;0; URL=http://prius.cc/d/20090312_heisei20nembunnokakuteishinkok.html&quot;&gt;
&lt;title&gt;index.html&lt;/title&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;/html&gt;
</pre></p>
				
				<p>…これはまぁ、実際のファイルをダウンロードして見て見て下さい。個別エントリ・プロフィール・カテゴリ・年月へのアクセスを、新URLに飛ばしています。プログラムを知らない人でも雰囲気はつかめると思います。</p>
				
				<p>cgiファイルのダウンロードは<a href='http://prius.cc/d/wp-content/uploads/2009/03/indexcgi.txt'>こちら。</a></p>
				
				<p>以上でリダイレクトの説明は終わりです。</p>
				
				<p>次→<a href="http://prius.cc/d/20090322_sb_wordpress_switch7.html">実際の移行レポートとその後</a></p>
]]></content:encoded>
			<wfw:commentRss>http://prius.cc/d/20090322_sb_wordpress_switch6html.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://prius.cc/d/20090322_sb_wordpress_switch6html.html" />
	</item>
		<item>
		<title>WordPressにSereneBachからエクスポートしたデータをインポート</title>
		<link>http://prius.cc/d/20090322_sb_wordpress_switch5html.html</link>
		<comments>http://prius.cc/d/20090322_sb_wordpress_switch5html.html#comments</comments>
		<pubDate>Sun, 22 Mar 2009 13:30:47 +0000</pubDate>
		<dc:creator>tera</dc:creator>
				<category><![CDATA[BlogやSNS]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://prius.cc/d/?p=1369</guid>
		<description><![CDATA[				目次
				
				
				旧ブログのアクセスを引き継ぎつつ、個別記事ページを生成していないSereneBach(sb)からWordPressへ移行する方法(このエントリ)
				新ブログのパーマリンク作 [...]]]></description>
			<content:encoded><![CDATA[				<h3>目次</h3>
				
				<ol>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch1.html">旧ブログのアクセスを引き継ぎつつ、個別記事ページを生成していないSereneBach(sb)からWordPressへ移行する方法</a>(このエントリ)</li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch2.html">新ブログのパーマリンク作成(投稿名ベース)</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch3.html">旧ブログ→新ブログへのパーマリンク対応作成</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch4.html">SereneBachからエクスポートしたデータを編集</a></li>
				<li>WordPressにSereneBachからエクスポートしたデータをインポート←今ここ</li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch6.html">旧ブログ(sb)→新ブログ(WordPress)へのリダイレクト設定</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch7.html">実際の移行レポートとその後</a></li>
				</ol>
				
				<hr />
				
				<p>エクスポートしたデータの編集が終わったので、インポート→postnameの編集を行います。</p>
				
				<h3>インポート！</h3>
				
				<p>WPの管理画面から「インポート」→「Movable Type もしくは Typepad のインポート」を選択し、編集したテキストを指定してアップロードします。</p>
				
				<h3>WP側の個別ファイル名(postname)リネーム</h3>
				
				<p><a href="http://www.ideaxidea.com/archives/2008/12/movabletypewordpress.html">固定リンクを変えずにスムーズにMovableTypeからWordPressに移行するまでの作業ログ &#8211; IDEA*IDEA ～ 百式管理人のライフハックブログ ～</a>の「マッピング用のSQLを作る」を参考に、post_nameの変更を行います。</p>
				
				<p>なお仮にインポートに失敗しても、SQLから以下の5つのテーブルを消せば元に戻ってやりなおせます。</p>
				
				<ul>
				<li>wp_comments</li>
				<li>wp_posts</li>
				<li>wp_terms</li>
				<li>wp_term_relationships</li>
				<li>wp_term_taxonomy</li>
				</ul>
				
				<h3>トラックバックを許可する(SQL使用)</h3>
				
				<p>※これはお好みで。</p>
				
				<p><a href="http://wordpress.bowz.info/47">[ WordPress ] 過去ログのトラックバック・コメントを一括で許可する方法 &#8211; WordPress 研究室</a>を参考に、全てのエントリのトラックバック設定をONにします。</p>
				
				<p>次→<a href="http://prius.cc/d/20090322_sb_wordpress_switch6.html">旧ブログ(sb)→新ブログ(WordPress)へのリダイレクト設定</a></p>
]]></content:encoded>
			<wfw:commentRss>http://prius.cc/d/20090322_sb_wordpress_switch5html.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://prius.cc/d/20090322_sb_wordpress_switch5html.html" />
	</item>
		<item>
		<title>SereneBachからエクスポートしたデータを編集</title>
		<link>http://prius.cc/d/20090322_sb_wordpress_switch4html.html</link>
		<comments>http://prius.cc/d/20090322_sb_wordpress_switch4html.html#comments</comments>
		<pubDate>Sun, 22 Mar 2009 13:29:59 +0000</pubDate>
		<dc:creator>tera</dc:creator>
				<category><![CDATA[BlogやSNS]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://prius.cc/d/?p=1367</guid>
		<description><![CDATA[				目次
				
				
				旧ブログのアクセスを引き継ぎつつ、個別記事ページを生成していないSereneBach(sb)からWordPressへ移行する方法(このエントリ)
				新ブログのパーマリンク作 [...]]]></description>
			<content:encoded><![CDATA[				<h3>目次</h3>
				
				<ol>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch1.html">旧ブログのアクセスを引き継ぎつつ、個別記事ページを生成していないSereneBach(sb)からWordPressへ移行する方法</a>(このエントリ)</li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch2.html">新ブログのパーマリンク作成(投稿名ベース)</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch3.html">旧ブログ→新ブログへのパーマリンク対応作成</a></li>
				<li>SereneBachからエクスポートしたデータを編集←今ここ</li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch5.html">WordPressにSereneBachからエクスポートしたデータをインポート</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch6.html">旧ブログ(sb)→新ブログ(WordPress)へのリダイレクト設定</a></li>
				<li><a href="http://prius.cc/d/20090322_sb_wordpress_switch7.html">実際の移行レポートとその後</a></li>
				</ol>
				
				<hr />
				
				<p>※後々旧ブログのURLは全て新ブログにリダイレクトされるので、この作業は必須ではありません。面倒な人は飛ばして次の項目へどうぞ。</p>
				
				<p>旧ブログのエントリー中で、自ブログのエントリにリンクを張ってたりTOPページにリンクを張ってたりするのを置き換えます。なお置き換えする場合は1→2→3の順番を守って置き換えてください。</p>
				
				<p>1.エントリ中のsbへのリンクリネーム</p>
				
				<p><a href="http://www.vector.co.jp/soft/win95/util/se142895.html">Speeeeed</a>というソフトを使って置換します。Speeeeedには置換リストと言う定義ファイルを利用して、多→多の置換が可能です。Speeeeedをダウンロードしたフォルダにreplace.lstというファイルを作成し、タブ区切りで置換前の文字列、置換後の文字列と記載します。
				<pre>
http://prius.sakura.ne.jp/sb/sb.cgi?eid=858  http://prius.cc/d/20090312_heisei20nembunnokakuteishinkok.html
</pre></p>
				
				<p>注意点は<strong>置き換えリスト(replace.lst)にはeidの大きい順に書いていく事。</strong>上から順に照合していくので、最初にeid=1と書いたらeid=10やeid=123にも一致しておかしく変換されてしまいます。</p>
				
				<p>2.画像パスのリネーム</p>
				
				<p>画像の保存場所を変更する場合はリンクを変更します。僕の場合は</p>
				
				<pre><code>置換前：http://prius.sakura.ne.jp/sb/img
置換後：http://prius.cc/d/wp-content/sb-img
</code></pre>
				
				<p>としました。</p>
				
				<p>3.TOPへのURLリネーム</p>
				
				<p>最後に旧ブログのTOPページのURLを新ブログのURLに置き換えます。テキストエディタでエクスポートしたデータを開いて</p>
				
				<pre><code>置換前：http://prius.sakura.ne.jp/sb/
置換後：http://prius.cc/d/
</code></pre>
				
				<p>でOK。</p>
				
				<h3>余談：ここで問題発生！</h3>
				
				<p>僕固有の問題かもしれませんが、この後WordPressにインポートしたら続きエリアに文章を書いてないエントリにも「続きを読む」が表示されちゃってました。これはSereneBachからエクスポートしたデータのEXTENDED BODYエリアに</p>
				
				<pre><code>&lt;ul class="footnote"&gt;
</code></pre>
				
				<p>という文字列が入っていたのが原因でした。よって以下の条件で置換を行い、EXTENDED BODYに</p>
				
				<pre><code>&lt;ul class="footnote"&gt;
</code></pre>
				
				<p>しか書かれてないものを消去しました。</p>
				
				<pre><code>置換前：^&lt;ul class="footnote"&gt;
置換後：
</code></pre>
				
				<p>次→<a href="http://prius.cc/d/20090322_sb_wordpress_switch5.html">WordPressにSereneBachからエクスポートしたデータをインポート</a></p>
]]></content:encoded>
			<wfw:commentRss>http://prius.cc/d/20090322_sb_wordpress_switch4html.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://prius.cc/d/20090322_sb_wordpress_switch4html.html" />
	</item>
	</channel>
</rss>

