<?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/"
	>

<channel>
	<title>delab &#187; .htaccess</title>
	<atom:link href="http://de-lab.com/tag/htaccess/feed/" rel="self" type="application/rss+xml" />
	<link>http://de-lab.com</link>
	<description>xhtml CSS SEO CMS PHP など Webデザイン WEBサイト構築の話題</description>
	<lastBuildDate>Wed, 05 Oct 2011 23:41:33 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>SEO的に正しいリダイレクトでURL変更 &#8211; リニューアル覚書</title>
		<link>http://de-lab.com/article/seo-url-redirect/</link>
		<comments>http://de-lab.com/article/seo-url-redirect/#comments</comments>
		<pubDate>Thu, 15 May 2008 18:03:34 +0000</pubDate>
		<dc:creator>sato</dc:creator>
				<category><![CDATA[Article]]></category>
		<category><![CDATA[.htaccess]]></category>
		<category><![CDATA[Renewal]]></category>
		<category><![CDATA[SEO]]></category>

		<guid isPermaLink="false">http://de-lab.com/?p=119</guid>
		<description><![CDATA[何も対策をせずに記事のURLが変更されると検索順位が下がったりSEO的な弊害がある場合がありますので.htaccessで、301リダイレクト(恒久的なURL移転)します。 対策なしでURL変更するとどのような弊害があるの [...]]]></description>
			<content:encoded><![CDATA[<div class="disc">
<p>何も対策をせずに記事のURLが変更されると検索順位が下がったりSEO的な弊害がある場合がありますので.htaccessで、301リダイレクト(恒久的なURL移転)します。</p>
</div>
<p><span id="more-119"></span></p>
<h2 id="toc-url">対策なしでURL変更するとどのような弊害があるのか</h2>
<h3 id="toc-">固定記事の検索順位が下がるかも</h3>
<p>外部からリンクをもらったり、SEO対策してページランクのあがったページも、URLが変更されれば違うページと認識され、ページランクがゼロに戻ります。</p>
<p>そうなると、今まで検索順位が上だったページもまた下の方になってしまう可能性大です。</p>
<h3 id="toc-1">外部リンクが外れる</h3>
<p>トラックバックなどの外部リンクやはてブでホットエントリになった(w 記事もリンクが外れてしまうので検索しないと記事が確認出来なくなります。</p>
<h2 id="toc-301urlurl">301リダイレクトで以前のURLから新しいURLへ転送</h2>
<p>301リダイレクトはHTTPステータスコードの1つであり、恒久的な移転を表します。</p>
<p>この方法は<strong>YahooやGoogleも推奨</strong>しています。タイトルに「SEO的に正しい」と書いたのはそのため。</p>
<ul class="external-link">
<li><a href="http://help.yahoo.co.jp/help/jp/search/indexing/indexing-08.html" title="Yahoo!検索 ヘルプ - サイトのURLを変えたので、検索結果のURLを修正したい" rel="nofollow" target="_blank" class="liexternal">Yahoo!検索 ヘルプ &#8211; サイトのURLを変えたので、検索結果のURLを修正したい</a></li>
<li><a href="http://www.google.co.jp/support/webmasters/bin/answer.py?answer=34444&#038;query=301&#038;topic=&#038;type=" title="検索結果に自分のサイトが表示されていないか、検索結果での掲載順位が以前よりも低くなっています。" rel="nofollow" target="_blank" class="liexternal">Google ウェブマスター向けヘルプ センター</a></li>
</ul>
<p>301リダイレクトすることにより、旧URLにアクセスしても自動的に新しいURLに転送されます。また、PageRankや検索順位なども一緒に移転されます。</p>
<h3 id="toc-htaccess">.htaccessの書き方</h3>
<pre><code>Redirect permanent /old/ http://de-lab.com/new/</code></pre>
<p>wordpressでは動的にページを生成しているので、メタタグを使ってのリダイレクトは適用外です。</p>
<p>既に.htaccessがルートフォルダに設置されてる場合は、<strong>個々の設定前、一番上</strong>に書きます。</p>
<h3 id="toc-2">コードサンプル</h3>
<p class="code">.htaccess</p>
<pre name="code" class="html">Redirect permanent /category/web http://de-lab.com/category/article
Redirect permanent /category/web/webtools http://de-lab.com/category/article
Redirect permanent /category/webdesign http://de-lab.com/category/article
Redirect permanent /category/webdesign/seo http://de-lab.com/category/article
</pre>
<p>旧：/category/web<br />
新：/category/article<br />
旧：/category/web/webtools<br />
新：/category/article</p>
<p>以前のURLと照らし合わせながら、全てのカテゴリを新しいURLに転送します。</p>
<p>作業が終わったら、.htaccessをルートにアップして、旧URLにアクセスして転送しているか確認します。</p>
<p>記述が間違っていると、URLにアクセスされずスクリプトエラーが出たり、検索エンジンから省かれた例もありますので(昔だけど)、確認に次ぐ確認で、慎重に。</p>
<img src="http://de-lab.com/?ak_action=api_record_view&id=119&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://de-lab.com/article/seo-url-redirect/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

