19.4. Accessing Web Servers
To request documents from Web servers, users must know the URLs at which those documents reside. Users can request documents from local Web servers (i.e., ones residing on users' machines) or remote Web servers (i.e., ones residing on machines across a network).
To understand how a Web browser is able to locate documents on a Web server, it is helpful for you to know the following terms:
Local Web servers can be accessed in two ways: through the machine name, or through localhosta host name that references the local machine. We use localhost in this book for demonstration purposes. To determine the machine name in Windows 98, right click Network Neighborhood, and select Properties from the context menu to display the Network dialog. In the Network dialog, click the Identification tab. The computer name displays in the Computer name: field. Click Cancel to close the Network dialog. In Windows 2000, right click My Network Places and select Properties from the context menu to display the Network and Dialup Connections explorer. In the explorer, click Network Identification. The Full computer name: field in the System Properties window displays the computer name. In Windows XP, select Start > Control Panel, which displays the Control Panel window. Double click System in the Control Panel window, which opens the System Properties window. Select the Computer Name tab in the System Properties window; the Full computer name: field displays the computer name.
To request documents from the Web server, users must know the fully qualified domain names (machine names) on which the Web server software resides. For example, to access the documents from Deitel's Web server, you must know the FQDN www.deitel.com. The FQDN www.deitel.com indicates that the host is www and the toplevel domain is com. In a FQDN, the TLD often describes the type of organization that owns the domain. For example, usually the com TLD refers to a commercial business, the org TLD to a nonprofit organization and the edu TLD to an educational institution. In addition, each country has its own TLD, such as cn for China, et for Ethiopia, om for Oman and us for the United States.
Each FQDN corresponds to a numeric address called an IP (Internet Protocol) address, which is much like a street address. Just as people use street addresses to locate houses or businesses in a city, computers use IP addresses to locate other computers on the Internet. Each internet host computer has a unique IP address. Each address comprises four sets of numbers separated by periods, such as 220.127.116.11. A Domain Name System (DNS) server is a computer that maintains a database of FQDNs and their corresponding IP addresses. The process of translating FQDNs to IP addresses is called a DNS lookup. For example, to access the Deitel Web site, type the FQDN www.deitel.com into a Web browser. The DNS lookup translates www.deitel.com into the IP address of the Deitel Web server (18.104.22.168). The IP address of localhost is always 127.0.0.1. This address, also known as the loopback address, can be used to test Web applications on your local computer.