D
D
dev4002016-08-18 21:44:03
JavaScript
dev400, 2016-08-18 21:44:03

Removing all entries from a VK group?

here is the button

<a class="ui_actions_menu_item" onclick="wall.deletePost(this, '-23003340_5699', 'f5495abcc7bf5b9656');" tabindex="0" role="link">Удалить запись</a>

There are also a bunch of buttons with this class on the page.
This script does not work correctly because of this.
for (var i=1;i<3000;i++){document.getElementsByClassName('ui_actions_menu_item')[i].click();document.getElementsByClassName('ui_actions_menu_item')}

Tell me how to pull out the link "delete record" in this case?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vitaly, 2016-08-18
@dev400

Queryselectorall and specify not only the class but also the corresponding container

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question