Have you ever seen such a thing: domain.com returns error but www.domain.com is ok. Example: 118.com www.118.com why is this?
Your server and htaccess file are probably not set up correctly. If you haven't created the htaccess yourself contact your host and ask them to sort it.
You should have a directory on your server called public_html. When your server is configured properly then this directory should mirror the www directory.