url_list = [] if txt == "": txt = "php.txt" try: with open(txt,'r') as f: for a in f: a = a.replace('\n','') url_list.append(a) f.close() except: print("error!")
将队列中的内容拼接到 url 中组成需要验证的地址,通过返回值来判断是否存在此目录
1 2 3 4 5 6 7 8 9 10 11
for li in url_list: conn = "http://" + url + "" +li