function DetectResolution() { 
	// Testirano Radi NA IE6,IE7,Firefox 2,Opera 9.21
	var resX=screen.width;
	var resY=screen.height;
	document.write('Vaša Rezolucija je:' + resX + 'px x ' + resY + 'px'); 
} 
function DetectScreenSize(url) { 
	// Testirano Radi NA IE6,IE7,Firefox 2,Opera 9.21
	var scrX=screen.availWidth;
	var scrY=screen.availHeight;
	document.write('Vaše Dimenzije Prozora su :' + scrX + 'px x ' + scrY + 'px'); 
} 
function OpenFullScreenUrl() { 
	// Ne radi dobro u Operi
	var resX=screen.width;
	var resY=screen.height;
    var url= resX + "x" + resY + ".html";
    var wndWidth = typeof(screen.availWidth) != "undefined" ? 
        screen.availWidth : screen.width; 
    var wndHeight = typeof(screen.availHeight) != "undefined" ? 
        screen.availHeight : screen.height; 
    var wndFS = window.open(url, "PopupFS", 
        "top=0,left=0,width=" + wndWidth + ",height=" + wndHeight + ",status=yes,toolbar=no,resizable=no,toolbar=no,scrollbars=no,location=yes,directories=no"); 
    wndFS.resizeTo(wndWidth, wndHeight); 
    wndFS.focus(); 
}
function OpenFullScreenTestUrl() { 
	// Ne radi dobro u Operi
	var resX=screen.width;
	var resY=screen.height;
    var url= "Test.html";
    var wndWidth = typeof(screen.availWidth) != "undefined" ? 
        screen.availWidth : screen.width; 
    var wndHeight = typeof(screen.availHeight) != "undefined" ? 
        screen.availHeight : screen.height; 
    var wndFS = window.open(url, "PopupFS", 
        "top=0,left=0,width=" + wndWidth + ",height=" + wndHeight + ",status=yes,toolbar=no,resizable=no,toolbar=no,scrollbars=no,location=yes,directories=no"); 
    wndFS.resizeTo(wndWidth, wndHeight); 
    wndFS.focus(); 
}
function GetBodySize() {
	// Testirano Radi NA IE6,IE7,Firefox 2,Opera 9.21
	var myWidth;
	var myHeight;
	
	if( typeof( window.innerWidth ) == 'number' ) {
    	myHeight = window.innerHeight;
		myWidth = window.innerWidth;
  	}
	else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
    	 //IE 6+ in 'standards compliant mode'
    	 myHeight = document.documentElement.clientHeight;
		 myWidth = document.documentElement.clientWidth;
  	} 
	else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
   		 //IE 4 compatible
    	 myHeight = document.body.clientHeight;
		 myWidth = document.body.clientWidth;
  	}
	document.write('Body Dimenzije su :' + myWidth + 'px x ' + myHeight + 'px'); 
}
function OpenFullScreenUrlServer( magazine_id, magazine_no ) { 
	var resX=screen.width;
	var resY=screen.height;	
    //var magazine_id = 'DuroDakovic';
    //var magazine_no = '04';
    
    var url= '/Viewer.aspx?' + 'magazine_id=' + magazine_id + '&' + 'magazine_no=' + magazine_no  + '&' + 'res_x=' + resX + '&' + 'res_y=' + resY; 
    var wndWidth = typeof(screen.availWidth) != "undefined" ? 
        screen.availWidth : screen.width; 
    var wndHeight = typeof(screen.availHeight) != "undefined" ? 
        screen.availHeight : screen.height; 
    var wndFS = window.open(url, "PopupFS", 
        "top=0,left=0,width=" + wndWidth + ",height=" + wndHeight + ",menu=yes,status=yes,toolbar=no,resizable=no,toolbar=no,scrollbars=no,location=yes,directories=no"); 
    wndFS.resizeTo(wndWidth, wndHeight); 
    wndFS.focus(); 
}
