﻿/*
function blockError(){return true;}
window.onerror = blockError;
*/
var close_button 	= "yes"		// GALLERY CLOSE BUTTON ON/OFF
var slideshow_button 	= "yes"		// SLIDESHOW BUTTON ON/OFF
var print_button 	= "yes"		// PRINT BUTTON yes/no
var zoom_button	 	= "yes"		// ZOOM BUTTON yes/no
var zoom		= "1.25"	// ZOOM AMOUNT
var zoom2		= "1.00"	// ZOOM BACK TO 100%
var right_click_on	= "yes"		// GALLERY RIGHT CLICK PROTECTION ON
var slideshow_width 	= 700		// SLIDESHOW POPUP WINDOW WIDTH
var slideshow_height 	= 525		// SLIDESHOW POPUP WINDOW HEIGHT
var view_width 		= 720		// GALLERY POPUP WIDTH
var view_height 	= 600		// GALLERY POPUP HEIGHT
var viewer	 	= "no"		// yes/FULL SCREEN OR no/POPUP MODE


// OTHER OPTIONS YOU CAN CHANGE

var scrollbarS 		= "0"		// TURN ON POPUP SCROLLBARS "1" FOR ON "0" FOR OFF
var right_click_text	= "Burada fare kullanılamaz"


// START SLIDESHOW POPUP CODE
function popUpSlideshow(URL) {

day = new Date();
id = day.getTime();
   if (viewer == "no") {
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars='+scrollbarS+',location=0,statusbar=0,menubar=0,resizable=1,width='+slideshow_width+',height='+slideshow_height+'');");
}
else 
if (viewer == "yes") {
eval("page" + id + " = window.open(URL);");
}
}

// START GALLERY POPUP CODE
function popUp(URL) {
   if (viewer == "no") {
var look='toolbar=0,scrollbars='+scrollbarS+',location=0,statusbar=0,menubar=0,resizable=1,width='+view_width+',height='+view_height+','
popwin=window.open("","",look)
}
else 
if (viewer == "yes") {
popwin=window.open("","")
}
popwin.document.open()
popwin.document.write('<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">\n');
popwin.document.write('<html><head>\n');
popwin.document.write('<title>Resim Galerisi</title>\n');
   if (right_click_on == "yes") {
popwin.document.write('<META HTTP-EQUIV="imagetoolbar" CONTENT="no">\n');
popwin.document.write('<script language="JavaScript" type="text/javascript">\n');
popwin.document.write('function noRightClick() {\n');
popwin.document.write('if (event.button==2) {\n');
popwin.document.write('alert(\''+right_click_text+'\')\n');
popwin.document.write('}\n');
popwin.document.write('}\n');
popwin.document.write('document.onmousedown=noRightClick\n');
popwin.document.write('</script>\n');
}
popwin.document.write('<link rel="StyleSheet" href="css/main.css" type="text/css"></head>\n');
popwin.document.write('<body>');
popwin.document.write('<TABLE cellpadding="0" cellspacing="0" border="0" width="100%"><tr><td align="center">\n');
popwin.document.write('<br><br><br><br>\n');
popwin.document.write('<TABLE cellpadding="1" cellspacing="0" border="0"><tr><td>\n');
   if (close_button == "yes") {
popwin.document.write('<form style="margin: 0px"><input type="button" value="Kapat" onmouseover="this.className=\'buttonon-popups\'" onmouseout="this.className=\'button-popups\'" class="button-popups" onClick=\'self.close()\'></form>\n');
}
   if (slideshow_button == "yes") {
popwin.document.write('</td><td>\n');
popwin.document.write('<form action="slideshow.html" style="margin: 0px"><input type="submit" value="Slayt Gösterisi" onmouseover="this.className=\'buttonon-popups\'" onmouseout="this.className=\'button-popups\'" class="button-popups"></form>\n');
}
   if (print_button == "yes") {
popwin.document.write('</td><td>\n');
popwin.document.write('<form style="margin: 0px"><input type="button" value="Resmi Bastır" onClick=\'window.print()\' class="button-popups" onmouseover="this.className=\'buttonon-popups\'" onmouseout="this.className=\'button-popups\'"></form>\n');
}
   if (zoom_button == "yes") {
popwin.document.write('</td><td>\n');
browser_version= parseInt(navigator.appVersion);
browser_type = navigator.appName;
if (browser_type == "Microsoft Internet Explorer" && (browser_version >= 4) && (navigator.userAgent.indexOf("Windows") != -1)) {
popwin.document.write('<form style="margin: 0px"><input type="button" value="'+zoom+'" onmouseover="this.className=\'buttonon-popups\'" onmouseout="this.className=\'button-popups\'" class="button-popups" onClick=\'show.style.zoom="'+zoom+'"\'></form>\n');
popwin.document.write('</td><td>\n');
popwin.document.write('<form style="margin: 0px"><input type="button" value="'+zoom2+'" onmouseover="this.className=\'buttonon-popups\'" onmouseout="this.className=\'button-popups\'" class="button-popups" onClick=\'show.style.zoom="'+zoom2+'"\'></form>\n');
}}
popwin.document.write('</td></tr></table>\n');
popwin.document.write('<br>\n');
popwin.document.write('<TABLE cellpadding="0" cellspacing="0" border="0"><tr><td>\n');
popwin.document.write('<img src="'+URL+'" name="show" class="popupborder">\n');
popwin.document.write('</td></tr></table><br>\n');
popwin.document.write('</td></tr><tr><td valign="bottom" align="center">\n');


popwin.document.write('</td></tr></table>\n');
popwin.document.write('</body></html>\n');
popwin.document.close()
}

document.write('<div class="divstyle" id="info" style=\'display:none;z-index:100\'>')
document.write('<div id="imagetitle" class="pstyletitle" align="center"></div>')
document.write('</div>')



var IE = document.all?true:false
if (!IE) document.captureEvents(Event.MOUSEMOVE)

document.onmousemove = getMouseXY;

var tempX = 0
var tempY = 0

  
function getMouseXY(e) {
  if (IE) { 
    tempX = event.clientX + document.body.scrollLeft
    tempY = event.clientY + document.body.scrollTop
  } else { 
    tempX = e.pageX
    tempY = e.pageY
  }  

  if (tempX < 0){tempX = 0}
  if (tempY < 0){tempY = 0}  

obj_info = document.getElementById("info")
obj_info.style.top = tempY + 15;
obj_info.style.left = tempX - 110;
  return true
}

function alert_msg(titletext){
obj_info = document.getElementById("info")
obj_info.style.display = '';
obj_imagetitle = document.getElementById("imagetitle");
obj_imagetitle.innerHTML = titletext;

}

function away()
{
obj_info = document.getElementById("info")
obj_info.style.display = 'none';
}


function goToURL() { history.go(-1); }


//  End -->
