Skip to content

Instantly share code, notes, and snippets.

@MadanThangavelu
Created January 16, 2012 07:30
Show Gist options
  • Save MadanThangavelu/1619612 to your computer and use it in GitHub Desktop.
Save MadanThangavelu/1619612 to your computer and use it in GitHub Desktop.
strip
def remove_html_tags(data, tag):
p = re.compile(r'<'+tag+'.*>(.*)</'+tag+'>')
return p.sub(r'\1', data)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment