一 HTML基本语法
HTML 超文本标记语言。其语法规则是用不同的标签对网页上的内容进行标记,从而使网页展示不同的效果。
-------------------------------------
h1:一级标题
h2:二级标题
p:段落
font:字体(被废弃但是能用)
body:主体
------------------------------------
xxx=XXX 是标签的属性,对标签进行进一步说明
html语法总结:
<标签 属性="值" 属性="值">被标记的内容</标签>
或:
<标签 属性="值" 属性="值">
<br><img src="***.jpg">
二 bs64的使用
find(标签,属性=值)
findall()
ps:<div class="honor">这些因为class是关键字,会报错
可以在class下面加个下划线 page.find("div", class_="honor")
也可用下面的方式表达:page.find("div", attrs={"class": "honor"})
抓取https://nba.hupu.com/stats/players的信息