﻿var x = 0;
function SetOpacity2(value) {
    document.getElementById('news').style.opacity = value / 25;
    document.getElementById('news').style.filter = 'alpha(opacity=' + value * 4 + ')';
}
function Animation() {
    for (var j = 0; j < 26; j++) {setTimeout('SetOpacity2(' + j + ')', 1000 + 40 * j);}
    document.getElementById("news").innerHTML = "<a class='news' href='" + arr[x][2] + "'><span style='color:White;'>" + arr[x][0] + "</span> <span style='color:Black;'>" + arr[x][1] + "</span></a>";
    for (var i = 25; i > -1; i--) {setTimeout('SetOpacity2(' + i + ')', 5000 - (40 * i));}
    if (x >= arr.length - 1)
    {x = 0;}
    else
    {x++;}
}
