Skip to content

Instantly share code, notes, and snippets.

@ashwnacharya
Created January 29, 2016 06:23
Show Gist options
  • Save ashwnacharya/e9bea02adfe3eeb3ed40 to your computer and use it in GitHub Desktop.
Save ashwnacharya/e9bea02adfe3eeb3ed40 to your computer and use it in GitHub Desktop.
import re
regex = re.compile('<DT><A HREF=\"(?P<urls>.+)" ADD_DATE=\".+" ICON=\".+\">(?P<names>.+)<\/A>')
results = regex.findall(contents)
for result in results:
print "{}, {}".format(result[1],result[0])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment