Created
May 20, 2016 22:40
-
-
Save rymcol/a14e0585977a75f3d37a3c143734c542 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
import urllib2 as ur | |
import re | |
f = ur.urlopen(u'http://website.com/SiteMap.xml') | |
res = f.readlines() | |
for d in res: | |
data = re.findall('<loc>(http:\/\/.+)<\/loc>',d) | |
for i in data: | |
print i |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment