
startList = function() { 
if (document.all&&document.getElementById) { 
navRoot = document.getElementById("nav"); 
for (i=0; i<navRoot.childNodes.length; i++) { 
node = navRoot.childNodes[i]; 
if (node.nodeName=="LI") { 
node.onmouseover=function() { 
this.className+=" over"; 
 } 
 node.onmouseout=function() { 
 this.className=this.className.replace(" over", ""); 
 } 
 } 
 } 
 } 
} 
window.onload=startList; 
function get_model_part(products_id, models_type, file, models_brand, models_name,id)
{ //alert("fff");

    $.ajax({
		   //id='#'+id;
        //url: 'http://www.global-ecommerce-batteries.com//get_model_part.php',
		url: '/get_model_part.php',    
        type: 'POST',
        dataType: 'html',
        async: true, 
        data: 'products_id='+products_id+'&models_type='+models_type+'&file='+file+'&models_brand='+models_brand+'&models_name='+models_name+'&id='+id,
        timeout: 5000,
        success: function(data){
			$("li").removeClass("first"); 
			$('#'+id).addClass("first"); 
			$('#switchlsit > .productinfo').remove();
            $('#switchlsit').append(data);
        }
    });
}
function get_conn_model_part(products_id, models_type, file, models_brand, models_name,id)
{ //alert("fff");

    $.ajax({
		   //id='#'+id;
        //url: 'http://www.global-ecommerce-batteries.com//get_model_part.php',
		url: '/get_conn_model_part.php',    
        type: 'POST',
        dataType: 'html',
        async: true, 
        data: 'products_id='+products_id+'&models_type='+models_type+'&file='+file+'&models_brand='+models_brand+'&models_name='+models_name+'&id='+id,
        timeout: 5000,
        success: function(data){
			$("li").removeClass("first"); 
			$('#'+id).addClass("first"); 
			$('#switchlsit > .productinfo').remove();
            $('#switchlsit').append(data);
        }
    });
}
function get_description(products_id,file,id,pscode){
	$.ajax({
        url: '/get_description.php',    
        type: 'POST',
        dataType: 'html',
        async: true, 
        data: 'products_id='+products_id+'&file='+file+'&id='+id+'&pscode='+pscode,
        timeout: 5000,
        success: function(data){
			$("li").removeClass("first"); 
			$('#'+id).addClass("first"); 
			$('#switchlsit > .productinfo').remove();
            $('#switchlsit').append(data);
        }
    });
}

