www.webdeveloper.com
Results 1 to 2 of 2

Thread: [RESOLVED] Remove www from URLS

Hybrid View

  1. #1
    Join Date
    Apr 2007
    Location
    RIT
    Posts
    6

    resolved [RESOLVED] Remove www from URLS

    I want to remove the www from the beginning of my URLS. My website is at http://www.nticompassinc.com

    http://www.nticompassinc.com/info.php works, but if I enter http://nticompassinc.com/info.php it redirects to http://www.nticompassinc.com

    Why does this happen?

    My DNS A (NAME) settings have @ and www both pointing to my webserver's IP.

    Here is my .htaccess file
    PHP Code:
    Options -Indexes

    RewriteEngine On
    RewriteBase 
    /

    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond 
    %{REQUEST_FILENAME} !-d
    RewriteRule 
    ^(.*)$ /index.php/$[L

  2. #2
    Join Date
    Feb 2009
    Posts
    3
    most likely happening in subdir
    just force it....

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

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles