Joomla!, Wordpress tips for building your site

After moving 301 redirects

Published on| November 21st, 2009 | No Comment.

If you change domain of your site, you should redirect from old domain to new domain with 301 error.

Why do we need a 301 redirect?

It is needed so that Search Robots know that your site domain changed.
Search Engine’s index of your site will be smooth changed from old url to new url by 301 error.
If you do not notify Search engine that your site changed domain, Search engine will know that your new domain is new site. And Search Engine’s indexes of your old domain will be erased.

How to set up 301 redirects

It's easy.
If you can use .htaccess file, you will write as follows.

Options +FollowSymLinks
RewriteEngine on
RewriteRule (.*) http://www.hikkoshi.com/$1 [R=301,L] 

If your server do not support Mod-Rewrite, you will write as follows.

Redirect 301 /hikkoshi/ http://www.hikkoshi.com/

This example means that redirects from ‘hikkoshi’ directory of old domain to new domain(‘www.hikkoshi.com’).
Also, you will be able to write as follows too for 301 error.

Redirect permanent /hikkoshi/ http://www.hikkoshi.com/

If you want write with PHP, you will be able to write as follows.

<?php
header( "HTTP/1.1 301 Moved Permanently" );
header( "Status: 301 Moved Permanently" );
header( "Location: http://www.hikkoshi.com/" );
exit(0);
?>


How to check 301 redirects

If you finish the setting for redirect, you will be able to check that setting for redirect of your site correct by http://web-sniffer.net/.

301

If you see following message, your site will be set correct.
HTTP Status Code: HTTP/1.1 301 Moved Permanently


You should keep this settings for 3 weeks or more long, because it is need at least 2 weeks when Search Engine re-index.






Comments

Leave a Reply








Transrator

Recent Posts

Categories

Tag Cloud

execute remove フロントページ 投稿ページ トップページ install WIndows Note Convert META generator 日付 donwload file manage multibyte utf-8 unicode shiftjis euc console サイトマップ 問題 ParmaLink Redirect パーマリンク はみ出る pre テンプレート テーマ タグクラウド マルチランゲージ リダイレクト PHP(タグ) タグ table control HTML(タグ) コマンド 国際化(翻訳) SQLite(タグ) MySQL(タグ) qTranslate プラグイン(タグ) Wordpress(タグ)

Links

Site Description

Joomla!, Wordpress as CMS using a site building, site management, software usage to describe the development tips.

  • はてなブックマークへ追加する
  • Facebookでシェアする
  • twitter でつぶやく
  • Google Plusでシェアする
  • Pocketでシェアする
ページトップへ