This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

website without www is 404
#2
RE: website without www is 404
It can have multiple causes, are you using any particular software on your website (like wordpress, joomla, etc)? Sometimes they change the .htaccess and might cause issues.

Quick Fix for .htaccess:
Try adding this to the .httaccess file (however this is probably NOT what you should fix, read below):
Code:
RewriteEngine on
RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]

Probably your issue is related to the DNS  or VHOSTS  setup, please check the following:
DNS Setup:
  1. You have a A Record entry for yourdomain.com and for www.yourdomain.com.
  2. Both entries are using the same IP Address (either IPv4 and/or IPv6 if applicable).
NOTE: Your DNS setup might be using Sentora Bind9, CloudFlare, Your Registar or your Hosting Provider, it only needs to be changed on ONE of those places, it's up to you do know witch one you are using.

V-HOSTS Setup:
You should have something like this on your V-HOSTS file for yourdomain.com
Code:
<VirtualHost *>
 ServerName www.yourdomain.com
 ServerAlias yourdomain.com
</VirtualHost>
What you need to check is the ServerAlias directive, the rest is here only for reference.
Please note that your VirtualHost may differ a LOT from the above example (usually it has much more lines).

Hope this helps you.
My Sentora Resources
[Module] Mail Quota Count | Vagrant Box with Sentora

[Image: vanguardly-logo-micro.png]
Graphic and Web Design. Development.
www.vanguardly.com


Reply
Thanks given by:


Messages In This Thread
website without www is 404 - by adamhk0 - 03-30-2015, 06:01 PM
RE: website without www is 404 - by apinto - 03-30-2015, 08:01 PM
RE: website without www is 404 - by adamhk0 - 03-31-2015, 04:44 AM
RE: website without www is 404 - by apinto - 03-31-2015, 06:59 AM
RE: website without www is 404 - by adamhk0 - 03-31-2015, 01:34 PM
RE: website without www is 404 - by adamhk0 - 04-01-2015, 12:10 PM
RE: website without www is 404 - by apinto - 04-01-2015, 06:01 PM
RE: website without www is 404 - by adamhk0 - 04-02-2015, 07:31 AM
RE: website without www is 404 - by TGates - 04-02-2015, 11:27 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
Split Website log files. spoonman 1 3 ,424 01-01-2022, 10:00 AM
Last Post: TGates
Uploaded Website Not Updating GiantEspresso 3 7 ,086 04-19-2020, 09:57 PM
Last Post: Ron-e
The website don't load naire 1 4 ,672 10-15-2019, 11:48 PM
Last Post: jamesmango

Forum Jump:


Users browsing this thread: 3 Guest(s)