Created
January 13, 2012 18:28
-
-
Save erikhazzard/1607920 to your computer and use it in GitHub Desktop.
here's some regex
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
a = '<span>Abelmoschus esculentus</span><a href="#" class="search-choice-close" rel="1"></a>'; | |
b = a.replace(/<[\/]?span>/g,''); | |
final_string = b.replace(/<a.*$/g,''); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment