var jq = document.createElement('script');
jq.src = "https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js";
document.getElementsByTagName('head')[0].appendChild(jq);
setTimeout(function()
{
var reported_post_count = 0;
$("a").each(function(i){
var a = $(this);
var href = a.attr("href");
var text = a.text().substr(0, 13);
if(href.substr(0, 33) == "u2u.php?action=view&folder=Outbox" && text == "Reported post")
{
var checkbox = a.parent().parent().children().first().children().first();
console.log(checkbox);
checkbox.prop("checked", true);
reported_post_count++;
}
});
if(reported_post_count > 0)
{
var modaction = $("input:radio[name=modaction]");
modaction.filter("[value=delete]").prop("checked", true);
$("input:submit[name=u2umodsubmit]").click();
}
} ,1000);
|