This Forum has been archived there is no more new posts or threads ... use this link to report any abusive content
==> Report abusive content in this page <==
Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Difference between 301 re-direct and cononicalisation?
04-08-2014, 06:46 PM
Post: #1
Difference between 301 re-direct and cononicalisation?

Ads

Find all posts by this user
Quote this message in a reply
04-08-2014, 06:49 PM
Post: #2
 
301 redirect:
301 redirect is Move the old url permanently to another URL.

For example http://www.cricinfo.com header.

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

Cononicalization:
Google has mistaken and seems, given websites are three individual webpages.
http://www.website.com
http://website.com
http://www.website.com/index.php
These three urls are same and have same content, Google hate duplicate content. Consequently, the google mistakenly penalize the website. To prevent this problem most of the webmaster add given script in the .htaccess.

RewriteEngine on
RewriteCond %(HTTP_HOST) ^website.com
RewriteRule (.*) http://www.website.com/$1 [R=301,L]
RewriteCond %(THE_REQUEST) ^[A-Z] {3,9}\ /.*index\.php\ HTTP/
RewriteRule (.*) index\.php$ /$1 [R=301,L]

In the canonicalization, we use 301 rule.

Ads

Find all posts by this user
Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)