Course 5.1Lesson 1 of 3
The internet and the world wide web are not the same thing. This lesson separates the two: the internet is the network of networks, and the web is the pages you reach through it. Then it reads a web address, a URL, part by part.
Try the code and the simulations beside the lesson.
Ask a friend what they did on the internet today. They may say they watched a video, sent a message and read a news page. All three used the internet. Only one of them, the news page, was the world wide web.
The internet is the infrastructure. It is a huge network of networks that covers the world. It is made of the cables, the wireless links, the routers and the computers that pass data from one network to another. You met routers and IP addresses in the chapter on computer hardware. The internet is those parts, joined together.
The world wide web (the web, for short) is the collection of websites and web pages that you reach using the internet. A web page is a document, written in a language called HTML. Pages link to each other, which is why we call it a web.
So the web is one use of the internet. Email, video calls, online games and file sharing are other uses. They travel over the same cables, but they are not web pages.
The picture shows four networks: a home, a school, a company and a network of web servers. Routers join them. The internet is everything drawn there. The web is only the web pages kept on the web servers.
Could we join every network to every other one with its own cable? With a few networks, maybe. But the number of cables grows very fast. With networks, each one needs cables, and each cable joins two networks. So the number of cables is
With networks that is cables. With networks it is almost half a million. The internet joins millions of networks, so it cannot work like that. Instead, routers pass the data along from network to network until it arrives.
Every web page has an address. It is called a uniform resource locator, or URL. A URL is a text-based address for a web page. You type it into the address bar of a browser, or you click a link that holds it.
Look at this URL.
https://www.example.org/science/atoms.htmlIt has three parts.
https. It is the set of rules that the browser and the web server use to talk. It ends with ://.www.example.org. It names the web server, the computer that holds the website.science/atoms.html. It is the page inside the website. Here the page atoms.html is in a folder called science.A URL does not always show all three parts. If you type only www.example.org, the browser adds the protocol for you, and the web server sends its main page.
Why do we need a domain name at all? Computers on the internet find each other by their IP addresses, which are numbers. People find names much easier to remember than numbers. In the third lesson you see how a domain name is turned into an IP address.
The program splits a URL into its three parts. It uses the string methods split and find, which you met in the Python Foundations book. It finds the :// first, then the first / after the domain name.
Try each one on your own first. If you are stuck, open a hint. Then check with Show the answer.
https://www.example.com/bags.html.Every lesson is open to read. Enrolling also lets you:
Log in to join the discussion.
Loading…
This lesson is free to read. Enroll free to keep your place and take the tests.