【发布时间】:2021-08-14 23:25:09
【问题描述】:
美好的一天!我无法从广播电台网站解析动态元素。这里需要当前歌曲的名称
import requests
from bs4 import BeautifulSoup
songsNameList = []
url = f"https://top-radio.ru/web/russkij-xit"
q = requests.get(url)
result = q.content
soup = BeautifulSoup(result, 'lxml')
songs = soup.select("#se_igra")
for song in songs:
print(song.find('span'))
songsNameList.append(song.find('span'))
https://top-radio.ru/web/marusya-fm
POST 字符串中 中包含的歌曲名称
,我有
我该如何解析这个案例?
【问题讨论】: