Automate actions with the Chrome console
Tired of having to click on endless Checkbox lists of a listing?
This happens when we want to add people to Facebook, Retail platforms and on certain pages and applications that ask us to press the box over and over again and in the end your finger gets cramped. That's when you wonder... isn't there an automatic way to do this?
YES THERE IS! AND IT'S VERY EASY!
What we have to do for Windows
Control + Shift + J
What we have to do for Mac
alt+cmd+J
And then paste this line
(function() {
var aa= document.getElementsByTagName(«input»);
for (var i =0; i < aa.length; i++){ if (aa[i].type == 'checkbox') aa[i].checked = true; } })()
and we give ENTER
We close and magic! everything will be selected.
What if I wanted to replace a price or a word?
document.body.innerHTML = document.body.innerHTML.replace(/ABC/g, «XYZ»)
The ABC would be the value you want to replace and XYZ the value you are going to replace it with.
Can you think of any other shortcuts? Comment here if you can think of any.
Leave a comment
This site is protected by hCaptcha and the hCaptcha Privacy Policy and Terms of Service apply.