Hi, everyone, welcome back.
In the last lecture, we took a look at what an HTTP request our guest request is and how it's made
along with our diagram, our general approach to web scraping.
And since we already covered the request, we need to take a moment to think about when we send that
request and visit a website.
What exactly is a Web site made out of?
Because this is going to help us when we're scraping to keep it simple.
A website is made out of three core things.
This is a HTML or hypertext markup language CSFs or cascading style sheets and a programming language.
And for the purpose of our example, we're going to use JavaScript as a programming language just because
it's really dominant specifically within the Web development industry.
And we can think about a house to try and compare.
And for our house, we can say the e-mail would be the bones of the house.
The structure, the access would be the design, the colors, the color of the doors, the Dem or hue
of the lights, things like that.
They're going to help style the house to give it the look.
And the programming language in JavaScript would be the functionality of the house.
So the electricity, the lighting, any of those functionality.
So if you open a door, something happens, such as a greeting.
That's where JavaScript is going to come into play.
And one quick tip here is that when we're building websites, when you are putting them together, developers
love to use classes because you don't want to have to rewrite code for every single shingle, every
single wall, every single door.
You want to give it a class so you can say class name door equals to brown.
And that's the color that's going to assign every door that has a class.
And keep that in mind in the future, because we're going to be using specific selectors, specific
XPATH information to scrape and retrieve information from our websites.
In addition to help us, most websites follow the dumb or the document object model.
And this is an object oriented representation of a Web page that can be modified with a scripting language
such as JavaScript.
And for any other further information, you can always visit the link that we can see here because it's
a great reference.
But the main takeaway here with the DOM is that it's going to serve us when we visit the Web page,
essentially a document, and we're going to be able to traverse or walk down that document to grab specific
selectors.
So let's take a quick look at everything.
The main components of a website would be the HTML Access and JavaScript, and a website primarily follows
the DOM.
So keep these in mind.
When we're web scraping, it's going to be very useful.
And let's wrap things up.
I'll see you in the next lecture.