Skip to content

Instantly share code, notes, and snippets.

@kahagon
Created March 28, 2013 12:21
Show Gist options
  • Select an option

  • Save kahagon/5262705 to your computer and use it in GitHub Desktop.

Select an option

Save kahagon/5262705 to your computer and use it in GitHub Desktop.
はてなダイアリーの記事を一括でチェック入れて削除するスクリプト。
var deleteForm = null;
for (var i = 0; i < document.forms.length; i++) {
var action = document.forms[i].getAttribute("action");
if (action && action.match(/delete$/))
deleteForm = document.forms[i];
}
tdList = document.getElementsByClassName("td-checkbox");
for (i = 0; i < tdList.length; i++) {
tdList[i].children[0].checked = true;
}
deleteForm.submit();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment