Skip to content

Instantly share code, notes, and snippets.

@pkmishra
Created June 24, 2013 03:29
Show Gist options
  • Save pkmishra/5847586 to your computer and use it in GitHub Desktop.
Save pkmishra/5847586 to your computer and use it in GitHub Desktop.
Collection of js utilities
//Script to find elements with duplicate ids in html dom
$('[id]').each(function(){
var ids = $('[id="'+this.id+'"]');
if(ids.length>1 && ids[0]==this)
console.warn('Multiple IDs #'+this.id);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment