课程视频地址:
https://edu.csdn.net/course/detail/28645
搜索文档树find_all方法-recursive参数
recursive参数
文档内容如下:
html_doc = “”"
The Dormouse's story
Once upon a time there were three little sisters; and their names were Elsie, Lacie and Tillie; and they lived at the bottom of a well.
...
"""调用tag的find_all()方法时,Beautiful Soup会检索当前tag的所有子孙节点,如果只想搜索tag的直接子节点,可以使用参数recursive=False。