Localhost or the internet: where a site lives
When you build a site, you test each page before anyone else sees it. The first way to publish is local: your own computer runs a web server program, and you open the page at an address that starts with localhost. The word localhost always means “this same computer”, so a visitor typing it reaches his own machine, not yours. Other computers can reach yours only through its own network address, and only while it is switched on, so localhost is meant for testing. The second way is hosting. A hosting company keeps your files on its web server, which is always on, and visitors anywhere reach the site through its URL, the Uniform Resource Locator, for example www.nile-club.example. Some hosts are paid and some are free. This term’s project stays on localhost; to go public you would upload the finished files to a host, with a teacher’s help.
| localhost | hosting | |
|---|---|---|
| Who can see the site? | only this computer (testing) | any visitor with the URL |
| Is it always on? | only while the computer runs | yes, a host keeps it on |
| Cost | none | paid or free hosts |
| Use | build and test | publish for the public |
| Situation | Best choice | Why |
|---|---|---|
| (a) page still being written | localhost | only you need it |
| (b) news for the whole school | hosting | always on, open to everyone |
| (c) practice project | localhost | no cost, nobody else needs it |
Write the plan for the club site on two lines: where you will test it, and where you would publish it. Give one reason for each choice and say what the visitor types to open it.