Creating a Page Redirection

Creating a page redirect is very simple, that is if you know how! Follow these steps for an accurate Page Redirection. There are two different formats and both will be exampled below.

The first Redirection is the HomePage Redirection. It looks like this:

# Redirect direct HP and Domain access to an HTTPS/SSL name

RewriteCond %{HTTP_HOST} ^$ [OR]

RewriteCond %{HTTP_HOST} ^$

RewriteRule ^/?$ [R=301,L]

RewriteRule ^$ [R=301,L]

Note: Make sure you place this code after the Expiration header.

The next is a simple Page Redirect. This is used to relocate a page from one location to another using the domain's URL. It looks like this:

# Create a page Redirect [Permanent Redirect]

RewriteRule ^about$ /home.php [R=301,L]

# Create a page Redirect [Temporary Redirect]

RewriteRule ^about$ /home.html [R=302,L]

When creating a Redirection link it is important to note that R=301 indicates a PERMANENT Redirection

and that R=302 indicates a TEMPORARY redirection. It Is important to note that you MUST indicate one of these two in the fields between two brackets”[ ]” in order for the redirection to take place. You must also follow the R=30x code with a “,L” in order to tell the server that this is a Link.

Converted from CHM to HTML with chm2web Standard 2.85 (unicode)