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
    Regular Coder
    Join Date
    May 2011
    Location
    new york
    Posts
    104
    Thanks
    4
    Thanked 0 Times in 0 Posts

    redirecting www to http (for a subdomain)

    could someone help me with finding a way to redirect www requests to the http version of the webpage for a website that is on a subdomain?

    for example

    www.yee.haw.com --> http://yee.haw.com


    I'm trying this in the htaccess:


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


    but it does not seem to be working, is there something I am doing wrong?

  • #2
    Regular Coder
    Join Date
    May 2011
    Location
    new york
    Posts
    104
    Thanks
    4
    Thanked 0 Times in 0 Posts
    Is it possible that the www is pointing to another directory altogether?

    When I go to http://web.site.com i see the page

    but when i go to www.web.site.com I see a stock apache configuration page. Perhaps this is the reason why the above redirect is not functioning properly ?


  •  

    Posting Permissions

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