Created
April 14, 2016 09:17
-
-
Save kurozumi/42f26d67e89294914a3695de5cd6a9d4 to your computer and use it in GitHub Desktop.
【Python】URLかどうか調べる方法
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
# coding: utf-8 | |
from urlparse import urlparse | |
url = "http://www.yahoo.co.jp" | |
o = urlparse(url) | |
assert len(o.scheme) > 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment