$(document).ready(function(){
						    // JFR Definitions
    jfr$('h1.sifr').jfr({
        src:'/_swf/jfr/Swis721_LtEx_BT.swf',
        css:[
            '* { color: #ff6600; text-align: left; font-size: 28px;   }',
            'a { color: #ff6600; text-decoration: none; }',
            'a:hover { text-decoration: underline; }'
            ]
    });

    
    $.jfr.render();

    $(".topLink").click(function(){
	   $('html, body').animate({scrollTop:0}, 'slow');
    });
	/* ============== FAQ LVL 1 =============== */
$(".faqItem .faqTitle a.faq").click(function() {
	$(".container").css("height","auto");
    // soru indeksi getiriliyor
var _index = $(".faqItem .faqTitle a.faq").index(this);
    // eger ayni soruya tiklaniyorsa, false donuyoruz
    if ($(".faqItem").eq(_index).hasClass("active")) {
        $(".faqItem .faqContent").eq(_index).slideUp("slow", function() {

            $(".faqItem").eq(_index).removeClass("active");

        });

        return false;
    }
    // tüm elementlerde dolasip, class temizleyip slideup yapiliyor
    $(".faqItem").each(function() {
        $(this).removeClass("active");
    })
    $(".faqContent").each(function() {
        $(this).slideUp("slow");

    })

    $(".faqItem").eq(_index).addClass("active");
    $($(".faqItem .faqContent").eq(_index)).slideToggle("slow");

   // linki disable etmek icin return false
    return false;
});

	//getFaqReady()
});
/*
function getFaqReady(){
		var openX = window.location.search;
    	var	openID = openX.substr(4,5)
        
        if($(".faqItem").eq(openID)){

            $(".faqContent").each(function(i){
                if(i == openID){
                        $(".faqItem").eq(i).addClass("active");
                        $(this).slideDown("fast");
                }
                else {
                        $(".faqItem").eq(i).removeClass("active");
                        $(this).slideUp("fast");
                }
            })
            //alert($(".faqItem").eq(openID).text())
            
            //alert("acıldı")
        }	
}
*/

var hastaliklar = new Array("has_rotav","has_bogmaca","has_cicek","has_cocuk","has_difteri","has_grip","has_hepatita","has_hepatitb","has_hib","has_kabakulak","has_kizamik","has_kizamikcik","has_kizil","has_kolera","has_kuduz","has_menenjit","has_pno","has_rota","has_sari","has_serviks","has_sucicegi","has_tifo")
function IllnessTable(illness){
		$(".container").css("height","auto");
		for (var k=0; k<hastaliklar.length; k++){
			if (document.getElementById(hastaliklar[k]).className=="breakme bleach"||document.getElementById(hastaliklar[k]).className=="breakme hm bleach"){
					document.getElementById(hastaliklar[k]).className="breakme hm bleach";
				} else {
					document.getElementById(hastaliklar[k]).className="hm bleach";
				}
			document.getElementById(illness).className="bl bleach";
		}
}

function getCenter(pwidth,pheight){
	wwidth=screen.width;
	wheigth=screen.height;
	lpos= (wwidth - pwidth)/2;
	tpos= (wheigth - pheight)/2;
	return lpos, tpos;
}

function PopItUp(src,w,h,s) {
	if(s) w=w+17;
	getCenter(w,h);
	Popwin = window.open(src,"popwin","toolbar=0,width=" + w + ", height=" + h + ", left="+ lpos +", top="+ tpos +"; location=0, directories=0, status=1, scrollbars="+s+", menubar=0, resizable=0, copyhistory=0");
	Popwin.focus();
	return false;
}

function ComboGo(){
		destination = document.getElementById("comboselect").options[document.getElementById("comboselect").selectedIndex].value+".aspx";
		if (destination) location.href = destination;

}
function ComboGoBread(){
		destination = document.getElementById("comboselect").options[document.getElementById("comboselect").selectedIndex].value;
		if (destination) location.href = destination;

}

function uyari(uyari,syfa){
window.open(uyari + "?redirectPage=" + syfa ,"GSK","toolbar=0,width=648,height=475,location=0,directories=0,status=0,scrollbars=1,menubar=0,resizable=0,left=10,top=10");
}


var sonuclar = new Array("Y","D","Y","D","Y","Y");
var sonuc = 0;
var sorucevapdurum;
var sorusonuc;
function VerifyTest(){
	for (var k=0; k<sonuclar.length; k++){
		sorusonuc = document.getElementById("evet"+(k+1)).checked;
		if (sorusonuc==true){
			sorucevapdurum="D";
				if (sonuclar[k]==sorucevapdurum){
					sonuc = sonuc+1;
					document.getElementById("cevap"+(k+1)).style.display="none";
					document.getElementById("sonuc"+(k+1)).className="dogru";
				} else {
					document.getElementById("cevap"+(k+1)).style.display="none";
					document.getElementById("sonuc"+(k+1)).className="yanlis";
				}
		} else {
			sorucevapdurum="Y";
				if (sonuclar[k]==sorucevapdurum){
					sonuc = sonuc+1;
					document.getElementById("cevap"+(k+1)).style.display="none";
					document.getElementById("sonuc"+(k+1)).className="dogru";
				} else {
					document.getElementById("cevap"+(k+1)).style.display="none";
					document.getElementById("sonuc"+(k+1)).className="yanlis";
				}
		}
		document.getElementById("cevap"+(k+1)).style.display="none";
		document.getElementById("sonuc"+(k+1)).style.display="block";
	}
	/** Kaybolacak Elementler **/
	document.getElementById("tebrik").style.display="none";
	document.getElementById("tebrik_mesaj").style.display="none";
	document.getElementById("sonuclan").style.display="none";
	document.getElementById("sonucucur").style.display="none";
	/** Sonuca göre ekrana basılacak elementler **/
	document.getElementById("tebrik1").style.display="block";
		var newPara = document.getElementById("baslik_tebrik");
		var newText = document.createTextNode(sonuclar.length+" sorudan "+sonuc+" tanesini doğru cevaplandırdınız.");
			if (sonuc==sonuclar.length){
				newText = document.createTextNode("Tebrikler! Tüm soruları doğru cevaplandırdınız.");
			}
		newPara.appendChild(newText);

scroll(0,0);
sonuc = 0;
}


function query(ji) {
hu = window.location.search.substring(1);
gy = hu.split("&");
for (i=0;i<gy.length;i++) {
ft = gy[i].split("=");
if (ft[0] == ji) {
return ft[1];
}
}
}