Created
October 27, 2011 20:37
-
-
Save voxxit/1320792 to your computer and use it in GitHub Desktop.
Select all friends on Event creation page dialog on Facebook
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
var el = document.getElementsByName("checkableitems[]"); | |
for (i = 0; i < el.length; i++) { | |
if(el[i].checked !== true){ | |
var node = el[i].parentNode, | |
evt = document.createEvent("HTMLEvents"); | |
evt.initEvent("click", true, true); | |
node.dispatchEvent(evt); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
To use this:
There you go! Enjoy ;)