Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Mar 2007
    Posts
    92
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Redirect WWW to non WWW, for primary domain, and parked domain

    Hi guys,

    I already know basic Redirect www to non-www, using htaccess:

    RewriteEngine On
    RewriteCond %{HTTP_HOST} ^www.yourdomain.com [NC]
    RewriteRule ^(.*)$ http://yourdomain.com/$1 [L,R=301]





    but how if we have parked domain too?

    I already tried this but its not works, its says "The page isn't redirecting properly"

    RewriteEngine On
    RewriteCond %{HTTP_HOST} ^www.yourdomain.com [NC]
    RewriteRule ^(.*)$ http://yourdomain.com/$1 [L,R=301]
    RewriteCond %{HTTP_HOST} ^www.yourdomain2.com [NC]
    RewriteRule ^(.*)$ http://yourdomain2.com/$1 [L,R=301]




    please share your knowledge, what is the best way for this?
    Whats up

  • #2
    New to the CF scene
    Join Date
    Oct 2011
    Location
    Cedar Rapids, Iowa
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Do you have access to your Apache error log? It may shed some light on what is happening.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •