Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- linhas = data.split(/^[0-9]{1}\n/m);
- linhas.shift(); // linha vazia
- index = 0;
- resp = "";
- linhas.forEach (function (linha) {
- linha_atual = linha.split("\n");
- resp += index.toString() + "\n";
- resp += linha_atual[0] + "\n";
- linha_atual.shift(); // tempo
- resp += '<font color="yellow">' + "\n";
- linha_atual.forEach (function (parte) {
- if(parte !== "")
- resp += parte + "\n";
- });
- resp += "</font>\n\n";
- index++;
- });
- console.info(resp);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement