htaccess 301 redirect – v quick Q

Hi all

I have not done a redirect using htacces/301 ahead of. So i just planned to check with people here before post implement this, as the htaccess file already has some stuff inside. So, could any person tell me quickly, is this correct (The bit concerning added is for individual page redirects, and also starts after " # FINISH WordPress" )

Code:
RewriteEngine With
RewriteCond %HTTP_HOST! www\. mysitename\. corp. uk$
RewriteRule (. *) http: //www. mysitename. corp. uk/$1 R=301, L
# GET STARTED WordPress
< IfModule mod_rewrite. c>
RewriteEngine With
RewriteBase /
RewriteCond %REQUEST_FILENAME! -f
RewriteCond %REQUEST_FILENAME! -d
RewriteRule. /index. php L
< /IfModule>

# FINISH WordPress

Redirect 301 /uk-female-rock-exclusive-mp3s-contact. html document http: //www. mysitename. corp. uk/

Redirect 301 /uk-female-rock-exclusive-mp3s-music. html document http: //www. thebestmusicshop. corp. uk/mp3-download/1/mysitename/intc. html

Direct 301 /uk-female-rock-exclusive-mp3s-shop. html document http: //www. thebestmusicshop. corp. uk/mp3-download/1/mysitename/intc. html

Direct 301 /uk-female-rock-exclusive-mp3s-thankyou. html document http: //www. mysitename. corp. uk/

Redirect 301 /uk-female-rock-exclusive-mp3s-video. html document http: //www. mysitename. corp. uk/the-indie-rock-bands-home/music-videos/

Redirect 301 /absolutely-free-music-downloads. html document http: //www. mysitename. corp. uk/best-rock-music-free-downloads/

Redirect 301 /uk-female-rock-exclusive-mp3s-biography. html document http: //www. mysitename. corp. uk/the-indie-rock-bands-home/female-rock-singers-bio/

Redirect 301 /uk-female-rock-exclusive-mp3s-contact. html document http: //www. mysitename. corp. uk/

Truly never seen of which before….

Began seeing I’ve always seen it truly is:

Code:
RewriteRule /uk-female-rock-exclusive-mp3s-contact. html document http: //www. mysitename. corp. uk/ L, R=301

Anyway, you should do if you can , to get this old URL pointing towards new URL with the same resource (if the item still exists). Usually, you’ll get disciplined by Google.

Hm okay thankyou Steve.. i found that way of writing it in my instance here:

http: //www. ndesign-studio. com/blog/301-htaccess-redirect
and also here
http: //www. tamingthebeast. net/articles3/spiders-301-redirect. htm

Is this not the way to write it

Okay – totally realize, is there another way to get this done then alongside 301 redirect Each page around my 301 refocus will redirect to its corresponding new page, eg – it is a old music page, redirecting to the new music page:

Can there be more i is able to do

No, that’s in what way you should do it.. Regarding " Direct 301" – I am just not saying it can be wrong, just telling I’ve never found it before. There’s usually multiple way to do things in coding.; -)

also cool thanks *gives a few rep before she’s spread it all over again*

Redirect 301 may be faster if you’re redirecting one unique page to a further, because RewriteRules in general invoke the overhead of your regex engine, as opposed to the more basic Redirect command. But the regex overhead for something that isn’t really a regex isn’t planning to be big, hence whatever.

REVISE: When I express faster’, of program, I mean around relative terms. These are both blazing speedy.

Thanks with the insight Shadowfiend, always good to know the real reason for these things.

This entry was posted in Web Design and tagged , , , , , , , , , , , , , , , , , , , . Bookmark the permalink.

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *