﻿function yokolancheck()
{ 
emptyfields = '';

var classname = 'error';
var classname2 = 'normal';
var email = document.form1.email.value;

if (document.form1.adsoyad.value == '') {
emptyfields += 'Adınızı ve soyadınızı girmediniz.\n';
document.form1.adsoyad.setAttribute('class', classname);
document.form1.adsoyad.setAttribute('className', classname);
document.form1.adsoyad.focus();
}
else
{
document.form1.adsoyad.setAttribute('class', classname2);
document.form1.adsoyad.setAttribute('className', classname2);
}

if (document.form1.email.value == '') {
emptyfields += 'E-posta adresinizi girmediniz.\n';
document.form1.email.setAttribute('class', classname);
document.form1.email.setAttribute('className', classname);
document.form1.email.focus();
}
else if (email=='' || email.indexOf ('@',0) == -1 || email.indexOf ('.',0) == -1 || email.length <10 ) {
emptyfields += 'Hatalı bir e-posta adresi girdiniz.\n';
}
else
{
document.form1.email.setAttribute('class', classname2);
document.form1.email.setAttribute('className', classname2);
}

if (document.form1.secure.value == '') {
emptyfields += 'Güvenlik kodunu girmediniz.\n';
document.form1.secure.setAttribute('class', classname);
document.form1.secure.setAttribute('className', classname);
document.form1.secure.focus();
}
else if (document.form1.secure.value != document.form1.secureid.value) {
emptyfields += 'Güvenlik kodunu hatalı girdiniz.\n';
document.form1.secure.setAttribute('class', classname);
document.form1.secure.setAttribute('className', classname);
document.form1.secure.focus();
}
else
{
document.form1.secure.setAttribute('class', classname2);
document.form1.secure.setAttribute('className', classname2);
}

if (emptyfields!= '') { 
alert(emptyfields);
return false; 
} 
else document.form1.submit(); 
}



function iletisimcheck()
{ 
emptyfields = '';

var classname = 'error';
var classname2 = 'normal';
var email = document.form1.email.value;

if (document.form1.adsoyad.value == '') {
emptyfields += 'Adınızı ve soyadınızı girmediniz.\n';
document.form1.adsoyad.setAttribute('class', classname);
document.form1.adsoyad.setAttribute('className', classname);
document.form1.adsoyad.focus();
}
else
{
document.form1.adsoyad.setAttribute('class', classname2);
document.form1.adsoyad.setAttribute('className', classname2);
}

if (document.form1.mesaj.value == '') {
emptyfields += 'Mesajınızı girmediniz.\n';
document.form1.mesaj.setAttribute('class', classname);
document.form1.mesaj.setAttribute('className', classname);
document.form1.mesaj.focus();
}
else
{
document.form1.mesaj.setAttribute('class', classname2);
document.form1.mesaj.setAttribute('className', classname2);
}


if (document.form1.email.value == '') {
emptyfields += 'E-posta adresinizi girmediniz.\n';
document.form1.email.setAttribute('class', classname);
document.form1.email.setAttribute('className', classname);
document.form1.email.focus();
}
else if (email=='' || email.indexOf ('@',0) == -1 || email.indexOf ('.',0) == -1 || email.length <10 ) {
emptyfields += 'Hatalı bir e-posta adresi girdiniz.\n';
}
else
{
document.form1.email.setAttribute('class', classname2);
document.form1.email.setAttribute('className', classname2);
}


if (emptyfields!= '') { 
alert(emptyfields);
return false; 
} 
else document.form1.submit(); 
}


function bultencheck()
{ 
emptyfields = '';

var classname = 'error';
var classname2 = 'normal';
var email = document.ebultenright.email.value;

if (document.ebultenright.email.value == '') {
emptyfields += 'E-posta adresinizi girmediniz.\n';
document.ebultenright.email.setAttribute('class', classname);
document.ebultenright.email.setAttribute('className', classname);
document.ebultenright.email.focus();
}
else if (email=='' || email.indexOf ('@',0) == -1 || email.indexOf ('.',0) == -1 || email.length <10 ) {
emptyfields += 'Hatalı bir e-posta adresi girdiniz.\n';
}
else
{
document.ebultenright.email.setAttribute('class', classname2);
document.ebultenright.email.setAttribute('className', classname2);
}


if (emptyfields!= '') { 
alert(emptyfields);
return false; 
} 
else document.ebultenright.submit(); 
}








function turcheck()
{ 
emptyfields = '';

var classname = 'error';
var classname2 = 'normal';
var email = document.form2.email.value;

if (document.form2.email.value == '') {
emptyfields += 'E-posta adresinizi girmediniz.\n';
document.form2.email.setAttribute('class', classname);
document.form2.email.setAttribute('className', classname);
document.form2.email.focus();
}
else if (email=='' || email.indexOf ('@',0) == -1 || email.indexOf ('.',0) == -1 || email.length <10 ) {
emptyfields += 'Hatalı bir e-posta adresi girdiniz.\n';
}
else
{
document.form2.email.setAttribute('class', classname2);
document.form2.email.setAttribute('className', classname2);
}

if (document.form2.adsoyad.value == '') {
emptyfields += 'Adınızı ve soyadınızı girmediniz.\n';
document.form2.adsoyad.setAttribute('class', classname);
document.form2.adsoyad.setAttribute('className', classname);
document.form2.adsoyad.focus();
}
else
{
document.form2.adsoyad.setAttribute('class', classname2);
document.form2.adsoyad.setAttribute('className', classname2);
}



if (emptyfields!= '') { 
alert(emptyfields);
return false; 
} 
else document.form2.submit(); 
}






function toggleFAQ(layerID, totalLayers) {
	for(var i=0;i<totalLayers;i++) {
		document.getElementById("faq_" + (i+1)).style.display = "none";
	}
	document.getElementById("faq_" + layerID).style.display = "block";
}





function popup(url, windowName, width, height, scroll) {

	var features = 'resizable=1,status=0,location=0' +
		',width=' + width +
		',height=' + height +
		',scrollbars=' + scroll

	return window.open(url,windowName,features);
}




function Sepet(url,id,ukn) {

if (id == 'rightcontainer') {
var pogressact = '<img border="0" src="http://www.outdoororacle.com/images/32-0.gif">'
}
if (id == 'article') {
var pogressact = '<div align="center"><img border="0" src="http://www.outdoororacle.com/images/36-0.gif"></div>'
}
else {
var pogressact = ''
}

var url = ukn + url
url="http://www.outdoororacle.com/"+url+"&sid="+Math.random();

  if (document.getElementById) {
    var x = (window.ActiveXObject) ? new ActiveXObject("Microsoft.XMLHTTP") : new XMLHttpRequest();
  }
  
  if (x) {
    x.onreadystatechange = function() {
    
    
    if (id == 'rightcontainer') {
    /*    document.getElementById(id).innerHTML= pogressact  */
    }

      if (x.readyState == 4 && x.status == 200) {
        el = document.getElementById(id);
        el.innerHTML = x.responseText;
        document.getElementById('chartadder').innerHTML = "<div class=\"okmetin\">Ürün sepetinize eklendi!</div>"
      }
    }
    x.open("GET", url, true);
	x.setRequestHeader("Content-Type", "application/x-www-form-urlencoded;charset=ISO-8859-9");
	x.setRequestHeader("Pragma", "no-cache");
	x.setRequestHeader("Cache-Control", "must-revalidate");
	x.setRequestHeader("Cache-Control", "no-cache");
	x.setRequestHeader("Cache-Control", "no-store");
    x.send(null);
  }
}

/* Bu yazilimin tum telif haklari Netbizde Bilisim Cozumleri'ne aittir,
/**/

function toggleBox(szDivID, iState) // 1 visible, 0 hidden
{
    if(document.layers)	   //NN4+
    {
       document.layers[szDivID].display = iState ? "show" : "hide";
    }
    else if(document.getElementById)	  //gecko(NN6) + IE 5+
    {
        var obj = document.getElementById(szDivID);
        obj.style.display = iState ? "block" : "none";
    }
    else if(document.all)	// IE 4
    {
        document.all[szDivID].style.display = iState ? "block" : "none";
    }
}

function saydun (o)	
{
      if ((event.keyCode < 48) || (event.keyCode > 57)) 
	{
        event.returnValue = false;
	} 
}




function addEvent(elm, evType, fn, useCapture)  
{  
  if (elm.addEventListener){  
    elm.addEventListener(evType, fn, useCapture);  
    return true;  
  } else if (elm.attachEvent){  
    var r = elm.attachEvent("on"+evType, fn);  
    return r;  
  } else {  
    alert("Handler could not be removed");  
  }  
}   
  
function prepareTextBoxes(){  
 if (!document.getElementsByTagName) return;  
 var oi=0;  
 var thisObj;  
 var objs = document.getElementsByTagName("input");  
  
  
 for (oi=0;oi<objs.length;oi++) {  
  thisObj = objs[oi];  
  if(thisObj.getAttribute('type') == 'text' || thisObj.getAttribute('type') == 'password'){  
   thisObj.className = 'text ' + thisObj.className;  
  }
  
 }  
}  
addEvent(window, "load", prepareTextBoxes);




function emailkont(madeger) {

url="http://www.outdoororacle.com/modules/uyelik/ajax/ver.asp?email=" + madeger + "&sid="+Math.random();
  var x = (window.ActiveXObject) ? new ActiveXObject("Microsoft.XMLHTTP") : new XMLHttpRequest();
  if (x) {
    x.onreadystatechange = function() {
    
      if (x.readyState == 4 && x.status == 200) {
        
        yanit = x.responseText;
        
     	document.signupform.mailsafe.value = yanit
     	signupcheck();
      }
    }
    x.open("GET", url, true);
    x.setRequestHeader("Content-Type", "application/x-www-form-urlencoded;charset=iso-8859-1");
	x.setRequestHeader("Pragma", "no-cache");
	x.setRequestHeader("Cache-Control", "must-revalidate");
	x.setRequestHeader("Cache-Control", "no-cache");
	x.setRequestHeader("Cache-Control", "no-store");
    x.send(null);
    
  }
}





function signupcheck()
{ 
emptyfields = '';

var classname = 'error';
var classname2 = 'normal';
var email = document.signupform.email.value;

if (document.signupform.email.value == '') {
emptyfields += 'E-posta adresinizi girmediniz.\n';
document.signupform.email.setAttribute('class', classname);
document.signupform.email.setAttribute('className', classname);
document.signupform.email.focus();
}
else if (email=='' || email.indexOf ('@',0) == -1 || email.indexOf ('.',0) == -1 || email.length <10 ) {
emptyfields += 'Hatalı bir e-posta adresi girdiniz.\n';
}
else
{
document.signupform.email.setAttribute('class', classname2);
document.signupform.email.setAttribute('className', classname2);
}

if (document.signupform.name.value == '') {
emptyfields += 'Adınızı ve soyadınızı girmediniz.\n';
document.signupform.name.setAttribute('class', classname);
document.signupform.name.setAttribute('className', classname);
document.signupform.name.focus();
}
else
{
document.signupform.name.setAttribute('class', classname2);
document.signupform.name.setAttribute('className', classname2);
}


if (document.signupform.password.value == '') {
emptyfields += 'Şifrenizi girmediniz.\n';
}
else
{
if (document.signupform.password.value != document.signupform.password2.value) {
emptyfields += 'Girdiğiniz şifreler birbiriyle aynı değil.\n';
}
}


if (document.signupform.mailsafe.value == 'NO') {
emptyfields += 'Bu e-posta adresiyle başka bir üyelik bulunuyor.\n';
}


if (document.signupform.secure.value == '') {
emptyfields += 'Güvenlik kodunu girmediniz.\n';
document.signupform.secure.setAttribute('class', classname);
document.signupform.secure.setAttribute('className', classname);
document.signupform.secure.focus();
}
else if (document.signupform.secure.value != document.signupform.secureid.value) {
emptyfields += 'Güvenlik kodunu hatalı girdiniz.\n';
document.signupform.secure.setAttribute('class', classname);
document.signupform.secure.setAttribute('className', classname);
document.signupform.secure.focus();
}
else
{
document.signupform.secure.setAttribute('class', classname2);
document.signupform.secure.setAttribute('className', classname2);
}

if (emptyfields!= '') { 
alert(emptyfields);
return false; 
} 
else document.signupform.submit(); 
}





