			function checkImg(pictSrc, dx, dy) {
				var foto = new Image();
				foto.src = pictSrc;
				if(foto.complete) {
					var w = foto.width;
					var h = foto.height;
					viewFoto(pictSrc, dx, dy, w, h);
					}
				else {
				    act = "checkImg('" + pictSrc + "', '" + dx + "', '" +dy + "')";
					time = setTimeout(act,50);
					}
			}
			function viewFoto(pictSrc, dx, dy, w, h){
				document.getElementById('layer2').style.display = 'none';
				var layer = document.getElementById('layer');
				layer.setAttribute('src', pictSrc);
				layer.setAttribute('alt', "");
				layer.style.left = dx -130 + 'px';
				layer.style.top = dy -120 + 'px';
				layer.style.width = w+'px';
				layer.style.height = h+'px';
				layer.style.borderColor = '#fc0';
				layer.style.display = 'inline';
				
				layer.onclick = function(){
					layer.style.display = 'none';
				}
			}


window.onload = function() {
	if(document.getElementById('descr')) {
		var descr = document.getElementById('descr');
		var descript = document.getElementById('descript');
		descr.style.display = 'inline';
		descript.style.display = 'none';
		descr.onclick = function(){
			if(descript.style.display == 'none') {
				descript.style.display = 'block';
				descr.firstChild.nodeValue = 'Скрыть подробное описание журнала'
			
			}
			else {
				descript.style.display = 'none';
				descr.firstChild.nodeValue = 'Показать подробное описание журнала'
			}
		}
		descr.onmouseover = function() {descr.style.color = '#DF6B05'}
		descr.onmouseout = function() {	descr.style.color = '#080C29'}
	
	}

	
	if(document.getElementsByName('pict')) {
		var pict = document.getElementsByName('pict');
		for (var i = 0; i<pict.length; i++) {
			pict[i].onclick = function(e) {
				if (!e) {var e = window.event}
				var pictSrc= this.getAttribute('href');
				var dx = e.clientX;
				var dy = document.documentElement.scrollTop + e.clientY;
				var layer2 = document.getElementById('layer2');
				layer2.style.left = dx-50 + 'px';
				layer2.style.top = dy - 30 + 'px';
				layer2.style.display = 'inline';
				checkImg(pictSrc, dx ,dy);
				return false;
			}
		}
	}
}
	
	
wside=(window.sidebar)?true:false;var isOff=false;
if (top.location != self.location) {top.location = self.location;};

function mt_dn(a){return false};function mt_de(e){return(e.target.tagName!=null&&e.target.tagName.search('^(INPUT|TEXTAREA|BUTTON|SELECT)$')!=-1)};function mt_md(e){if(e.which==1){window.captureEvents(Event.MOUSEMOVE);window.onmousemove=mt_dn}}function mt_mu(e){if(e.which==1){window.releaseEvents(Event.MOUSEMOVE);window.onmousemove=null}}if(navigator.appName.indexOf('Internet Explorer')==-1||(navigator.userAgent.indexOf('MSIE')!=-1&&document.all.length!=0)){if(document.all){document.onselectstart=mt_dn}else if(document.layers){window.captureEvents(Event.MOUSEUP|Event.MOUSEDOWN);window.onmousedown=mt_md;window.onmouseup=mt_mu}else if(document.getElementById&&!document.all){document.onmousedown=mt_de}}

function disdrag(){if(document.all){document.ondragstart= new Function("return false");for (i = 0;i< document.images.length;i++){z = document.images(i);z.galleryImg = 'no';}}};disdrag();

strLocation =document.URL.toLowerCase();if((strLocation.indexOf("")<0) && (isOff==false))this.location.href ="http://www.dollbooks.ru";

if(document.URL.substring(0,4)=='file'){window.location='about:blank';isOff=true}


function mt_cm(){return false}
function mt_md(e){
	mac=navigator.userAgent.indexOf('Mac')!=-1;
	if (document.all) {
		if (event.button==2||(mac&&(event.ctrlKey||event.keyCode==91))) {return false}
		}
	else {
		if (e.which==3||(mac&&(e.modifiers==2||e.ctrlKey))) {return false}
		}
}
if (navigator.appName.indexOf('Internet Explorer')==-1||(navigator.userAgent.indexOf('MSIE')!=-1&&document.all.length!=0)) {
	if(document.all) { 
		mac=navigator.userAgent.indexOf('Mac')!=-1;
		version=parseFloat('0'+navigator.userAgent.substr(navigator.userAgent.indexOf('MSIE')+5),10);
		if(!mac&&version>4) {
			document.oncontextmenu=mt_cm
			}
		else {
			document.onmousedown=mt_md;document.onkeydown=mt_md
			}
	}
	else if(document.layers){
		window.captureEvents(Event.MOUSEDOWN|Event.modifiers|Event.KEYDOWN);
		window.onmousedown=mt_md;
		window.onkeydown=mt_md
		}
	else if(document.getElementById&&!document.all){
		document.oncontextmenu=mt_cm
		}
}

