Conteúdo do Curso
Web Scraping with Python
Web Scraping with Python
Navigating HTML Document
After reading the HTML
document, you have the flexibility to navigate it in several ways. To delve deeper, you can specify a tag just like an attribute. For example, let's examine the <head>
element and represent it in a 'structured' form (by employing the .prettify()
method).
Feel free to experiment by substituting the .head
attribute with .body
, for example. As shown above, the <head>
element encompasses several children. You can iterate through all the children of elements using a for
loop and the .children
attribute.
Tudo estava claro?
Conteúdo do Curso
Web Scraping with Python
Web Scraping with Python
Navigating HTML Document
After reading the HTML
document, you have the flexibility to navigate it in several ways. To delve deeper, you can specify a tag just like an attribute. For example, let's examine the <head>
element and represent it in a 'structured' form (by employing the .prettify()
method).
Feel free to experiment by substituting the .head
attribute with .body
, for example. As shown above, the <head>
element encompasses several children. You can iterate through all the children of elements using a for
loop and the .children
attribute.
Tudo estava claro?