Report this

What is the reason for this report?

Non www domain name resolves to www intermittently

Posted on November 26, 2013

My site is www.recipehearth.com, the domain name with the “www” resolves fine every time. If you type in only: recipehearth.com , it will either take you to a blank screen or occasionally it will resolve correctly to http://www.recipehearth.com as it is supposed to.

The fact that the domain recipehearth.com does not resolve correctly to www.recipehearth.com every time is what my problem is.

<strong>Setup:</strong> WordPress 3.7.1 LAMP stack (Ubuntu 12.10)

<strong>What I’ve done so far:</strong> -Activated htaccess in Apache (https://www.digitalocean.com/community/articles/how-to-use-the-htaccess-file) -Reviewed my htaccess file and made sure I am using the standard configuration. <pre># BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule>

END WordPress</pre>

<strong>Not sure if this matters:</strong> -If you tell it to go to a page/or login such as recipehearth.com/blueberry-sorbet-macarons/ it will go with no issues, even though the www is not in the address. -My site is not located in /var/www it is in /home/wordpress/public_html

Any thoughts or ideas on what this could be are appreciated!



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Check out <a href=“https://www.digitalocean.com/community/articles/one-click-install-wordpress-on-ubuntu-12-10-with-digitalocean”>One-Click Install WordPress on Ubuntu 12.10 with DigitalOcean</a>.

Yes, I’ve seen that tutorial. The only item that was of help in it was regarding the apache configuration file in /etc/apache2/sites-enabled/www.recipehearth.com. I made two changes; 1)Servername www.recipehearth.com 2) ServerAlias recipehearth.com (oddly recipehearth.com was resolving just fine shortly after making the adjustment to this file, now it is back to being intermittent) <br> <br>Was there something else you were trying to point out?

The htaccess file also contains “IfModule mod_rewrite.c” before “RewriteEngine On” and “/IfModule” before “# END WordPress”. It disappeared above when I posted the question, but it is in the server file.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.