And this demo on extracting links from web pages brings
us to the very end of this module.
We started this module off by understanding how
Beautiful Soup sets up a parse tree,
and then we saw how we could navigate this parse tree using tag names.
This allowed us to directly access the first header,
the first paragraph element, or the first anchor tag on our page.
We saw how we could traverse down the parse tree to
child nodes or descendant nodes.
In a very similar manner,
we also saw how we could use soup objects to traverse up the
parse tree to parent nodes and ancestor nodes.
We understood child, parent, and sibling elements,
and we learned how to traverse the parse tree sideways.
We use the find and find_all functions to perform
filtering operations on HTML elements.
We filtered by tags, attributes, using regular expressions,
and custom functions.
And, finally,
we saw how we could extract links from web pages using Beautiful Soup,
and we extracted all of the links leading off of pluralsight.com.
In the next module,
we'll see how we can search for elements in the parse tree
using advanced Beautiful Soup functionality.