Free javascript Hosting


real-out.js

Uploaded on Dec 28 2021 21:15 by richardaol1990

function get_all(){
s = "";
total_sent = 0;
all = document.querySelectorAll(".panel.panel-default");
all.forEach(
function(elm){
try{
name = elm.innerText.split(" - ")[1].split(" ==> ")[0];
sent = "down"
try {
iframe = elm.querySelector("iframe");
sent = iframe.contentDocument.querySelectorAll("td")[14].innerText;
total_sent += parseInt( sent.replace(",","") );
} catch (e) {

}
s+= name + " --> " + sent + "\n";
} catch(e){}
}
);
s+= "===================\nNumber sent : " + total_sent;
s+= "\nRP : " ;
s+= "\nBoite TG : " ;
s+= "\nOffer : " ;
s+= "\nNber clicks: " ;
s+= "\nNber leads : " ;
s+= "\nSeeds : " ;
document.querySelector("#data").value = s;
}

divs = `
<div class="col-lg-2" style="margin:20px" onload="get_all()"><div class="panel panel-default">
<div class="panel-heading">
<b> Sauvegarde </a></b>
<button type="button" title="Sent" style="float:right" class="btn btn-xs default sent"><span class="glyphicon glyphicon-refresh" onclick="get_all()"></span></button>
</div>
<div class="panel-body">
<textarea id="data" style="width:100%;height:300px;"></textarea>
</div>
</div>
</div>
`;

function createElementFromHTML(htmlString) {
var div = document.createElement('div');
div.innerHTML = htmlString.trim();

// Change this to div.childNodes to support multiple top-level nodes
return div.firstChild;
}

divs = createElementFromHTML(divs);

document.querySelector(".row").prepend(divs);

get_all();

Back to list