function add(id) {
			$("#wite").show();
			var kolvo = document.getElementById('kolvo' + id).value;
			if (kolvo < 1) kolvo = 1;
			var ur = '/my/cart/do.add_cart.id.' + id + '.qty.' + kolvo + '.type.1.html';
			$.post(ur,{act:"addz"},
				function(data){
					$("#wite").hide();
					$('#go'+id).fadeIn("slow");
				}
			);
		}
		function kon() {
			$('#wite').hide();
		}
		function minus(id) {
			document.getElementById('kolvo' + id).value--;
			if(document.getElementById('kolvo' + id).value < 1) document.getElementById('kolvo' + id).value = 1;
		}
		function plus(id) {
			document.getElementById('kolvo' + id).value++;
			if(document.getElementById('kolvo' + id).value < 1) document.getElementById('kolvo' + id).value = 1;
		}
		function PopupWin(link, title) {
			var win = window.open('','preview','width=50,height=50,left=0,top=0,screenX=0,screenY=0,resizable=no,scrollbar=no,status=no,menubar=no,titlebar=no,location=no,scrolling=no');
			var winDoc = win.document;
			var content = '<html><head><title>' + title + '</title>' + 
			'<style>body{overflow: auto; padding:0; margin:0}img{border:0;}div{padding:5px; margin: 0 5px;}*div{padding:5px; margin: 0 5px;}html>body div {padding:0px 5px; margin: 0 5px;}</style>' + '</head><body><div><a href="javascript:self.close()">' +
			'<img alt="' + title + '" id="image" title="Закрыть" src="/thumb/640x0xNormal/data/files/' + link + '" /></a></div></body></html>';
			win.document.write(content);
			winDoc.body.onload = function() {
				var obj = winDoc.getElementById('image');
				var w = obj.width, h = obj.height;
				
				var iHeight= document.body.clientHeight, iWidth = self.innerWidth;
				var left = (self.opera ? iWidth : screen.availWidth)/2 - w/2;
				var top = (self.opera ? iHeight : screen.availHeight)/2 - h/2;

				win.resizeTo(w+35, h+65);
				
				win.moveTo(left, top);
			}
			win.onload = winDoc.body.onload; // special for Mozilla
			// !!! Important statement: popup onload won't execute without it!
			win.document.close();
			win.focus();
		}
