Last active
August 29, 2015 14:25
-
-
Save nhtua/937f271b3d75e114fe23 to your computer and use it in GitHub Desktop.
Make your diigo bookmarks private
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
//Run in console (press F12, click `Console` tab, paste and press Enter to run) | |
//NOTE: | |
// Scroll to end of page, choose 100 items/page. | |
// Run once for every page. | |
// After done; change page by your-self then run code again. (press Up Arrow to get pre-code) | |
var items = document.querySelectorAll(".editIcon"); | |
var i = 0; | |
items[i].click(); | |
var tBrowser = setInterval(function(){ | |
console.log("Private item: "+i); | |
if ( i+1 <= items.length){ | |
items[i].click(); | |
var checkBookmark = document.querySelector("#bPriPrivate"); | |
var checkNote = document.querySelector("#newItemPrivate"); | |
if (checkBookmark !== null) | |
checkBookmark.checked = "checked"; | |
if (checkNote !== null) | |
checkNote.checked = "checked"; | |
var bmS = document.querySelector("#wSubmit"); | |
var bmN = document.querySelector(".btn.blue.submit"); | |
if (bmS !== null) | |
bmS.click(); | |
if (bmN !== null) | |
bmN.click(); | |
} else { | |
clearInterval(tBrowser); | |
alert("Done") | |
} | |
i++; | |
},1000) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment