Before running the code, you need to install BeautifulSoup, requests, os library. From bs4 import BeautifulSoup Import requests Import time Import os Def get_html(url): Try: Response=requests.get(url) Response.encoding='gb2312' If response.status_code==200: Print('Successfully connected! URL is '+url) Return response.text Except requests.RequestException: Return None Def get_url_and_name(url): "The passed argument is the main page link, the return value is a list with 2 elements, element 1 is the map package link, and element 2 is the map package name." Html=get_html(url) Soup=BeautifulSoup(html,'lxml') Name=[] Url_1=[] List2=soup.find_all...
Just want to spend this life happier.