Michael,

I have done this type of thing many times but not using the web server 
machinery but instead using DNS. Most major DNS providers support 301 
redirection in some form (it will usually have some type of proprietary 
branding). I have found that when I want to redirect an entire domain that it 
is usually more efficient to use DNS to perform the redirect rather than make 
my web server and/or ColdFusion have to handle the request . Of course, this 
will depend on your level of access to the domain’s DNS zone in the first place.

I realize that isn’t necessarily what you asked but I just thought I’d throw it 
out there as an idea for you.

Thank you,

Troy Jones
Technical Manager
Third Wave Digital
1841 Hardeman Ave.
Macon, GA 31201
t...@thirdwavedigital.com<mailto:t...@thirdwavedigital.com>
www.thirdwavedigital.com<http://www.thirdwavedigital.com>

From: ad...@acfug.org [mailto:ad...@acfug.org] On Behalf Of Cameron Childress
Sent: Monday, February 09, 2015 1:35 PM
To: discussion@acfug.org
Subject: Re: [ACFUG Discuss] htaccess dilemma

I just saw this list and thought about your question. Might be helpful.

It's "A collection of useful .htaccess snippets, all in one place. I decided to 
create this repo after getting so tired (and bored) with Googling everytime 
there's a need of forcing www for my new website."

https://github.com/phanan/htaccess#force-https

-Cameron

On Thu, Feb 5, 2015 at 9:30 PM, Michael Brown 
<singleconce...@gmail.com<mailto:singleconce...@gmail.com>> wrote:
Good Evening,

I recently created site the requires a 301 redirect.  I would like to redirect 
all files with https://www.oldsite.com/*.* to https://secure.newsite.com.  
Currently using the following in the htaccess however it's not redirecting.  
Any suggestions?

RewriteEngine on
RewriteCond %{HTTP_HOST} !^secure\.newsite\.com [NC]
RewriteCond %{HTTP_HOST} ^oldsite\.com [NC,OR]
RewriteCond %{HTTP_HOST} ^www\.oldsite\.com [NC]
RewriteRule ^(.*)$ https://secure.newsite.com/$1 [R=301,L]

Thanks in advance for your help.

--
Michael Brown

"Do a Common Thing Uncommonly Well"

Direct Line - 770-605-5240<tel:770-605-5240>

[http://singleconcepts.com/images/logo4links.png]

We Get Your Business Moving
http://www.techillo.com

[https://d2q0qd5iz04n9u.cloudfront.net/_ssl/proxy.php/http/www.linkedin.com/img/webpromo/btn_viewmy_160x25.png]<http://www.linkedin.com/in/hotdeals>

Twitter: http://www.twitter.com/singleconcepts


Skype ID: "hotdealer"





--
Cameron Childress
--
p:   678.637.5072
im: cameroncf
facebook<http://www.facebook.com/cameroncf> | 
twitter<http://twitter.com/cameronc> | 
google+<https://profiles.google.com/u/0/117829379451708140985>

Reply via email to