Created
July 19, 2016 14:24
-
-
Save jimmy89Li/9042211c1e26f27e367a9355e4778298 to your computer and use it in GitHub Desktop.
remove duplicate divs based on their id
This file contains hidden or 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
$('[id]').each(function (i) { | |
$('[id="' + this.id + '"]').slice(1).remove(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment