Feb-12-2020, 03:13 PM
Look at Web-Scraping part-1 and part-2
Then you should try yourself,here a start with some hints.
Then you should try yourself,here a start with some hints.
import requests from bs4 import BeautifulSoup url = 'https://europa.eu/youth/volunteering/organisations_en#open' response = requests.get(url) soup = BeautifulSoup(response.content, 'lxml') print(soup.find('title').text) block = soup.find('div', class_="eyp-card block-is-flex")Test usage,site have blocks with info,here some on first block.
European Youth Portal >>> block.a <a href="/youth/volunteering/organisation/48592_en" target="_blank">"Academy for Peace and Development" Union</a> >>> block.a.text '"Academy for Peace and Development" Union' >>> block.select_one('div > div > p:nth-child(9)') <p><strong>PIC:</strong> 948417016</p> >>> block.select_one('div > div > p:nth-child(9)').text 'PIC: 948417016'
apollo Wrote:is this possible to rssify content - of let us say 10 or 20 last records!?RSS is a kind of XML very close,so can use parsed content or HTML tag to make it.