You are viewing a single comment's thread. Return to all comments →
import re import sys
html= sys.stdin.read()
pattern= r'https?://(?:www.|ww2.)?([a-zA-Z0-9-]+.?[a-zA-Z0-9-]+.[a-zA-Z].?[a-zA-Z])'
matches=re.findall(pattern,html)
output=sorted(set(url for url in matches))
print(';'.join(output))
Seems like cookies are disabled on this browser, please enable them to open this website
Detect the Domain Name
You are viewing a single comment's thread. Return to all comments →
import re import sys
html= sys.stdin.read()
pattern= r'https?://(?:www.|ww2.)?([a-zA-Z0-9-]+.?[a-zA-Z0-9-]+.[a-zA-Z].?[a-zA-Z])'
matches=re.findall(pattern,html)
output=sorted(set(url for url in matches))
print(';'.join(output))