Friday, 24 November 2023

E mails extractor

import requests from bs4 import BeautifulSoup url = "https://example.com" response = requests.get(url) soup = BeautifulSoup(response.content, "html.parser") email_addresses = [] for link in soup.find_all("a"): href = link.get("href") if href and "mailto:" in href: email_addresses.append(href.replace("mailto:", "")) print(email_addresses)

1 comment:

Fireworks genrator

  Fireworks Generator Auto Launch: Toggle On/Off ...