
	var timer;

	function loip_catalog_open(id, type) {
		
		if (type == 'self') type = '/self';
		
		var lang = getLang();
		
		if (type == '/self') {
			
			newWindow("/" + lang + "/catalog" + type + "/product/" + id + ".html", "blank");
			
		} else {
			
			newWindow("/" + lang + "/catalog" + type + "/product/" + id + ".html");
			
		}
		
	}

	function loip_catalog_descript_all(action) {
	
		for(var i = 0; i < expand.length; i++) {
		
			//if (action == 1) t = expand.length-i; else t = i;
			//timer = setTimeout("loip_catalog_descript_exp('" + expand[i] + "', " + action + ")", (50 * t));
			loip_catalog_descript_exp(expand[i], action);
		
		}
	
	}
	
	function loip_catalog_browser(id) {
		
		x=(screen.width-800)/2
		y=(screen.height-500)/2
		
		this.window.open("/modules/_loip/catalog/modal/browser.php?id=" + id, "catBrowser", "menubar=no, toolbar=no, width=800, height=500, resizable=no, status=yes, top="+y+", left="+x);
		
	}
	
	function loip_catalog_descript_exp(id, action) {
	
		var link = document.getElementById(id + '_link');
		var desc = document.getElementById(id + '_desc');
		var tr   = document.getElementById(id + '_tr');
	
		if (action == 1) {
		
			desc.style.display = '';
			link.innerHTML = "<img src='/admin/ui/actions/node_collapse.gif' border='0' class='expand'>";
			if (tr.className == 'prodEven') { tr.className = 'prodEvenB'; }
			if (tr.className == 'prodOdd')  { tr.className = 'prodOddB';  }
		
		} else {
		
			desc.style.display = 'none';
			link.innerHTML = "<img src='/admin/ui/actions/node_expand.gif' border='0' class='expand'>";
			if (tr.className == 'prodEvenB') { tr.className = 'prodEven'; }
			if (tr.className == 'prodOddB')  { tr.className = 'prodOdd';  }
		
		}
	
	}
	
	function loip_catalog_descript(id) {
	
		var desc = document.getElementById(id + '_desc');
		
		if (desc.style.display == 'none') {

			loip_catalog_descript_exp(id, 1);
			
		} else {
		
			loip_catalog_descript_exp(id, 0);
		
		}
	
	}
	