應該就判斷結尾到了沒,到了就不要迴圈就好了吧 endText = '延伸閱讀》' for tag in soup.select('div.article p,...
根據文獻 Returns false on failure. For successful queries which produce a result se...
這樣的效果好像還不錯 for tag in soup.select('div#news-content p'): # 內...
soup.select('dd.normal.first-thread div.user-comment-block')拿到的是整個文章了,所以你用 tag.g...
def tri(num): if num == 0: return tri(num - 1) print(' * ' *...
section#firstSingle div.post-content-container h2 strong:not(:last-of-type) 應該為...
excepts = ['▲', '▼', '或其他想排除的文字'] for tag in soup.select('div.caas-body p'):...
我看你有三個Project,我猜你現在正在運行的應該是MVClogin 而不是你認為的MvcBootstrap當然就無法找到路徑(404)在solution上按...
css 解法 res.select('div.story p:not(:first-of-type)') 如果 css 你不熟,那就用 if,這方法應該最基...