跳至主內容區

新營學習網

This is an example of a HTML caption with a link.
:::

主內容區域

7-2 爬蟲

爬蟲

import requests
from bs4 import BeautifulSoup
#取得網址
res = requests.get('http://sypswiki.dcs.tn.edu.tw/wiki/index.php?title=Python_%E7%AD%86%E8%A8%98')
soup= BeautifulSoup(res.text,"lxml")
for item in soup.select('.mw-headline'):
    print(item.text)

下中左區域內容

Google網站翻譯工具列

下中右區域內容

站內搜尋

頁尾區域