function editcheck()
{ 
emptyfields = '';

var classname = 'error';
var classname2 = 'normal';
var email = document.signupform.email.value;

if (document.signupform.name.value == '') {
emptyfields += 'Adınızı ve soyadınızı girmediniz.\n';
document.signupform.name.setAttribute('class', classname);
document.signupform.name.setAttribute('className', classname);
document.signupform.name.focus();
}
else
{
document.signupform.name.setAttribute('class', classname2);
document.signupform.name.setAttribute('className', classname2);
}

if (document.signupform.password.value != '') {
if (document.signupform.password.value != document.signupform.password2.value) {
emptyfields += 'Girdiğiniz şifreler birbiriyle aynı değil.\n';
}
}

if (emptyfields!= '') { 
alert(emptyfields);
return false; 
} 
else document.signupform.submit(); 
}



function logincheck()
{ 
emptyfields = '';

var classname = 'error';
var classname2 = 'normal';
var email = document.loginright.email.value;

if (document.loginright.email.value == '') {
emptyfields += 'E-posta adresinizi girmediniz.\n';
document.loginright.email.focus();
}
else if (email=='' || email.indexOf ('@',0) == -1 || email.indexOf ('.',0) == -1 || email.length <10 ) {
emptyfields += 'Hatalı bir e-posta adresi girdiniz.\n';
}

if (document.loginright.password.value == '') {
emptyfields += 'Şifrenizi girmediniz.\n';
document.loginright.password.focus();
}

if (emptyfields!= '') { 
alert(emptyfields);
return false; 
} 
else document.loginright.submit(); 
}


function kurskayit()
{
document.getElementById('basvuru').style.display = 'block';
document.getElementById('basvurubutton').innerHTML = '<a href=\"#\" onclick=\"kursabasvur();\">Gönder</a>';
}



function kursabasvur()
{ 
emptyfields = '';

var classname = 'error';
var classname2 = 'normal';
var email = document.form1.email.value;

if (document.form1.adsoyad.value == '') {
emptyfields += 'Adınızı ve soyadınızı girmediniz.\n';
document.form1.adsoyad.setAttribute('class', classname);
document.form1.adsoyad.setAttribute('className', classname);
document.form1.adsoyad.focus();
}
else
{
document.form1.adsoyad.setAttribute('class', classname2);
document.form1.adsoyad.setAttribute('className', classname2);
}

if (document.form1.tel.value == '') {
emptyfields += 'Mesajınızı girmediniz.\n';
document.form1.tel.setAttribute('class', classname);
document.form1.tel.setAttribute('className', classname);
document.form1.tel.focus();
}
else
{
document.form1.tel.setAttribute('class', classname2);
document.form1.tel.setAttribute('className', classname2);
}


if (document.form1.email.value == '') {
emptyfields += 'E-posta adresinizi girmediniz.\n';
document.form1.email.setAttribute('class', classname);
document.form1.email.setAttribute('className', classname);
document.form1.email.focus();
}
else if (email=='' || email.indexOf ('@',0) == -1 || email.indexOf ('.',0) == -1 || email.length <10 ) {
emptyfields += 'Hatalı bir e-posta adresi girdiniz.\n';
}
else
{
document.form1.email.setAttribute('class', classname2);
document.form1.email.setAttribute('className', classname2);
}

if (emptyfields!= '') { 
alert(emptyfields);
return false; 
} 
else document.form1.submit(); 
}

function NewsScroller(name) {
	this.name = name;
	this.contDivID;
	this.news;
	this.transition;
	this.cIndex = 0;
	this.timer;
	this.width;
	this.height;
	this.cDiv;
	this.duration = 30;
	this.step = 1;
	this.delay = 1000;
	this.opc;
	this.ie = browser.ie;
}


NewsScroller.prototype.run = function () {
	if(this.read()) {
		switch(this.transition) {
			case 'SCROLL2TOP':
				this.scroll2top();
			break;
			case 'SCROLL2LEFT':
				this.scroll2left();
			break;
			case 'FADE':
				this.fade();
			break;
			default:
				alert("HATA OLUŞTU");
		}
	}
}


NewsScroller.prototype.read = function () {
	var i, j;
	var cont = document.getElementById(this.contDivID);
	var data = cont.childNodes;
	
	cont.style.overflow = 'hidden';
	cont.style.position = 'relative';
	
	this.width	= cont.offsetWidth;
	this.height	= cont.offsetHeight;
	
	this.news = new Array();
	
	j = 0;
	for(i=0; i < data.length; i++) {
		if(data[i].nodeName != '#text') {
			this.news[j] = data[i];
			j++;
		}
	}
	
	return true;
}


NewsScroller.prototype.scroll2top = function () {
	if(this.cIndex == this.news.length) {
		this.cIndex = 0;
	}
	
	if(this.cDiv) {
		this.cDiv.style.display = 'none';
	}
	
	this.cDiv = this.news[this.cIndex];
	this.cDiv.style.marginTop = this.height + "px";
	this.cDiv.style.display = 'block';
	this.cDiv.style.position = 'absolute';
	
	this.timer = setInterval(this.name + ".scrollTop()", this.duration);
	
	this.cIndex++;
}


NewsScroller.prototype.scrollTop = function () {
	var dist = parseInt(this.cDiv.style.marginTop);
	
	if(dist < -this.cDiv.offsetHeight) {
		clearInterval(this.timer);
		this.scroll2top();
	} else if(dist > 0 && dist <= this.step) {
		clearInterval(this.timer);
		this.cDiv.style.marginTop = "0px";
		this.timer = setTimeout(this.name+".goOn('scrollTop')", this.delay);
	} else {
		this.cDiv.style.marginTop = (dist - this.step) + "px";
	}
}


NewsScroller.prototype.scroll2left = function () {
	if(this.cIndex == this.news.length) {
		this.cIndex = 0;
	}
	
	if(this.cDiv) {
		this.cDiv.style.display = 'none';
	}
	
	this.cDiv = this.news[this.cIndex];
	this.cDiv.style.marginLeft = this.width + "px";
	this.cDiv.style.display = 'block';
	
	
	this.timer = setInterval(this.name + ".scrollLeft()", this.duration);
	
	this.cIndex++;
}


NewsScroller.prototype.scrollLeft = function () {
	var dist = parseInt(this.cDiv.style.marginLeft);
	
	if(dist < -this.cDiv.offsetWidth) {
		clearInterval(this.timer);
		this.scroll2left();
	} else if(dist > 0 && dist <= this.step) {
		clearInterval(this.timer);
		this.cDiv.style.marginLeft = "0px";
		this.timer = setTimeout(this.name+".goOn('scrollLeft')", this.delay);
	} else {
		this.cDiv.style.marginLeft = (dist - this.step) + "px";
	}
}


NewsScroller.prototype.fade = function () {
	if(this.cIndex == this.news.length) {
		this.cIndex = 0;
	}
	
	this.cDiv = this.news[this.cIndex];
	if(browser.isIE) {
		this.cDiv.filters.alpha.opacity = 0;
	} else {
		this.cDiv.style.MozOpacity = 0;
	}
	this.cDiv.style.display = 'block';
	this.opc = 0;
	this.timer = setInterval(this.name + ".fadeIN()", this.duration);
	this.cIndex++;
}


NewsScroller.prototype.fadeIN = function () {
	if(this.opc >= 100) {
		clearInterval(this.timer);
		this.opc = 100;
		this.timer = setTimeout(this.name + ".goOn('fadeOUT')", this.delay);
	} else {
		this.opc += this.step;
		if(browser.isIE) {
			this.cDiv.filters.alpha.opacity = this.opc;
		} else {
			this.cDiv.style.MozOpacity = this.opc/100;
		}
	}
}


NewsScroller.prototype.fadeOUT = function () {
	if(this.opc <= 0) {
		clearInterval(this.timer);
		this.cDiv.style.display = 'none';
		this.fade();
	} else {
		this.opc -= this.step;
		if(browser.isIE) {
			this.cDiv.filters.alpha.opacity = this.opc;
		} else {
			this.cDiv.style.MozOpacity = this.opc/100;
		}
	}
}



NewsScroller.prototype.goOn = function (func) {
	this.timer = setInterval(this.name + "." + func + "()", this.duration);
}


function BrowserDetect(){
var ua=navigator.userAgent.toLowerCase(); 
	this.isGecko=(ua.indexOf('gecko')!=-1 && ua.indexOf('safari')==-1);
	this.isAppleWebKit=(ua.indexOf('applewebkit')!=-1);

	this.isSafari=(ua.indexOf('safari')!=- 1);
	this.isIE=(ua.indexOf('msie')!=-1 && !this.isOpera && (ua.indexOf('webtv')==-1)); 
	this.isMozilla=(this.isGecko && ua.indexOf('gecko/')+14==ua.length);
	this.isFirebird=(ua.indexOf('firebird/')!=-1);
	this.isNS=((this.isGecko)?(ua.indexOf('netscape')!=-1):((ua.indexOf('mozilla')!=-1) && !this.isOpera && !this.isSafari && (ua.indexOf('spoofer')==-1) && (ua.indexOf('compatible')==-1) && (ua.indexOf('webtv')==-1) && (ua.indexOf('hotjava')==-1)));

	this.isIECompatible=((ua.indexOf('msie')!=-1) && !this.isIE);

	this.geckoVersion=((this.isGecko)?ua.substring((ua.lastIndexOf('gecko/')+6), (ua.lastIndexOf('gecko/')+14)):-1);
	this.equivalentMozilla=((this.isGecko)?parseFloat(ua.substring(ua.indexOf('rv:')+3)):-1);
	this.appleWebKitVersion=((this.isAppleWebKit) ? parseFloat(ua.substring(ua.indexOf('applewebkit/')+12)):-1);

	this.versionMinor=parseFloat(navigator.appVersion); 

	if(this.isGecko && !this.isMozilla) this.versionMinor=parseFloat(ua.substring(ua.indexOf('/', ua.indexOf('gecko/')+6)+1));
	else if(this.isMozilla) this.versionMinor=parseFloat(ua.substring(ua.indexOf('rv:')+3));
	else if(this.isIE && this.versionMinor>=4) this.versionMinor=parseFloat(ua.substring(ua.indexOf('msie ')+5));
	else if(this.isSafari) this.versionMinor=parseFloat(ua.substring(ua.lastIndexOf('safari/')+7));

	this.versionMajor=parseInt(this.versionMinor); 

	this.isDOM1=(document.getElementById);
	this.isDOM2Event=(document.addEventListener && document.removeEventListener);

	this.mode=document.compatMode?document.compatMode:'BackCompat';

	this.isWin=(ua.indexOf('win')!=-1);
	this.isMac=(ua.indexOf('mac')!=-1);

	this.isNS6x=(this.isNS && this.versionMajor==6);
	this.isNS6up=(this.isNS && this.versionMajor>= 6);
	this.isNS7x=(this.isNS && this.versionMajor==7);
	this.isNS7up=(this.isNS && this.versionMajor>= 7);
	this.isIE5x=(this.isIE && this.versionMajor==5);
	this.isIE55=(this.isIE && this.versionMinor==5.5);
	this.isIE5up=(this.isIE && this.versionMajor>= 5);
	this.isIE6x=(this.isIE && this.versionMajor==6);
	this.isIE6up=(this.isIE && this.versionMajor>= 6);
}
var browser=new BrowserDetect();

function Browser() {
		var b=navigator.appName;
		if (b=="Netscape") this.b="ns";
		else if ((b=="Opera") || (navigator.userAgent.indexOf("Opera")>0)) this.b = "opera";
		else if (b=="Microsoft Internet Explorer") this.b="ie";
		if (!b) alert('Unidentified browser./nThis browser is not supported,');
	this.version=navigator.appVersion;
	this.v=parseInt(this.version);
	this.ns=(this.b=="ns" && this.v>=4);
	this.ns4=(this.b=="ns" && this.v==4);
	this.ns6=(this.b=="ns" && this.v==5);
	this.ie=(this.b=="ie" && this.v>=4);
	this.ie4=(this.version.indexOf('MSIE 4')>0);
	this.ie5=(this.version.indexOf('MSIE 5')>0);
	this.ie55=(this.version.indexOf('MSIE 5.5')>0);
	this.ie6=(this.version.indexOf('MSIE 6')>0);
	this.opera=(this.b=="opera");
	this.dom=(document.createElement && document.appendChild && document.getElementsByTagName)?true:false;
	this.def=(this.ie||this.dom); // most used browsers, for faster if loops
	var ua=navigator.userAgent.toLowerCase();
	if (ua.indexOf("win")>-1) this.platform="win32";
	else if (ua.indexOf("mac")>-1) this.platform="mac";
	else this.platform="other";
}

is = new Browser();





function aramacheck(){ 

if (document.searchbox.querr.value == '')
{
return false;
}
else
{
document.cse-search-box.submit(); 
}
}




AIM = {

    frame : function(c) {

        var n = 'f' + Math.floor(Math.random() * 99999);
        var d = document.getElementById('commentresponse');
        d.innerHTML = '<iframe style="display:none" src="about:blank" id="'+n+'" name="'+n+'" onload="AIM.loaded(\''+n+'\')"></iframe>';
        document.body.appendChild(d);

        var i = document.getElementById(n);
        if (c && typeof(c.onComplete) == 'function') {
            i.onComplete = c.onComplete;
        }

        return n;
    },

    form : function(f, name) {
        f.setAttribute('target', name);
    },

    submit : function(f, c) {
        AIM.form(f, AIM.frame(c));
        if (c && typeof(c.onStart) == 'function') {
            return c.onStart();
        } else {
            return true;
        }
    },

    loaded : function(id) {
        var i = document.getElementById(id);
        if (i.contentDocument) {
            var d = i.contentDocument;
        } else if (i.contentWindow) {
            var d = i.contentWindow.document;
        } else {
            var d = window.frames[id].document;
        }
        if (d.location.href == "about:blank") {
            return;
        }

        if (typeof(i.onComplete) == 'function') {
            i.onComplete(d.body.innerHTML);
        }
    }

}




function logincheck()
{ 
emptyfields = '';

var email = document.loginform.email.value;

if (document.loginform.email.value == '') {
emptyfields += 'E-posta adresinizi girmediniz.\n';
}

if (document.loginform.email.value == '') {
emptyfields += 'Şifrenizi girmediniz.\n';
}


if (emptyfields!= '') { 
alert(emptyfields);
return false; 
} 
else document.loginform.submit(); 
}

