Created
October 19, 2019 07:26
-
-
Save seyed-dev/bd73e6c4a2db84676136cb5b4a9e2ce2 to your computer and use it in GitHub Desktop.
دریافت تعدادی پروکسی سالم ایران
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from bs4 import BeautifulSoup | |
import requests | |
import re | |
print("search iran proxy started") | |
response = requests.get('https://www.proxynova.com/proxy-server-list/country-ir/').text | |
soup = BeautifulSoup(response, "html.parser") | |
tables = soup.findAll("tr") | |
for x in tables: | |
try: | |
ip = x.find("abbr")["title"] | |
port = x.findAll("td", {"align":"left"})[1].find("a").get_text() | |
print('{}:{}'.format(ip, port)) | |
except: | |
pass | |
#Code By SeYeD :) @ITMKH |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment