Shopping Cart Forum

Go Back   eShop Forums - eCommerce Help Forum for Shopping Cart Owners. > Tech Corner > PHP/MySQL ASP.net and other server side technologies
Register Blogs FAQ Members List Calendar Search Today's Posts Mark Forums Read
PHP/MySQL ASP.net and other server side technologies Everything to do with the programming of websites. Discuss what goes on under the bonnet of your ecart or just chat about programming in general.

Pen n Paper, click here
Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 29-09-2007, 12:37 AM
Lawrence Lawrence is offline
Forum Admin
 
Join Date: Aug 2007
Location: Kenley, Surrey, UK
Posts: 1,154
Thanks: 0
Thanked 69 Times in 69 Posts
Default How to perform a HTTP 301 redirect in PHP (Search engine friendly)

A 301 redirect is the most efficient and search engine friendly method for webpage redirection. It will preserve your search engine ranking for that particular page. If you change file names, file locations or even change your domain name it is the safest way to redirect the page while preserving it's pagerank. The code "301" means "moved permanently". If you have a domain that is no longer required with ranked pages then you can use this method to point those pages with rank to pages of another domain.

This is how you do it.

PHP Code:
<?php
header
("HTTP/1.1 301 Moved Permanently");
header("Location: http://www.eshopforums.com/");
exit();
?>
You can change "www.eshopforums.com/" to the domain or page of your choice, though you are welcome to leave it as it is
__________________
Lawrence
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
What would you search for? Lawrence SEO and PPC 5 31-08-2007 06:44 AM
How to do a page redirect using HTML meta tags. Lawrence HTML/XHTML CSS & JavaScript 2 26-08-2007 11:20 AM
Inside Magento #7 - Product Search Magento News from Magento 0 21-08-2007 03:16 AM

Google

Edible Graphics, Affordable E-Commerce, Web Shops & Custom Form Scripts
Fair Trade Quality Handmade Photo Albums & Gifts
tech news, product reviews, the latest home and business technology, the latest in digital imaging


Content Relevant URLs by vBSEO 3.0.0