﻿function FAQ_Fade(id) {

    if ($("#faq_Table_" + id).css('border') != undefined && $("#faq_Table_" + id).css('border') !='') {
    FAQ_FadeOut(id);
    }else
    {FAQ_FadeIn(id);}
}

function FAQ_FadeIn(id)
{
    $("#faq_Table_"+id).css({'border' : 'solid 1px #ceceb6'});
    $("#faq_sp_table_"+id).css({'background-color' : '#dfdfdf'});
    $("#faq_sv_table_"+id).css({'background-color' : '#fffec7'});
    $("#faq_sv_table_"+id).fadeIn("slow");
    $("#faq_sp_"+id).fadeIn("slow");
    $("#CloseBtn_"+id).fadeIn("slow");
}

function FAQ_FadeOut(id)
{
    $("#faq_Table_" + id).css({ 'border': 'none' });
    $("#faq_sp_table_" + id).css({ 'background-color': '#FFFFFF' });
    $("#faq_sv_table_" + id).css({ 'background-color': '#FFFFFF' });
    $("#faq_sv_table_" + id).fadeOut("slow");
    $("#faq_sp_" + id).fadeOut("slow");
    $("#CloseBtn_" + id).fadeOut("slow");
}

function GetFAQ(PageModulID, Kategori)
{
    FAQ_WebService.GetFAQItems(PageModulID, Kategori, GetFAQOnComplete)
}

function GetFAQOnComplete(result)
{
    $("#FAQ_ITEMS").attr('innerHTML', result);
}
