Last active
October 11, 2016 12:27
-
-
Save Prithvirajbilla/50dc499242c32cbf81f4 to your computer and use it in GitHub Desktop.
Revisions
-
Prithvirajbilla revised this gist
Apr 19, 2015 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,5 +1,5 @@ //Works on http://web.whatsapp.com // With little creativity and some coding skills you can do a lot of things using this code to annoy some one. function dispatch(target, eventType, char) { var evt = document.createEvent("TextEvent"); evt.initTextEvent (eventType, true, true, window, char, 0, "en-US"); -
Prithvirajbilla revised this gist
Apr 19, 2015 . 1 changed file with 6 additions and 5 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,12 +1,11 @@ //Works on http://web.whatsapp.com // With little creativity and some coding skills you can do a lot of things to annoy some one. function dispatch(target, eventType, char) { var evt = document.createEvent("TextEvent"); evt.initTextEvent (eventType, true, true, window, char, 0, "en-US"); target.focus(); target.dispatchEvent(evt); } function triggerClick() { var event = new MouseEvent('click', { 'view': window, @@ -17,6 +16,8 @@ function triggerClick() { } window.setInterval(function(){ dispatch(document.querySelector(".block-compose .input"), "textInput", "valar morghulis!"); triggerClick(); }, 1000); -
Prithvirajbilla revised this gist
Apr 6, 2015 . 1 changed file with 5 additions and 2 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -6,7 +6,6 @@ function dispatch(target, eventType, char) { } function triggerClick() { var event = new MouseEvent('click', { @@ -16,4 +15,8 @@ function triggerClick() { }); document.querySelector(".icon.btn-icon.icon-send").dispatchEvent(event) } window.setInterval(function(){ dispatch(document.querySelector(".block-compose .input"), "textInput", "hello!"); triggerClick(); }, 60000); -
Prithvirajbilla revised this gist
Apr 6, 2015 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -6,7 +6,7 @@ function dispatch(target, eventType, char) { } dispatch(document.querySelector(".block-compose .input"), "textInput", "hello!"); function triggerClick() { var event = new MouseEvent('click', { -
Prithvirajbilla created this gist
Apr 6, 2015 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,19 @@ function dispatch(target, eventType, char) { var evt = document.createEvent("TextEvent"); evt.initTextEvent (eventType, true, true, window, char, 0, "en-US"); target.focus(); target.dispatchEvent(evt); } dispatch(document.querySelector("#compose-input div"), "textInput", "hello!"); function triggerClick() { var event = new MouseEvent('click', { 'view': window, 'bubbles': true, 'cancelable': true }); document.querySelector(".icon.btn-icon.icon-send").dispatchEvent(event) } triggerClick()