I acquired a domain. When I try accessing it a message comes up
telling me I must have and index file.
What is that?
Cannot I access mydomain.com without making a mydomain.com/index.html
page?
I want people to be able to simply enter mydomain.com and go to it,
not have to type mydomain.com/index.html.
What is it I'm not understanding?
I found an answer. (I finally put the right keywords into Google.)
Here's the URL I found it at:
http://webdesign.about.com/od/beginningtutorials/f/index_html.htm
Every website is built inside directories on a Web server. And each
Web page is a separate file on that Web server. But sometimes, when
you go to a URL, there is no file listed in the URL. For example:
http://webdesign.about.com/
But there is still a file that the Web server needs to serve in order
for that URL to display anything other than an error page. This file
is the default page for that directory. On most Web servers, the
default page in a directory is named "index.html".
What this means is that when you go to a URL without a file named at
the end, the server looks for a default file and displays that
automatically. Just as if you had typed in that file name in the URL:
http://webdesign.about.com/index.htm
There are Three Default Page Names
There are three commonly used default page names that you can use on
most Web servers:
* index.html
* index.htm
* default.htm (on some Windows servers)
It's a good idea to stick with index.html or index.htm on most
servers, as default.htm is most often used on Windows servers, and
isn't as common as it used to be.
You Should Have an index.html Page in All Your Directories
Whenever you have a directory on your website you should have an
index.html page. This allows your readers to see a page when they come
to that directory without typing a file name in the URL. It also
prevents them from seeing things you might not want them to see.
If you don't put in an index.html file in a directory, most Web
servers will display a file listing of all the files in that
directory. While in some situations, you might want that, most of the
time this is ugly at best and a security hole at worst. Writing a
default Web page and naming it index.html helps solve those problems.
Your Homepage Should be an index.html Page
When you start building your website, you should create your main page
and name it index.html. This is true whether you're using a free
hosting service or you have your own domain name. That way, when
people come to your URL, they automatically get your main page. All
other pages will have names like "about.html" or "contact.html", but
your home page should file should be called "index.html".
Learn HTML and Web Design
Every website is built inside directories on a Web server. And each
Web page is a separate file on that Web server. But sometimes, when
you go to a URL, there is no file listed in the URL. For example:
http://webdesign.about.com/
But there is still a file that the Web server needs to serve in order
for that URL to display anything other than an error page. This file
is the default page for that directory. On most Web servers, the
default page in a directory is named "index.html".
What this means is that when you go to a URL without a file named at
the end, the server looks for a default file and displays that
automatically. Just as if you had typed in that file name in the URL:
http://webdesign.about.com/index.htm
There are Three Default Page Names
There are three commonly used default page names that you can use on
most Web servers:
* index.html
* index.htm
* default.htm (on some Windows servers)
It's a good idea to stick with index.html or index.htm on most
servers, as default.htm is most often used on Windows servers, and
isn't as common as it used to be.
You Should Have an index.html Page in All Your Directories
Whenever you have a directory on your website you should have an
index.html page. This allows your readers to see a page when they come
to that directory without typing a file name in the URL. It also
prevents them from seeing things you might not want them to see.
If you don't put in an index.html file in a directory, most Web
servers will display a file listing of all the files in that
directory. While in some situations, you might want that, most of the
time this is ugly at best and a security hole at worst. Writing a
default Web page and naming it index.html helps solve those problems.
Your Homepage Should be an index.html Page
When you start building your website, you should create your main page
and name it index.html. This is true whether you're using a free
hosting service or you have your own domain name. That way, when
people come to your URL, they automatically get your main page. All
other pages will have names like "about.html" or "contact.html", but
your home page should file should be called "index.html".
Learn HTML and Web Design