var _prevLI = -1;

function Answer(id)
{
    tLI = $('tempLI');
    if(tLI != null)
    {
        p = tLI.parentNode;
        $('contForm').appendChild($('dCommentForm'));
        p.removeChild(tLI);
    }

//    alert($('lastComment').nodeName);

    if(id != 0)
    {
        var li = $('LI'+id);
        p = li.parentNode;

        li2 = document.createElement("li");
        li2.id = "tempLI";
        li2.className = "forma";

        p.insertBefore(li2, li.nextSibling);

        d = $('dCommentForm');
        li2.appendChild(d);

        $('lastComment').show();
    }
    else $('lastComment').hide();

    $('cid').value = id;
    _prevLI = id;
}


    var _prev = false;
    var _link = "/catalog/download.html";

    function Toggle(aid, inp)
    {
        inp2 = document.getElementById(inp);
        a2 = document.getElementById(aid);

        alink = _link + "?cid=" + _CID + "&pid="+ _PID; 

        if(inp2.checked) a2.href = alink;
        else a2.href = _link;
    }

