﻿var Deger;
function AnketOyDegerleri(AnketID, CevapID) {
    $.ajax({
        url: "../Tools/json.aspx?Type=a&aID=" + AnketID + "&cID=" + CevapID,
        cache: false,
        dataType: "json",
        success: function(data) {
            $.each(data.items, function(i, item) {
                if (item) { // fix strange ie bug

                    Deger = '#bar_' + item.c;
                    $(Deger).css('width', item.w + '%');
                    $(Deger).html(item.w + '% ');
                    $("#oy_"+item.c).css('display', 'block');
                }
            });
        }
    });
    
}
function StilResimPuanla(StilID, Puan,sayfa) {
    $.ajax({
        url: "../Tools/json.aspx?StilPuan=" + Puan + "&StilID=" + StilID,
        cache: false,
        dataType: "json",
        success: function(data) {
           result = data.username;
           if(result == 1)
           {
            window.location.href="Detay.aspx?s="+sayfa+"#s";
           }else 
           {
            window.location.href="Detay.aspx?s="+sayfa+"#s";
           }
        }
    });
}
