 var optionData = [
               {"type": "Apple TV", "dataList":[
 	             {"name":"Apple TV 2G (4.1/8M89)", "value": "http://appldnld.apple.com/AppleTV/061-8940.20100926.Tvtnz/AppleTV2,1_4.1_8M89_Restore.ipsw"}, 
						   {"name":"Apple TV 2G (4.2.1/8C154)", "value": "http://appldnld.apple.com/AppleTV/061-9978.20101214.gmabr/AppleTV2,1_4.2.1_8C154_Restore.ipsw"},
						   {"name":"Apple TV 2G (4.3/8F191m)", "value": "http://appldnld.apple.com/AppleTV/061-9584.20110308.Cxdew/AppleTV2,1_4.3_8F191m_Restore.ipsw"},
						   {"name":"Apple TV 2G (4.4/9A334v)", "value": "http://appldnld.apple.com/AppleTV/061-9621.20111012.Vgijx/AppleTV2,1_4.4_9A334v_Restore.ipsw"}]  }, 
						   	
							{"type": "iPad 1", "dataList":[
							{"name":"iPad (3.2.2/7B500)", "value": "http://appldnld.apple.com/iPad/061-8801.20100811.CvfR5/iPad1,1_3.2.2_7B500_Restore.ipsw"}, 
						  {"name":"iPad (3.2/7B367)", "value": "http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPad/061-7987.20100403.mjiTr/iPad1,1_3.2_7B367_Restore.ipsw"},
						  {"name":"iPad (4.2.1/8C148)", "value": "http://appldnld.apple.com/iPad/061-9857.20101122.VGthy/iPad1,1_4.2.1_8C148_Restore.ipsw"},
              {"name":"iPad (4.3.1/8G4)","value": "http://appldnld.apple.com/iPhone4/041-0550.20110325.Zsw6y/iPad1,1_4.3.1_8G4_Restore.ipsw"},
              {"name":"iPad (4.3.2/8H7)","value":"http://appldnld.apple.com/iPhone4/041-0661.20110414.W9Q8r/iPad1,1_4.3.2_8H7_Restore.ipsw"},
              {"name":"iPad (4.3.3/8J2)","value":"http://appldnld.apple.com/iPhone4/041-1010.20110503.ScEp3/iPad1,1_4.3.3_8J3_Restore.ipsw"},
              {"name":"iPad (4.3.4/8K2)","value":"http://appldnld.apple.com/iPhone4/041-1913.20110715.cvTyu/iPad1,1_4.3.4_8K2_Restore.ipsw"},
              {"name":"iPad (4.3.5/8L1)","value":"http://appldnld.apple.com/iPhone4/041-1957.20110721.6UHaN/iPad1,1_4.3.5_8L1_Restore.ipsw"},
              {"name":"iPad (4.3/8F190)","value":"http://appldnld.apple.com/iPhone4/041-0329.20110311.Cvfre/iPad1,1_4.3_8F190_Restore.ipsw"},
              {"name":"iPad (5.0/9A334)","value":"http://appldnld.apple.com/iPhone4/041-8357.20111012.DTOrM/iPad1,1_5.0_9A334_Restore.ipsw"}	  
						]},
						  {"type":"iPad 2","dataList":[
							{"name":"iPad 2 CDMA (4.3.1/8G4)","value":"http://appldnld.apple.com/iPhone4/041-0544.20110325.Dew3r/iPad2,3_4.3.1_8G4_Restore.ipsw"},
							{"name":"iPad 2 CDMA (4.3.2/8H8)","value":"http://appldnld.apple.com/iPhone4/041-0665.20110414.MbwVr/iPad2,3_4.3.2_8H8_Restore.ipsw"},
							{"name":"iPad 2 CDMA (4.3.3/8J2)","value":"http://appldnld.apple.com/iPhone4/041-1014.20110503.52dap/iPad2,3_4.3.3_8J2_Restore.ipsw"},
							{"name":"iPad 2 CDMA (4.3.4/8K2)","value":"http://appldnld.apple.com/iPhone4/041-1917.2011.715.ZbLkn/iPad2,3_4.3.4_8K2_Restore.ipsw "},
							{"name":"iPad 2 CDMA (4.3.5/8L1)","value":"http://appldnld.apple.com/iPhone4/041-1962.20110721.rWxrf/iPad2,3_4.3.5_8L1_Restore.ipsw"},
							{"name":"iPad 2 CDMA (4.3/8F191)","value":"http://appldnld.apple.com/iPhone4/041-0334.20110311Plgt5/iPad2,3_4.3_8F191_Restore.ipsw"},
							{"name":"iPad 2 CDMA (5.0/9A334)","value":"http://appldnld.apple.com/iPhone4/041-9620.20111012.pnB4r/iPad2,3_5.0_9A334_Restore.ipsw"},
							{"name":"iPad 2 GSM (4.3.1/8G4)","value":"http://appldnld.apple.com/iPhone4/041-0557.20110325.Jy76y/iPad2,2_4.3.1_8G4_Restore.ipsw"},
							{"name":"iPad 2 GSM (4.3.2/8H7)","value":"http://appldnld.apple.com/iPhone4/041-0664.20110414.39vUS/iPad2,2_4.3.2_8H7_Restore.ipsw"},
							{"name":"iPad 2 GSM (4.3.3/8J2)","value":"http://appldnld.apple.com/iPhone4/041-1013.20110503.1m73D/iPad2,2_4.3.3_8J2_Restore.ipsw"},
							{"name":"iPad 2 GSM (4.3.4/8K2)","value":"http://appldnld.apple.com/iPhone4/041-1914.20110715.Xdw2Q/iPad2,2_4.3.4_8K2_Restore.ipsw"},
							{"name":"iPad 2 GSM (4.3.5/8L1)","value":"http://appldnld.apple.com/iPhone4/041-1961.20110721.zigyd/iPad2,2_4.3.5_8L1_Restore.ipsw"},
							{"name":"iPad 2 GSM (4.3/8F191)","value":"http://appldnld.apple.com/iPhone4/041-0369.20110311.Xzsew/iPad2,2_4.3_8F191_Restore.ipsw"},
							{"name":"iPad 2 GSM (5.0/9A334)","value":"http://appldnld.apple.com/iPhone4/041-9619.20111012.y34Nx/iPad2,2_5.0_9A334_Restore.ipsw"},
							{"name":"iPad 2 Wi-Fi (4.3.1/8G4)","value":"http://appldnld.apple.com/iPhone4/041-0556.20110325.64rfg/iPad2,1_4.3.1_8G4_Restore.ipsw"},
							{"name":"iPad 2 Wi-Fi (4.3.2/8H7)","value":"http://appldnld.apple.com/iPhone4/041-0663.20110414.U7bTI/iPad2,1_4.3.2_8H7_Restore.ipsw"},
							{"name":"iPad 2 Wi-Fi (4.3.3/8J2)","value":"http://appldnld.apple.com/iPhone4/041-1012.20110503.tmmBc/iPad2,1_4.3.3_8J2_Restore.ipsw"},
							{"name":"iPad 2 Wi-Fi (4.3.4/8K2)","value":"http://appldnld.apple.com/iPhone4/041-1924.2011.0715.qP4r3/iPad2,1_4.3.4_8K2_Restore.ipsw"},
							{"name":"iPad 2 Wi-Fi (4.3/8F191)","value":"http://appldnld.apple.com/iPhone4/041-0368.20110311.SwtHr/iPad2,1_4.3_8F191_Restore.ipsw"},
							{"name":"iPad 2 WiFi (4.3.5/8L1)","value":"http://appldnld.apple.com/iPhone4/041-1960.20110721.UsAO4/iPad2,1_4.3.5_8L1_Restore.ipsw"},
							{"name":"iPad 2 WiFi (5.0/9A334)","value":"http://appldnld.apple.com/iPhone4/041-9618.20111012.Zxb22/iPad2,1_5.0_9A334_Restore.ipsw"}
						]},
						{"type":"iPhone ","dataList":[
							{"name":"iPhone (1.0.1/1C25)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-3614.20070731.Nt6Y7/iPhone1,1_1.0.1_1C25_Restore.ipsw"},
							{"name":"iPhone (1.0.2/1C28)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-3823.20070821.vormd/iPhone1,1_1.0.2_1C28_Restore.ipsw"},
							{"name":"iPhone (1.0/1A543a)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-3538.20070629.B7vXa/iPhone1,1_1.0_1A543a_Restore.ipsw"},
							{"name":"iPhone (1.1.1/3A109a)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-3883.20070927.In76t/iPhone1,1_1.1.1_3A109a_Restore.ipsw"},	
							{"name":"iPhone (1.1.2/3B48b)","value":"=http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-4037.20071107.5Bghn/iPhone1,1_1.1.2_3B48b_Restore.ipsw"},	
							{"name":"iPhone (1.1.3/4A93)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-4061.20080115.4Fvn7/iPhone1,1_1.1.3_4A93_Restore.ipsw"},
							{"name":"iPhone (1.1.4/4A102)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-4313.20080226.Sw39i/iPhone1,1_1.1.4_4A102_Restore.ipsw"},		
							{"name":"iPhone (2.0.1/5B108)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-5135.20080729.Vfgtr/iPhone1,1_2.0.1_5B108_Restore.ipsw"},	
							{"name":"iPhone (2.0.2/5C1)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-5246.20080818.2V0hO/iPhone1,1_2.0.2_5C1_Restore.ipsw"},	
							{"name":"iPhone (2.0/5A347)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-4956.20080710.V50OI/iPhone1,1_2.0_5A347_Restore.ipsw"},	
							{"name":"iPhone (2.1/5F136)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-5202.20080909.gkbEj/iPhone1,1_2.1_5F136_Restore.ipsw"},
							{"name":"iPhone (2.2.1/5H11)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-5830.20090127.Mmni6/iPhone1,1_2.2.1_5H11_Restore.ipsw"},	
							{"name":"iPhone (2.2/5G77)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-5779.20081120.Pt5yH/iPhone1,1_2.2_5G77_Restore.ipsw"},
							{"name":"iPhone (3.0.1/7A400)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-6974.20090731.Cf4Tg/iPhone1,1_3.0.1_7A400_Restore.ipsw"},
							{"name":"iPhone (3.0/7A341)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-6580.20090617.XsP76/iPhone1,1_3.0_7A341_Restore.ipsw"},	
							{"name":"iPhone (3.1.2/7D11)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-7268.20091008.32pNe/iPhone1,1_3.1.2_7D11_Restore.ipsw"},	
							{"name":"iPhone (3.1.3/7E18)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-7481.20100202.4orot/iPhone1,1_3.1.3_7E18_Restore.ipsw"},		
							{"name":"iPhone (3.1/7C144)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-6605.20090909.PQ3ws/iPhone1,1_3.1_7C144_Restore.ipsw"}
						]},
						{"type":"iPhone 3G","dataList":[
							{"name":"iPhone 3G (2.0.1/5B108)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-5134.20080729.Q2W3E/iPhone1,2_2.0.1_5B108_Restore.ipsw"},
							{"name":"iPhone 3G (2.0.2/5C1)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-5241.20080818.t5Fv3/iPhone1,2_2.0.2_5C1_Restore.ipsw"},
							{"name":"iPhone 3G (2.0/5A347)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-4955.20080710.bgt53/iPhone1,2_2.0_5A347_Restore.ipsw"},
							{"name":"iPhone 3G (2.1/5F136)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-5198.20080909.K3294/iPhone1,2_2.1_5F136_Restore.ipsw"},		
							{"name":"iPhone 3G (2.2.1/5H11)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-5828.20090127.aQLi8/iPhone1,2_2.2.1_5H11_Restore.ipsw"},
							{"name":"iPhone 3G (2.2/5G77)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-5778.20081120.Aqw4R/iPhone1,2_2.2_5G77_Restore.ipsw"},
							{"name":"iPhone 3G (3.0.1/7A400)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-6972.20090731.Zx3Rr/iPhone1,2_3.0.1_7A400_Restore.ipsw"},
							{"name":"iPhone 3G (3.0/7A341)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-6578.20090617.VfgtU/iPhone1,2_3.0_7A341_Restore.ipsw"},	
							{"name":"iPhone 3G (3.1.2/7D11)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-7265.20091008.Xsd32/iPhone1,2_3.1.2_7D11_Restore.ipsw"},
							{"name":"iPhone 3G (3.1.3/7E18)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-7468.20100202.pbnrt/iPhone1,2_3.1.3_7E18_Restore.ipsw"},
							{"name":"iPhone 3G (3.1/7C144)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-6600.20090909.AwndZ/iPhone1,2_3.1_7C144_Restore.ipsw"},
							{"name":"iPhone 3G (4.0.1/8A306)","value":"http://appldnld.apple.com/iPhone4/061-8616.20100715.phnt4/iPhone1,2_4.0.1_8A306_Restore.ipsw"},
							{"name":"iPhone 3G (4.0/8A293)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone4/061-7436.20100621.58Yt4/iPhone1,2_4.0_8A293_Restore.ipsw"},
							{"name":"iPhone 3G (4.1/8B117)","value":"http://appldnld.apple.com/iPhone4/061-7932.20100908.3fgt5/iPhone1,2_4.1_8B117_Restore.ipsw"},	
							{"name":"iPhone 3G (4.2.1/8C148)","value":"http://appldnld.apple.com/iPhone4/061-9853.20101122.Vfgt5/iPhone1,2_4.2.1_8C148_Restore.ipsw"},	
							{"name":"iPhone 3G (4.2/8C148)","value":"http://appldnld.apple.com/iPhone4/061-9853.20101122.Vfgt5/iPhone1,2_4.2.1_8C148_Restore.ipsw"}		
						]},
						{"type":"iPhone 3GS","dataList":[
						{"name":"iPhone 3GS (3.0.1/7A400)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-6976.20090731.Vgbt5/iPhone2,1_3.0.1_7A400_Restore.ipsw"},
						{"name":"iPhone 3GS (3.0/7A341)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-6582.20090617.LlI87/iPhone2,1_3.0_7A341_Restore.ipsw"},
						{"name":"iPhone 3GS (3.1.2/7D11)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-7270.20091008.phn32/iPhone2,1_3.1.2_7D11_Restore.ipsw"},
						{"name":"iPhone 3GS (3.1.3/7E18)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-7472.20100202.8tugj/iPhone2,1_3.1.3_7E18_Restore.ipsw"},	
						{"name":"iPhone 3GS (3.1/7C144)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-6609.20090909.mwws4/iPhone2,1_3.1_7C144_Restore.ipsw"},	
						{"name":"iPhone 3GS (4.0.1/8A306)","value":"http://appldnld.apple.com/iPhone4/061-8618.20100715.Zapn4/iPhone2,1_4.0.1_8A306_Restore.ipsw"},	
						{"name":"iPhone 3GS (4.0/8A293)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone4/061-7437.20100621.5urG8/iPhone2,1_4.0_8A293_Restore.ipsw"},	
						{"name":"iPhone 3GS (4.1/8B117)","value":"http://appldnld.apple.com/iPhone4/061-7938.20100908.F3rCk/iPhone2,1_4.1_8B117_Restore.ipsw"},	
						{"name":"iPhone 3GS (4.2.1/8C148a)","value":"http://appldnld.apple.com/iPhone4/061-9895.20101122.Cdew2/iPhone2,1_4.2.1_8C148a_Restore.ipsw"},
						{"name":"iPhone 3GS (4.3.1/8G4)","value":"http://appldnld.apple.com/iPhone4/041-0549.20110325.ZxP8u/iPhone2,1_4.3.1_8G4_Restore.ipsw"},	
						{"name":"iPhone 3GS (4.3.2/8H7)","value":"http://appldnld.apple.com/iPhone4/041-0660.20110414.Gwed5/iPhone2,1_4.3.2_8H7_Restore.ipsw"},	
						{"name":"iPhone 3GS (4.3.3/8J2)","value":"http://appldnld.apple.com/iPhone4/041-1009.20110503.M73Yr/iPhone2,1_4.3.3_8J2_Restore.ipsw"},	
						{"name":"iPhone 3GS (4.3.4/8K2)","value":"http://appldnld.apple.com/iPhone4/041-1921.20110715.ItuLh/iPhone2,1_4.3.4_8K2_Restore.ipsw"},	
						{"name":"iPhone 3GS (4.3.5/8L1)","value":"http://appldnld.apple.com/iPhone4/041-1965.20110721.gxUB5/iPhone2,1_4.3.5_8L1_Restore.ipsw"},	
						{"name":"iPhone 3GS (4.3/8F190)","value":"http://appldnld.apple.com/iPhone4/041-0328.20110311.Lkhy6/iPhone2,1_4.3_8F190_Restore.ipsw"},	
						{"name":"iPhone 3GS (5.0/9A334)","value":"http://appldnld.apple.com/iPhone4/041-8356.20111012.SQRDT/iPhone2,1_5.0_9A334_Restore.ipsw"},	
						{"name":"iPhone 3GS (5.0.1/9A405)","value":"http://appldnld.apple.com/iPhone4/041-3307.20111109.5tGhu/iPhone2,1_5.0.1_9A405_Restore.ipsw"}	
						]},
						{"type":"iPhone 4","dataList":[
							{"name":"iPhone 4 (4.0.1/8A306)","value":"http://appldnld.apple.com/iPhone4/061-8619.20100715.4Pnsx/iPhone3,1_4.0.1_8A306_Restore.ipsw"},
							{"name":"iPhone 4 (4.0/8A293)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone4/061-7380.20100621,Vfgb5/iPhone3,1_4.0_8A293_Restore.ipsw"},
							{"name":"iPhone 4 (4.1/8B117)","value":"http://appldnld.apple.com/iPhone4/061-7939.20100908.Lcyg3/iPhone3,1_4.1_8B117_Restore.ipsw"},
							{"name":"iPhone 4 (4.2.1/8C148)","value":"http://appldnld.apple.com/iPhone4/061-9858.20101122.Er456/iPhone3,1_4.2.1_8C148_Restore.ipsw"},
							{"name":"iPhone 4 (4.3.1/8G4)","value":"http://appldnld.apple.com/iPhone4/041-0551.20110325.Aw2Dr/iPhone3,1_4.3.1_8G4_Restore.ipsw"},
							{"name":"iPhone 4 (4.3.2/8H7)","value":"http://appldnld.apple.com/iPhone4/041-0662.20110414.byQ84/iPhone3,1_4.3.2_8H7_Restore.ipsw"},
							{"name":"iPhone 4 (4.3/8F190)","value":"http://appldnld.apple.com/iPhone4/041-0330.20110311.Cswe3/iPhone3,1_4.3_8F190_Restore.ipsw"},
							{"name":"iPhone 4 (4.3.3/8J2)","value":"http://appldnld.apple.com/iPhone4/041-1011.20110503.q7fGc/iPhone3,1_4.3.3_8J2_Restore.ipsw"},
							{"name":"iPhone 4 (4.3.4/8K2)","value":"http://appldnld.apple.com/iPhone4/041-1923.20110715.BnATg/iPhone3,1_4.3.4_8K2_Restore.ipsw"},
							{"name":"iPhone 4 (4.3.5/8L1)","value":"http://appldnld.apple.com/iPhone4/041-1966.20110721.V3Ufe/iPhone3,1_4.3.5_8L1_Restore.ipsw"},
							{"name":"iPhone 4 (5.0/9A334)","value":"http://appldnld.apple.com/iPhone4/041-8358.20111012.FFc34/iPhone3,1_5.0_9A334_Restore.ipsw"},
							{"name":"iPhone 4 (5.0.1/9A405)","value":"http://appldnld.apple.com/iPhone4/041-3309.20111109.64rtg/iPhone3,1_5.0.1_9A405_Restore.ipsw"},
							{"name":"iPhone 4 CDMA (4.2.7/8E303)","value":"http://appldnld.apple.com/iPhone4/041-0614.20110414.B47xa/iPhone3,3_4.2.7_8E303_Restore.ipsw"},
							{"name":"iPhone 4 CDMA (4.2.8/8E401)","value":"http://appldnld.apple.com/iPhone4/041-1022.20110503.5g8k7/iPhone3,3_4.2.8_8E401_Restore.ipsw"},
							{"name":"iPhone 4 CDMA (4.2.9/8E50)","value":"http://appldnld.apple.com/iPhone4/041-1916.20110715.V5rUA/iPhone3,3_4.2.9_8E501_Restore.ipsw"},
							{"name":"iPhone 4 CDMA(5.0/9A334)","value":"http://appldnld.apple.com/iPhone4/041-9743.20111012.vjhfp/iPhone3,3_5.0_9A334_Restore.ipsw"},
						  {"name":"iPhone 4 CDMA (5.0.1/9A405)","value":"http://appldnld.apple.com/iPhone4/041-3304.20111109.Vgtyh/iPhone3,3_5.0.1_9A405_Restore.ipsw"}]},
						  	
						 {"type":"iPhone 4S","dataList":[
						 	{"name":"iPhone 4S (5.0/9A334)","value":"http://appldnld.apple.com/iPhone4/041-1317.20111012.UVTgr/iPhone4,1_5.0_9A334_Restore.ipsw"},
						  {"name":"iPhone 4S (5.0.1/9A405)","value":"http://appldnld.apple.com/iPhone4/041-3305.20111109.Bghy6/iPhone4,1_5.0.1_9A405_Restore.ipsw"}	
						] },
						{"type":"iPod Touch 1G","dataList":[
		{"name":"iPod Touch 1G (1.1/3A101a)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPod/SBML/osx/bundles/061-3882.20070910.N8uyT/iPod1,1_1.1_3A101a_Restore.ipsw"},
		{"name":"iPod Touch 1G (1.1.1/3A110a)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPod/SBML/osx/bundles/061-3932.20070927.p23dD/iPod1,1_1.1.1_3A110a_Restore.ipsw"},
		{"name":"iPod Touch 1G (1.1.2/3B48b)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPod/SBML/osx/bundles/061-4036.20071107.9g3DF/iPod1,1_1.1.2_3B48b_Restore.ipsw"},
		{"name":"iPod Touch 1G (1.1.3/4A93)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPod/SBML/osx/061-4060.20080115.9Iuh5/iPod1,1_1.1.3_4A93_Restore.ipsw"},
		{"name":"iPod Touch 1G (1.1.4/4A102)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPod/SBML/osx/bundles/061-4312.20080226.Btu45/iPod1,1_1.1.4_4A102_Restore.ipsw"},
	  {"name":"iPod Touch 1G (1.1.5/4B1)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPod/SBML/osx/bundles/061-4841.20080714.bgy8O/iPod1,1_1.1.5_4B1_Restore.ipsw"}
						]},
						
						{"type":"iPod Touch 2G","dataList":[
		{"name":"iPod Touch 2G (2.1.1/5F138)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPod/SBML/osx/bundles/061-5494.20080909.8i9o0/iPod2,1_2.1.1_5F138_Restore.ipsw"},
		{"name":"iPod Touch 2G (2.2.1/5H11a)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-5863.20090127.rt56K/iPod2,1_2.2.1_5H11a_Restore.ipsw"},
		{"name":"iPod Touch 2G (2.2/5G77a)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPod/SBML/osx/061-5358.20081120.Gtghy/iPod2,1_2.2_5G77a_Restore.ipsw"},
		{"name":"iPod Touch 2G (4.0/8A293)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone4/061-7435.20100621.tr49t/iPod2,1_4.0_8A293_Restore.ipsw"},
		{"name":"iPod Touch 2G (4.1/8B117)","value":"http://appldnld.apple.com/iPhone4/061-7937.20100908.ghj4f/iPod2,1_4.1_8B117_Restore.ipsw"},
		{"name":"iPod Touch 2G (4.2/8C148)","value":"http://appldnld.apple.com/iPhone4/061-9855.20101122.Lrft6/iPod2,1_4.2.1_8C148_Restore.ipsw"},
		{"name":"iPod Touch 2G (4.2.1/8C148)","value":"http://appldnld.apple.com/iPhone4/061-9855.20101122.Lrft6/iPod2,1_4.2.1_8C148_Restore.ipsw"}	
						]},
						{"type":"iPod Touch 3G","dataList":[
		{"name":"iPod Touch 3G (3.1.1/7C145)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPod/SBML/osx/bundles/061-7163.20090909.NtstR/iPod3,1_3.1.1_7C145_Restore.ipsw"},
		{"name":"iPod Touch 3G (3.1.2/7D11)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-7271.20091008.Tch23/iPod3,1_3.1.2_7D11_Restore.ipsw"},
		{"name":"iPod Touch 3G (3.1.3/7E18)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone/061-7473.20100202.4i44t/iPod3,1_3.1.3_7E18_Restore.ipsw"},
		{"name":"iPod Touch 3G (4.0/8A293)","value":"http://appldnld.apple.com.edgesuite.net/content.info.apple.com/iPhone4/061-7381.20100621.AzSP9/iPod3,1_4.0_8A293_Restore.ipsw"},
		{"name":"iPod Touch 3G (4.1/8B117)","value":"http://appldnld.apple.com/iPhone4/061-7941.20100908.sV9KE/iPod3,1_4.1_8B117_Restore.ipsw"},
		{"name":"iPod Touch 3G (4.2.1/8C148)","value":"http://appldnld.apple.com/iPhone4/061-9860.20101122.Xsde3/iPod3,1_4.2.1_8C148_Restore.ipsw"},
		{"name":"iPod Touch 3G (4.3.1/8G4)","value":"http://appldnld.apple.com/iPhone4/041-0552.20110325.Yt67u/iPod3,1_4.3.1_8G4_Restore.ipsw"},
		{"name":"iPod Touch 3G (4.3.2/8H7)","value":"http://appldnld.apple.com/iPhone4/041-0667.20110414.95hVL/iPod3,1_4.3.2_8H7_Restore.ipsw"},
		{"name":"iPod Touch 3G (4.3.3/8J2)","value":"http://appldnld.apple.com/iPhone4/041-1021.20110503.8Lfs1/iPod3,1_4.3.3_8J2_Restore.ipsw"},
		{"name":"iPod Touch 3G (4.3.4/8K2)","value":"http://appldnld.apple.com/iPhone4/041-1919.20110715.ShHh4/iPod3,1_4.3.4_8K2_Restore.ipsw"},
		{"name":"iPod Touch 3G (4.3.5/8L1)","value":"http://appldnld.apple.com/iPhone4/041-1964.20110721.P9Cg3/iPod3,1_4.3.5_8L1_Restore.ipsw"},
		{"name":"iPod Touch 3G (4.3/8F190)","value":"http://appldnld.apple.com/iPhone4/061-8366.20110311.Fr45t/iPod3,1_4.3_8F190_Restore.ipsw"},
	  {"name":"iPod Touch 3G (5.0/9A334)","value":"http://appldnld.apple.com/iPhone4/061-8360.20111012.New3w/iPod3,1_5.0_9A334_Restore.ipsw"}	]},
		
		        {"type":"iPod Touch 4G","dataList":[
		{"name":"iPod Touch 4G (4.1/8B118)","value":"http://appldnld.apple.com/iPhone4/061-9344.20100922.Urgt43/iPod4,1_4.1_8B118_Restore.ipsw"},
		{"name":"iPod Touch 4G (4.2.1/8C148)","value":"http://appldnld.apple.com/iPhone4/061-9859.20101122.$erft/iPod4,1_4.2.1_8C148_Restore.ipsw"},
		{"name":"iPod Touch 4G (4.3.1/8G4)","value":"http://appldnld.apple.com/iPhone4/041-0545.20110325.We3Rt/iPod4,1_4.3.1_8G4_Restore.ipsw"},
		{"name":"iPod Touch 4G (4.3.2/8H7)","value":"http://appldnld.apple.com/iPhone4/041-0666.20110414.3QvM1/iPod4,1_4.3.2_8H7_Restore.ipsw"},
		{"name":"iPod Touch 4G (4.3.3/8J2)","value":"http://appldnld.apple.com/iPhone4/041-1015.20110503.d7i57/iPod4,1_4.3.3_8J2_Restore.ipsw"},
		{"name":"iPod Touch 4G (4.3.4/8K2)","value":"http://appldnld.apple.com/iPhone4/041-1918.20110715.MgWsk/iPod4,1_4.3.4_8K2_Restore.ipsw"},
		{"name":"iPod Touch 4G (4.3.5/8L1)","value":"http://appldnld.apple.com/iPhone4/041-1963.20110721.Huant/iPod4,1_4.3.5_8L1_Restore.ipsw"},
		{"name":"iPod Touch 4G (4.3/8F190)","value":"http://appldnld.apple.com/iPhone4/061-9588.20110311.GtP7y/iPod4,1_4.3_8F190_Restore.ipsw"},
		{"name":"iPod Touch 4G (5.0/9A334)","value":"http://appldnld.apple.com/iPhone4/061-9622.20111012.Evry3/iPod4,1_5.0_9A334_Restore.ipsw"}     	
		        	]  
								  }];
								  
		// {"name":"","value":""},						  
	var jsonData = {
		      "iPhone1.0":  "iPhone (1.0/1A543a)",
		      "iPhone1.0.1":"iPhone (1.0.1/1C25)",
		      "iPhone1.0.2":"iPhone (1.0.2/1C28)",
		      "iPhone1.1.1":"iPhone (1.1.1/3A109a)",
		      "iPhone1.1.2":"iPhone (1.1.2/3B48b)",
		      "iPhone1.1.3":"iPhone (1.1.3/4A93)",
		      "iPhone1.1.4":"iPhone (1.1.4/4A102)",
		      "iPhone2.0":"iPhone (2.0/5A347)",
		      "iPhone2.0.1":"iPhone (2.0.1/5B108)",
		      "iPhone2.0.2":"iPhone (2.0.2/5C1)",
		      "iPhone2.1":"iPhone (2.1/5F136)",
		      "iPhone2.2":"iPhone (2.2/5G77)",
		      "iPhone2.2.1":"iPhone (2.2.1/5H11)",
		      "iPhone3.0":"iPhone (3.0/7A341)",
		      "iPhone3.0.1":"iPhone (3.0.1/7A400)",
		      "iPhone3.1":"iPhone (3.1/7C144)",
		      "iPhone3.1.2":"iPhone (3.1.2/7D11)",
		      "iPhone3.1.3":"iPhone (3.1.3/7E18)",
		      "iPhone 3G2.0.1":"iPhone 3G (2.0.1/5B108)",
		      "iPhone 3G2.0.2":"iPhone 3G (2.0.2/5C1)",
		      "iPhone 3G2.0":"iPhone 3G (2.0/5A347)",
		      "iPhone 3G2,1":"iPhone 3G (2.1/5F136)",
		      "iPhone 3G2.2":"iPhone 3G (2.2/5G77)",
		      "iPhone 3G2.2.1":"iPhone 3G (2.2.1/5H11)",
		      "iPhone 3G3.0.1":"iPhone 3G (3.0.1/7A400)",
		      "iPhone 3G3.0":"iPhone 3G (3.0/7A341)",
		      "iPhone 3G3.1":"iPhone 3G (3.1/7C144)",
		      "iPhone 3G3.1.2":"iPhone 3G (3.1.2/7D11)",
		      "iPhone 3G3.1.3":"iPhone 3G (3.1.3/7E18)",
		      "iPhone 3G4.0.1":"iPhone 3G (4.0.1/8A306)",
		      "iPhone 3G4.0":"iPhone 3G (4.0/8A293)",
		      "iPhone 3G4.1":"iPhone 3G (4.1/8B117)",
		      "iPhone 3G4.2":"iPhone 3G (4.2/8C148)",
		      "iPhone 3G4.2.1":"iPhone 3G (4.2.1/8C148)",
		      
		      "iPhone 3GS3.0.1":"iPhone 3GS (3.0.1/7A400)",
		      "iPhone 3GS3.0":"iPhone 3GS (3.0/7A341)",
		      "iPhone 3GS3.1":"iPhone 3GS (3.1.2/7D11)",
		      "iPhone 3GS3.1.2":"iPhone 3GS (3.1.2/7D11)",
		      "iPhone 3GS3.1.3":"iPhone 3GS (3.1.3/7E18)",
		      "iPhone 3GS4.0":"iPhone 3GS (4.0/8A293)",
		      "iPhone 3GS4.0.1":"iPhone 3GS (4.0.1/8A306)",
          "iPhone 3GS4.1":"iPhone 3GS (4.1/8B117)",	
          "iPhone 3GS4.2.1":"iPhone 3GS (4.2.1/8C148a)",	
          "iPhone 3GS4.3.1" :"iPhone 3GS (4.3.1/8G4)",
          "iPhone 3GS4.3.2":"iPhone 3GS (4.3.2/8H7)",
          "iPhone 3GS4.3.3":"iPhone 3GS (4.3.3/8J2)",
          "iPhone 3GS4.3.4":"iPhone 3GS (4.3.4/8K2)",
          "iPhone 3GS4.3.5":"iPhone 3GS (4.3.5/8L1)",
          "iPhone 3GS4.3":"iPhone 3GS (4.3/8F190)",
          "iPhone 3GS5.0":"iPhone 3GS (5.0/9A334)",
          "iPhone 3GS5.0.1":"iPhone 3GS (5.0.1/9A405)",
          
          "iPhone 44.0":"iPhone 4 (4.0/8A293)",
          "iPhone 44.0.1":"iPhone 4 (4.0.1/8A306)",
          "iPhone 44.1":"iPhone 4 (4.1/8B117)",
          "iPhone 44.2.1":"iPhone 4 (4.2.1/8C148)",
          "iPhone 44.3.1":"iPhone 4 (4.3.1/8G4)",
          "iPhone 44.3.2":"iPhone 4 (4.3.2/8H7)",
          "iPhone 44.3.3":"iPhone 4 (4.3.3/8J2)",
          "iPhone 44.3.4":"iPhone 4 (4.3.4/8K2)",
          "iPhone 44.3.5":"iPhone 4 (4.3.5/8L1)",
          "iPhone 45.0":"iPhone 4 (5.0/9A334)",
          "iPhone 45.0.1":"iPhone 4 (5.0.1/9A405)",
          "iPhone 4CDMA4.2.7":"iPhone 4 CDMA (4.2.7/8E303)",
          "iPhone 4CDMA4.2.8":"iPhone 4 CDMA (4.2.8/8E401)",
          "iPhone 4CDMA4.2.9":"iPhone 4 CDMA (4.2.9/8E50)",
          "iPhone 4CDMA5.0":"iPhone 4 CDMA(5.0/9A334)",
          "iPhone 4CDMA5.0.1":"iPhone 4 CDMA (5.0.1/9A405)",
          
          "iPhone 4S5.0":"iPhone 4S (5.0/9A334)",
          "iPhone 4S5.0.1":"iPhone 4S (5.0.1/9A405)",
          
          
          "iPad 2CDMA4.3.1 ":"iPad 2 CDMA (4.3.1/8G4)",
          "iPad 2CDMA4.3.2":"iPad 2 CDMA (4.3.2/8H8)",
          "iPad 2CDMA4.3.3":"iPad 2 CDMA (4.3.3/8J2)",
          "iPad 2CDMA4.3.4":"iPad 2 CDMA (4.3.4/8K2)",
          "iPad 2CDMA4.3.5":"iPad 2 CDMA (4.3.5/8L1)",
          "iPad 2CDMA4.3":"iPad 2 CDMA (4.3/8F191)",
          "iPad 2CDMA5.0":"iPad 2 CDMA (5.0/9A334)",
          
          "iPad 2GSM4.3.1":"iPad 2 GSM (4.3.1/8G4)",
          "iPad 2GSM4.3.2":"iPad 2 GSM (4.3.2/8H7)",
          "iPad 2GSM4.3.3":"iPad 2 GSM (4.3.3/8J2)",
          "iPad 2GSM4.3.4":"iPad 2 GSM (4.3.4/8K2)",
          "iPad 2GSM4.3.5":"iPad 2 GSM (4.3.5/8L1)",
          "iPad 2GSM4.3":"iPad 2 GSM (4.3/8F191)",
          "iPad 2GSM5.0":"iPad 2 GSM (5.0/9A334)",
          
          "iPad 2WIFI4.3.1":"iPad 2 Wi-Fi (4.3.1/8G4)",
          "iPad 2WIFI4.3.2":"iPad 2 Wi-Fi (4.3.2/8H7)",
          "iPad 2WIFI4.3.3":"iPad 2 Wi-Fi (4.3.4/8J2)",
          "iPad 2WIFI4.3.4":"iPad 2 Wi-Fi (4.3.4/8K2)",
          "iPad 2WIFI4.3":"iPad 2 Wi-Fi (4.3/8F191)",
          "iPad 2WIFI4.3.5":"iPad 2 WiFi (4.3.5/8L1)",
          "iPad 2WIFI5.0":"iPad 2 WiFi (5.0/9A334)",
          
          "iPad3.2.2":"iPad (3.2.2/7B500)",
          "iPad3.2":"iPad (3.2/7B367)",
          "iPad4.2.1":"iPad (4.2.1/8C148)",
          "iPad4.3.1":"iPad (4.3.1/8G4)",
          "iPad4.3.2":"iPad (4.3.2/8H7)",
          "iPad4.3.3":"iPad (4.3.3/8J2)",
          "iPad4.3.4":"iPad (4.3.4/8K2)",
          "iPad4.3.5":"iPad (4.3.5/8L1)",
          "iPad4.3":"iPad (4.3/8F190)",
          "iPad5.0":"iPad (5.0/9A334)",
          
          "iPod 4G4.1":"iPod Touch 4G (4.1/8B118)",
          "iPod 4G4.2.1":"iPod Touch 4G (4.2.1/8C148)",
          "iPod 4G4.3.1":"iPod Touch 4G (4.3.1/8G4)",
          "iPod 4G4.3.2":"iPod Touch 4G (4.3.2/8H7)",
          "iPod 4G4.3.3":"iPod Touch 4G (4.3.3/8J2)",
          "iPod 4G4.3.4":"iPod Touch 4G (4.3.4/8K2)",
          "iPod 4G4.3.5":"iPod Touch 4G (4.3.5/8L1)",
          "iPod 4G4.3":"iPod Touch 4G (4.3/8F190)",
          "iPod 4G5.0":"iPod Touch 4G (5.0/9A334)",
          
          "iPod 3G3.1.1":"iPod Touch 3G (3.1.1/7C145)",
          "iPod 3G3.1.2":"iPod Touch 3G (3.1.2/7D11)",
          "iPod 3G3.1.3":"iPod Touch 3G (3.1.3/7E18)",
          "iPod 3G4.0":"iPod Touch 3G (4.0/8A293)",
          "iPod 3G4.1":"iPod Touch 3G (4.1/8B117)",
          "iPod 3G4.2.1":"iPod Touch 3G (4.2.1/8C148)",
          "iPod 3G4.3.1":"iPod Touch 3G (4.3.1/8G4)",
          "iPod 3G4.3.2":"iPod Touch 3G (4.3.2/8H7)",
          "iPod 3G4.3.3":"iPod Touch 3G (4.3.3/8J2)",
          "iPod 3G4.3.4":"iPod Touch 3G (4.3.4/8K2)",
          "iPod 3G4.3.5":"iPod Touch 3G (4.3.5/8L1)",
          "iPod 3G4.3":"iPod Touch 3G (4.3/8F190)",
          "iPod 3G5.0":"iPod Touch 3G (5.0/9A334)"
          
          

			
					};
	var jsondata2 = {"name":"Apple TV 2G (4.1/8M89)", "value": "http://appldnld.apple.com/AppleTV/061-8940.20100926.Tvtnz/AppleTV2,1_4.1_8M89_Restore.ipsw"};
	
  var optionData2 = {"Apple TV 2G (4.1/8M89)": {"type":"Apple TV 2G (4.1/8M89)", "href": "http://appldnld.apple.com/AppleTV/061-8940.20100926.Tvtnz/AppleTV2,1_4.1_8M89_Restore.ipsw"}, 
					"Apple TV 2G (4.2.1/8C154)": {"type":"Apple TV 2G (4.1/8M89)", "href": "http://appldnld.apple.com/AppleTV/061-9978.20101214.gmabr/AppleTV2,1_4.2.1_8C154_Restore.ipsw"}};
/*	
	alert(optionData.length);
	alert(optionData[0].type);
	alert(optionData[0].dataList[0].name);
	alert(optionData[0].dataList[0].value);
	alert(optionData[1].type);
	alert(optionData[1].dataList[1].name);
	alert(optionData[1].dataList[1].value);
	var nvalue = jsonData.w10086s;
	alert(optionData2[nvalue].href);*/
	
	

 
	
	//alert("hello");
	
	$(document).ready(function() {
		
			var devType, devVersion,IPhoneCode;
//
	try {
		devType = external.GetIPhoneType();
		devVersion = external.GetIPhoneVersion();
		IPhoneCode=devType+devVersion;
	} catch(e) { }
	devType = !devType ? "" : devType;
	devVersion = !devVersion ? "" : devVersion;
	IPhoneCode=!IPhoneCode?"":IPhoneCode;
		
	
	devTypeSelBox = document.getElementById("firmware");
     var group=document.createElement('OPTGROUP'); 
	 group.label = "Apple TV";
	 devTypeSelBox.appendChild(group);
	 
	for(var i=0; i<optionData[0].dataList.length; i++)
	{
		// devTypeSelBox.add(new Option(optionData[i].dataList.name,optionData[i].dataList.value));
		  //alert(optionData[i].dataList[0].name);
		  var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[0].dataList[i].name;
          oOption.value = optionData[0].dataList[i].value;
		 
		  if( optionData[0].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }
		  
		//  alert(optionData[0].dataList[i].value);
	}


   var ipad1=document.createElement('OPTGROUP'); 
	 ipad1.label = "iPad 1";
	 devTypeSelBox.appendChild(ipad1);
	 
	 for( var i=0;i<optionData[1].dataList.length;i++)
	 {
	 	 var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[1].dataList[i].name;
          oOption.value = optionData[1].dataList[i].value;
		 
		  if( optionData[1].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }
	 	  
	 }
	 
	  var ipad2=document.createElement('OPTGROUP'); 
	 ipad2.label = "iPad 2";
	 devTypeSelBox.appendChild(ipad2);
	 
	 for( var i=0;i<optionData[2].dataList.length;i++)
	 {
	 	 var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[2].dataList[i].name;
          oOption.value = optionData[2].dataList[i].value;
		 
		  if( optionData[2].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }
	 	  
	 }
	 
	 
	   var iphone=document.createElement('OPTGROUP'); 
	 iphone.label = "iPhone";
	 devTypeSelBox.appendChild(iphone);
	 
	 for( var i=0;i<optionData[3].dataList.length;i++)
	 {
	 	 var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[3].dataList[i].name;
          oOption.value = optionData[3].dataList[i].value;
		 
		  if( optionData[3].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }
	 	  
	 }


 var iphone3g=document.createElement('OPTGROUP'); 
	 iphone3g.label = "iPhone 3G";
	 devTypeSelBox.appendChild(iphone3g);
	 
	 for( var i=0;i<optionData[4].dataList.length;i++)
	 {
	 	 var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[4].dataList[i].name;
          oOption.value = optionData[4].dataList[i].value;
		 
		  if( optionData[4].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }
	 	  
	 }
	 
	 var iphone3gs=document.createElement('OPTGROUP'); 
	 iphone3gs.label = "iPhone 3GS";
	 devTypeSelBox.appendChild(iphone3gs);
	 
	 for( var i=0;i<optionData[5].dataList.length;i++)
	 {
	 	 var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[5].dataList[i].name;
          oOption.value = optionData[5].dataList[i].value;
		 
		  if( optionData[5].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }
	 	  
	 }
	 
	 	 var iphone4=document.createElement('OPTGROUP'); 
	 iphone4.label = "iPhone 4";
	 devTypeSelBox.appendChild(iphone4);
	 
	 for( var i=0;i<optionData[6].dataList.length;i++)
	 {
	 	 var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[6].dataList[i].name;
          oOption.value = optionData[6].dataList[i].value;
		 
		  if( optionData[6].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }
	 	  
	 }
  
  
  	 	 var iphone4s=document.createElement('OPTGROUP'); 
	 iphone4s.label = "iPhone 4S";
	 devTypeSelBox.appendChild(iphone4s);
	 
	 for( var i=0;i<optionData[7].dataList.length;i++)
	 {
	 	 var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[7].dataList[i].name;
          oOption.value = optionData[7].dataList[i].value;
		 
		  if( optionData[7].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }
	 	  
	 }
	 
	 var ipod1=document.createElement('OPTGROUP'); 
	 ipod1.label = "iPod Touch 1G";
	 devTypeSelBox.appendChild(ipod1);
	 
	 for( var i=0;i<optionData[8].dataList.length;i++)
	 {
	 	 var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[8].dataList[i].name;
          oOption.value = optionData[8].dataList[i].value;
		 
		  if( optionData[8].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }
	 	  
	 }
	 
	 	 var ipod2=document.createElement('OPTGROUP'); 
	 ipod2.label = "iPod Touch 2G";
	 devTypeSelBox.appendChild(ipod2);
	 
	 for( var i=0;i<optionData[9].dataList.length;i++)
	 {
	 	 var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[9].dataList[i].name;
          oOption.value = optionData[9].dataList[i].value;
		 
		  if( optionData[9].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }
	 	  
	 }
  
  
   var ipod3=document.createElement('OPTGROUP'); 
	 ipod3.label = "iPod Touch 3G";
	 devTypeSelBox.appendChild(ipod3);
	 
	 for( var i=0;i<optionData[10].dataList.length;i++)
	 {
	 	 var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[10].dataList[i].name;
          oOption.value = optionData[10].dataList[i].value;
		 
		  if( optionData[10].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }
	 	  
	 }
	 
	   
   var ipod4=document.createElement('OPTGROUP'); 
	 ipod4.label = "iPod Touch 4G";
	 devTypeSelBox.appendChild(ipod4);
	 
	 for( var i=0;i<optionData[11].dataList.length;i++)
	 {
	 	 var oOption = document.createElement("OPTION");
          devTypeSelBox.options.add(oOption);
          oOption.innerText = optionData[11].dataList[i].name;
          oOption.value = optionData[11].dataList[i].value;
		 
		  if( optionData[11].dataList[i].name==jsonData[IPhoneCode])
		  {
			  oOption.selected=true;
		  }  
	 }
   })