Welcome Guest, Not a member yet? Register   Sign In
Site Breaks Without "WWW"

Just completed a site for a client and discovered that if you enter the site without the "www" in the url it breaks. You'll get this message:
Quote:An Error Was Encountered
Unable to connect to your database server using the provided settings.

It works fine if you add the "www". Why would this be happening??

Here is the site in question: http://fluentcollab.org/fluent/

[eluser]Tom Glover[/eluser]
This is down to the host not rooting the non www site correctly. To work around this you will need to redirect all requests to the www version through the .htaccess.



# permanently redirect from non-www domain to www domain
RewriteEngine on
Options +FollowSymLinks
RewriteCond %{HTTP_HOST} ^domain\.tld$ [NC]
RewriteRule ^(.*)$ http://www.domain.tld/$1 [R=301,L]

Awesome. I'll give it a shot. Thanks!

Worked like a charm. Thank you.

[eluser]Tom Glover[/eluser]
No Problem, We offer Hosting with out these issues, but I'm glad it worked for you.

Theme © iAndrew 2016 - Forum software by © MyBB