/* if desktop/server/movile no longer support...put a place holder '99' or '9999' in front*/
selectArrLine = new Array();

selectArrLine.push("1000#$100#$Desktop Processors",
					"1000#$101#$Desktop Boards",
					"1000#$102#$Desktop Adapters",
					"2000#$200#$Mobile Processors",
					"2000#$201#$Mobile Platforms",
					"2000#$202#$Mobile Chipsets",
					"2000#$203#$Mobile Adapters",
					"2000#$204#$Verified by Intel",
					"3000#$300#$Server Processors",
					"3000#$301#$Server Boards",
					"3000#$302#$Server Systems",
					"3000#$303#$Server Chassis",
					"3000#$304#$RAID",
					"3000#$305#$IntelÂ® Modular Server",
					"3000#$306#$Storage Systems",
					"4000#$400#$Solid State Drives"
					);

selectArrProduct = new Array();

/*New list*/
/* Desktop Processors */
selectArrProduct.push("100#$49#$IntelÂ® CeleronÂ® processor",
						"100#$2841#$IntelÂ® PentiumÂ® processor",
						"100#$2308#$IntelÂ® Coreâ„¢2 Duo processor",
						"100#$2578#$IntelÂ® Coreâ„¢2 Quad processor",
						"100#$2309#$IntelÂ® Coreâ„¢2 Extreme processor",
						"100#$3059#$IntelÂ® Coreâ„¢ i7 processor Extreme Edition",
						"100#$3155#$IntelÂ® Coreâ„¢ i5 processor",
						"100#$3052#$IntelÂ® Coreâ„¢ i7-900 processor series",
						"100#$3052#$IntelÂ® Coreâ„¢ i7-800 processor series"
						);

/* Desktop Boards */
selectArrProduct.push("101#$2926#$IntelÂ® Desktop Board D945GCLF2",
						"101#$2916#$IntelÂ® Desktop Board D945GCLF",
						"101#$2839#$IntelÂ® Desktop Board DG31PR",
						"101#$3058#$IntelÂ® Desktop Board DG41RQ",
						"101#$3030#$IntelÂ® Desktop Board DG41TY",
						"101#$2781#$IntelÂ® Desktop Board DG33FB",
						"101#$2929#$IntelÂ® Desktop Board DG35EC",
						"101#$2783#$IntelÂ® Desktop Board DQ35JO",
						"101#$2934#$IntelÂ® Desktop Board DQ45EK",
						"101#$2933#$IntelÂ® Desktop Board DQ45CB",
						"101#$2979#$IntelÂ® Desktop Board DG43NB",
						"101#$2930#$IntelÂ® Desktop Board DG45FC",
						"101#$2931#$IntelÂ® Desktop Board DG45ID",
						"101#$2980#$IntelÂ® Desktop Board DP43TF",
						"101#$2932#$IntelÂ® Desktop Board DP45SG",
						"101#$2864#$IntelÂ® Desktop Board D5400XS",
						"101#$3018#$IntelÂ® Desktop Board DX58SO",
						"101#$3057#$IntelÂ® Desktop Board DG41MJ",
						"101#$3060#$IntelÂ® Desktop Board D945GSEJT",
						"101#$3121#$IntelÂ® Desktop Board DB43LD",
						"101#$3119#$IntelÂ® Desktop Board DQ43AP",
						"101#$3123#$IntelÂ® Desktop Board DG43GT",
						"101#$3064#$IntelÂ® Desktop Board DP55KG",		                  
						"101#$3125#$IntelÂ® Desktop Board DP55WB",
						"101#$3066#$IntelÂ® Desktop Board DP55WG",
						"101#$3065#$IntelÂ® Desktop Board DP55SB",
						"101#$3122#$IntelÂ® Desktop Board DG41KR"						
						);
						
/* Desktop Adapters */
selectArrProduct.push("102#$820#$IntelÂ® PRO/100 M Desktop Adapter",
						"102#$871#$IntelÂ® PRO/1000 MT Desktop Adapter",
						"102#$1058#$IntelÂ® PRO/100 S Management Adapter",
						"102#$1878#$IntelÂ® PRO/1000 GT Desktop Adapter"
						);

/* Mobile Processors */
selectArrProduct.push("200#$2277#$IntelÂ® Coreâ„¢ 2 Duo mobile processor",
						"200#$2967#$IntelÂ® Coreâ„¢2 Extreme mobile processor",
						"200#$3040#$IntelÂ® Coreâ„¢2 Quad mobile processor"
						);
 
/* Mobile Platforms */
selectArrProduct.push("201#$2277#$IntelÂ® CentrinoÂ® Duo mobile technology",
						"201#$955#$IntelÂ® CentrinoÂ® mobile technology",
						"201#$3012#$IntelÂ® CentrinoÂ® 2 processor technology",
						"201#$3013#$IntelÂ® CentrinoÂ® 2 with vProâ„¢ technology",
						"201#$2832#$IntelÂ® CentrinoÂ® with vProâ„¢ technology"
						);

/* Mobile Chipsets */
selectArrProduct.push("202#$2301#$Mobile IntelÂ® 945GM Express Chipset Family",
						"202#$1862#$Mobile IntelÂ® 915GM/GMS	 910GML Express Chipset Family"
						);
 
/* Mobile Adapters */
selectArrProduct.push("203#$1637#$IntelÂ® PRO/Wireless 2200BG Network Connection",
						"203#$1847#$IntelÂ® PRO/Wireless 2915ABG Network Connection",
						"203#$2259#$IntelÂ® PRO/Wireless 3945ABG Network Connection"
						);
						
/* Verified by Intel */
selectArrProduct.push("204#$2459#$ASmobile* AS62FP945GM1",
						"204#$2463#$ASmobile* AS62J945PM1",
						"204#$2465#$ASmobile* AS96F945GM1",
						"204#$2466#$ASmobile* AS96J945PM1",
						"204#$2468#$Compal* CEL80945PM1",
						"204#$2469#$Compal* CEL81945GM1",
						"204#$2470#$Compal* CGL30945PM1",
						"204#$2473#$Compal* CGL31945GM1",
						"204#$2474#$Quanta* QSW1945GM1",
						"204#$2475#$Quanta* QTW3A945PM1",
						"204#$2476#$Quanta* QTW3M945GM1"
						);

/* Server Processors */
selectArrProduct.push("300#$2676#$IntelÂ® XeonÂ® processor 7000 sequence",
						"300#$2371#$IntelÂ® XeonÂ® processor 5000 sequence",
						"300#$528#$IntelÂ® XeonÂ® processor 3000 sequence"
						);

/* Server Boards */
selectArrProduct.push("301#$2869#$IntelÂ® Entry Server Boards S3200SHV, S3210SHLC, and S3210SHLX",
						"301#$2871#$IntelÂ® Server Board X38ML",
						"301#$2451#$IntelÂ® Server Board S5000PAL",
						"301#$2487#$IntelÂ® Server Board S5000VSA",
						"301#$2308#$IntelÂ® Workstation Board S5000XVN",
						"301#$2305#$IntelÂ® Server Board S5000PSL",
						"301#$2859#$IntelÂ® Server Board S5400SF",
						"301#$3076#$IntelÂ® Server Board S5500BC",
						"301#$3069#$IntelÂ® Server Board S5520HC and S5520HCV",
						"301#$3068#$IntelÂ® Server Board S5520UR",
						"301#$3073#$IntelÂ® Server Board S5520SC",
						"301#$3115#$IntelÂ® Server Board S5500WB",
						"301#$3136#$IntelÂ® Server Board WX58BP",
						"301#$3146#$IntelÂ® Server Board S3420GP"
						);

/* Server Systems */
selectArrProduct.push("302#$2867#$IntelÂ® 4-Processor Server System S7000FC4UR",
						"302#$2872#$IntelÂ® Server System SR1520ML",
						"302#$2487#$IntelÂ® Server Systems SR2520SAF, SR2520SAS and SR2520SASX",
						"302#$2801#$IntelÂ® Server Systems SR1530CL, SR1530HCL, and SR1530HCLS",
						"302#$2834#$IntelÂ® Server Systems SR1530AH, SR1530AHLX, and SR1530HAHLX",
						"302#$2850#$IntelÂ® Server System SR1560SF",
						"302#$3078#$IntelÂ® Server System SR1630BC",
						"302#$3077#$IntelÂ® Server System SR1600UR",
						"302#$3086#$IntelÂ® Server System SR1625UR",
						"302#$3116#$IntelÂ® Server System SR2600UR",
						"302#$3117#$IntelÂ® Server System SR2625UR",
						"302#$3146#$IntelÂ® Server System SR1630GP"
						);
						
/* Server chasis */
selectArrProduct.push("303#$2135#$IntelÂ® Entry Server Chassis SC5295-E",
						"303#$2486#$IntelÂ® Entry Server Chassis SC5299-E",
						"303#$2414#$IntelÂ® Server Chassis SC5400",
						"303#$3070#$IntelÂ® Server Chassis SC5600",
						"303#$3072#$IntelÂ® Server Chassis SC5650",
						"303#$3072#$IntelÂ® Server Chassis SC5650UP"
						);
						
/* RAID Server */
selectArrProduct.push("304#$2501#$IntelÂ® RAID Controller SRCSAS144E",
						"304#$3054#$IntelÂ® RAID Controller SASWT4I",
						"304#$3053#$IntelÂ® RAID Controller SASUC8I",
						"304#$2972#$IntelÂ® RAID Controller SASMF8I",
						"304#$2858#$IntelÂ® RAID Controller SRCSATAWB",
						"304#$2970#$IntelÂ® RAID Controller SRCSASLS4I",
						"304#$2857#$IntelÂ® RAID Controller SRCSASRB",
						"304#$2969#$IntelÂ® RAID Controller SRCSASBB8I",
						"304#$2856#$IntelÂ® RAID Controller SRCSASJV",
						"304#$2971#$IntelÂ® RAID Controller SRCSASPH16I"
						);

/* Intel® Modular Server (formely Blade Servers) */
selectArrProduct.push("305#$2860#$IntelÂ® Compute Module MFS5000SI",
						"305#$2861#$IntelÂ® Modular Server systems MFSYS25 and MFSYS35"
						);
						
/* Storage Systems */
selectArrProduct.push("306#$2816#$IntelÂ® Storage Server SSR212MC2");

/* Solid State Drives */							
selectArrProduct.push("400#$3042#$IntelÂ® X18-M SATA Solid State Drive",
						"400#$3113#$IntelÂ® X25-E Extreme SATA Solid-State Drive",
						"400#$3044#$IntelÂ® X25-M SATA Solid State Drive"
						);

/*End new list*/


/* Unsupported products
selectArrProduct[34] = "9999#$1896#$IntelÂ® Desktop Board D915GVWB"
selectArrProduct[35] = "9999#$1774#$IntelÂ® Desktop Board D925XYT"
selectArrProduct[36] = "9999#$2350#$IntelÂ® Desktop Board D925XEHY"
selectArrProduct[37] = "9999#$2282#$IntelÂ® Desktop Board D945PLNM"
selectArrProduct[38] = "9999#$870#$IntelÂ® PRO/1000 T Desktop Adapter"
selectArrProduct[39] = "9999#$923#$IntelÂ® PRO/100 VM Network Connection"
selectArrProduct[40] = "9999#$1070#$IntelÂ® PRO/1000 CT Network Connection"
selectArrProduct[41] = "9999#$1361#$IntelÂ® PRO LAN Adapter - Unknown Model"
selectArrProduct[42] = "9999#$2247#$IntelÂ® PRO/1000 PT Desktop Adapter"
selectArrProduct[43] = "9999#$2290#$IntelÂ® CentrinoÂ® mobile technology Solo"
selectArrProduct[44] = "9999f#$944#$IntelÂ® PRO/Wireless 2100 Network Connection"
selectArrProduct[45] = "9999#$1078#$IntelÂ® PRO/Wireless 2100A Network Connection"
selectArrProduct[46] = "9999#$1530#$IntelÂ® PRO/Wireless 2011 LAN PCI Carrier"
selectArrProduct[47] = "9999#$1703#$IntelÂ® Wireless Connect Technology"
selectArrProduct[48] = "9999#$1779#$IntelÂ® PRO/Wireless 2225BG Network Connection"
selectArrProduct[49] = "9999#$2260#$IntelÂ® PRO/Wireless 3945BG Network Connection"
selectArrProduct[50] = "9999#$2250#$Boxed IntelÂ® XeonÂ® processor"
selectArrProduct[51] = "9999#$2305#$IntelÂ® Server Board S5000PSL"
selectArrProduct[52] = "9999#$2306#$IntelÂ® Server Board S5000XSL"
selectArrProduct[53] = "9999#$2362#$IntelÂ® Server Board SE7520BB2D2"
selectArrProduct[54] = "9999#$863#$IntelÂ® Server Board SHG2"
selectArrProduct[55] = "9999#$1857#$IntelÂ® Entry Server Board SE7221BK1-E"
selectArrProduct[56] = "9999#$2095#$IntelÂ® Server Board S845WD1-E"
selectArrProduct[57] = "9999#$602#$IntelÂ® Server Board SAI2"
selectArrProduct[58] = "9999#$603#$IntelÂ® Server Board SCB2"
selectArrProduct[59] = "9999#$802#$IntelÂ® Server Board SDS2"
selectArrProduct[60] = "9999#$464#$IntelÂ® Server Board STL2"
selectArrProduct[61] = "9999#$442#$IntelÂ® Server Board SBT2"
selectArrProduct[62] = "9999#$2307#$IntelÂ® Server Platform SC5400RA"
selectArrProduct[63] = "9999#$2057#$IntelÂ® Server Platform SR1400SYS"
selectArrProduct[64] = "9999#$2058#$IntelÂ® Server Platform SR2400SYS"
selectArrProduct[65] = "9999#$2059#$IntelÂ® Server Platform SR2400SYSD2"
selectArrProduct[66] = "9999#$1858#$IntelÂ® Entry Server Platform SR1425BK1-E"
selectArrProduct[67] = "9999#$431#$IntelÂ® Server Platform SPKA4"
selectArrProduct[68] = "9999#$803#$IntelÂ® Server Platform SRPL8"
selectArrProduct[69] = "9999#$872#$IntelÂ® Server Chassis SR2300"
selectArrProduct[70] = "9999#$1059#$IntelÂ® Server Chassis SBCE"
selectArrProduct[71] = "9999#$2414#$IntelÂ® Server Chassis SC5400"
selectArrProduct[72] = "9999#$875#$IntelÂ® RAID Controller SRCMRU"
selectArrProduct[73] = "9999#$1895#$IntelÂ® RAID Controller SRCU41L"
selectArrProduct[74] = "9999#$2177#$IntelÂ® RAID Controller SRCSAS18E"

*/

	
selectArrProduct.reverse(); //reverse it 

function UpdateLine() {	// Update Line Dropdown
	var iFirstDash, iSecondDash;
	var iPrdObjIdFamily;
	var famList = document.getElementById("selFamily")
	var lineList = document.getElementById("selLine");
	var prodList = document.getElementById("selProduct");
	//Reset Line dropdown
	lineList.length =  0;
	lineList.options[0] = new Option("Select Line","none");
	if (famList.selectedIndex!=0) {	//A valid family has been selected, so set line
		iPrdObjIdFamily = famList.options[famList.selectedIndex].value;
		for(var i=0;i<selectArrLine.length;i++) {
			strLine = selectArrLine[i];
			iFirstDash = strLine.indexOf("#$");
			if (strLine.substring(0,iFirstDash) == iPrdObjIdFamily) {
				iSecondDash = strLine.indexOf("#$", iFirstDash+2);			
				lineList.options[lineList.options.length] = new Option(strLine.substring(iSecondDash+2),strLine.substring(iFirstDash+2,iSecondDash));				
			}
		}
	}
	if(prodList){
		prodList.length = 0;									
		prodList.options[0] = new Option("Select Product","none");
	}
}

function UpdateProduct() {	// Update Product Dropdown
	var iFirstDash, iSecondDash;
	var iPrdObjId;
	var famList = document.getElementById("selFamily");
	var lineList = document.getElementById("selLine");
	var prodList = document.getElementById("selProduct");
	var str = "";
	var count = 0;
	//Reset Product dropdown
	prodList.length = 0;		
	prodList.options[0] = new Option("Select Product","none");
	if (lineList.selectedIndex!=0){	//A valid Line has been selected, so set Prod
		iPrdObjId = lineList.options[lineList.selectedIndex].value;
		for(var i=0;i<selectArrProduct.length;i++) {
			strProduct = selectArrProduct[i];
			iFirstDash = strProduct.indexOf("#$");			
			if (strProduct.substring(0, iFirstDash) == iPrdObjId){
				iSecondDash = strProduct.indexOf("#$", iFirstDash+2);	
				
				//legacy urls	
				if(count==0){
				prodList.options[1] = new Option("Legacy Products","http://downloadcenter.intel.com/Default.aspx")
				}
									
				prodList.options[prodList.options.length] = new Option(strProduct.substring(iSecondDash+2),strProduct.substring(iFirstDash+2,iSecondDash));
				count+=1;
			}
		}
	}
}