huan/fml.py
2023-07-17 00:07:28 +00:00

15 lines
304 B
Python

#!/usr/bin/python3
import requests
from bs4 import BeautifulSoup
def get_fml(url):
r = requests.get(url)
data = r.text
r.close
soup = BeautifulSoup(data, 'html.parser')
fml = soup.select_one("article > a.block").string.strip().replace("\\", "").rstrip(" FML")
del soup
return fml