How to access a specific p tag while using BeautifulSoup

Hello everyone I’m having trouble while using BeautifulSoup , indeed i don’t succeed to access the information that I want, here is my code : import nltk import requests from bs4 import …

bs4 p tags returning as None

import bs4 import requests import re r = requests.get(‘https://www.the961.com/latest-news/lebanon-news/’).text soup = bs4.BeautifulSoup(r, ‘lxml’) for article in soup.find_all(‘article’): …

Python beautiful soup get only body content without header or footer data [closed]

In my code I need to get only the main text not the header or footer data. I also would like to filter out any html/css/js code that is received with the request. How would I do this? I have tried …

Scraping search results off of Sportchek with Beautiful Soup 4 to find prices

So I’m trying to web scrape search results from Sportchek with BS4, specifically this link “https://www.sportchek.ca/categories/men/footwear/basketball-shoes.html?page=1”. I want to get the …

python web scrapping issues with mechanize

I am trying to scrap web results from the website: https://promedmail.org/promed-posts/ I have followed beutifulsoup. mechanical soup and mechanize so far unable to scarp the search results. import re …

How can I scrape a href that is hidden behind a placeholder?

I’m trying to scrape the below href from a site. There are several hrefs on the site which I intend to scrape and so I am looping through the site in order to store them all in one list. Below is an …

scraping table from a website result as empty

I am trying to scrape the main table with tag :

from following website using ‘BeautifulSoup’ library, but the code …

Beautifulsoup: extracting td list in table

I’m stuck with a BeautifulSoup problem that I think is simple but I can’t seem to solve. It is about extracting each td from the following table to create a loop and a list:

Beautiful Soup: extract 2 different tags and append them together in text only output

I have been playing around with beautiful soup trying to learn it. So far ive learned some stuff but im struggle to put my use case together. how do i print, both movieslist and moviescore text only …