$(function() {

getHotlink();

function getHotlink()
{

	$url = "http://"+top.location.host+"/dls/hotlink-corporate.xml";
	$.ajax({
		type: "GET",
		url: $url,
		dataType: "xml",
		success: function(xml) {
			$(xml).find('category').each(function(){				
				
				  $id = $(this).find('id').text();
				  $title = $(this).find('title').text();
			  	 
		          switch ($id)
				  {
					case "1":
					  $("#category1").html($title);
					  break;
					case "2":  
					  $("#category2").html($title);
					  break;
					case "3":  
					  $("#category3").html($title);
					  break;
					case "4":  
					  $("#category4").html($title);
					  break;
					case "5":  
					  $("#category5").html($title);
					  break;
					case "6":  
					  $("#category6").html($title);
					  break;
					case "7":  
					  $("#category7").html($title);
					  break;					
					case "8":  
					  $("#category8").html($title);
					  break;
					case "9":  
					  $("#category9").html($title);
					  break;
					case "10":  
					  $("#category10").html($title);
					  break;
					case "11":  
					  $("#category11").html($title);
					  break;
					case "12":  
					  $("#category12").html($title);
					  break;
					case "13":  
					  $("#category13").html($title);
					  break;
}		


				}); // end each
			
			$(xml).find('link').each(function(){				
	
				  $id = $(this).find('id').text();
				  $title = $(this).find('title').text();
				  $url = $(this).find('url').text();
				  $link = "";
				  
				  if ($title != "")
				  {
				  $link = '<a href = "'+$url+'">'+$title+'</a>';
				  }
				  
		          switch ($id)
				  {
				case "1":
$dv = $("#hotlink1");
break;
case "2":
$dv = $("#hotlink2");
break;
case "3":
$dv = $("#hotlink3");
break;
case "4":
$dv = $("#hotlink4");
break;
case "5":
$dv = $("#hotlink5");
break;
case "6":
$dv = $("#hotlink6");
break;
case "7":
$dv = $("#hotlink7");
break;
case "8":
$dv = $("#hotlink8");
break;
case "9":
$dv = $("#hotlink9");
break;
case "10":
$dv = $("#hotlink10");
break;
case "11":
$dv = $("#hotlink11");
break;
case "12":
$dv = $("#hotlink12");
break;
case "13":
$dv = $("#hotlink13");
break;
case "14":
$dv = $("#hotlink14");
break;
case "15":
$dv = $("#hotlink15");
break;
case "16":
$dv = $("#hotlink16");
break;
case "17":
$dv = $("#hotlink17");
break;
case "18":
$dv = $("#hotlink18");
break;
case "19":
$dv = $("#hotlink19");
break;
case "20":
$dv = $("#hotlink20");
break;
case "21":
$dv = $("#hotlink21");
break;
case "22":
$dv = $("#hotlink22");
break;
case "23":
$dv = $("#hotlink23");
break;
case "24":
$dv = $("#hotlink24");
break;
case "25":
$dv = $("#hotlink25");
break;
case "26":
$dv = $("#hotlink26");
break;
case "27":
$dv = $("#hotlink27");
break;
case "28":
$dv = $("#hotlink28");
break;
case "29":
$dv = $("#hotlink29");
break;
case "30":
$dv = $("#hotlink30");
break;
case "31":
$dv = $("#hotlink31");
break;
case "32":
$dv = $("#hotlink32");
break;
case "33":
$dv = $("#hotlink33");
break;
case "34":
$dv = $("#hotlink34");
break;
case "35":
$dv = $("#hotlink35");
break;
case "36":
$dv = $("#hotlink36");
break;
case "37":
$dv = $("#hotlink37");
break;
case "38":
$dv = $("#hotlink38");
break;
case "39":
$dv = $("#hotlink39");
break;
case "40":
$dv = $("#hotlink40");
break;
case "41":
$dv = $("#hotlink41");
break;
case "42":
$dv = $("#hotlink42");
break;
case "43":
$dv = $("#hotlink43");
break;
case "44":
$dv = $("#hotlink44");
break;
case "45":
$dv = $("#hotlink45");
break;
case "46":
$dv = $("#hotlink46");
break;
case "47":
$dv = $("#hotlink47");
break;
case "48":
$dv = $("#hotlink48");
break;
case "49":
$dv = $("#hotlink49");
break;
case "50":
$dv = $("#hotlink50");
break;
case "51":
$dv = $("#hotlink51");
break;
case "52":
$dv = $("#hotlink52");
break;
case "53":
$dv = $("#hotlink53");
break;
case "54":
$dv = $("#hotlink54");
break;
case "55":
$dv = $("#hotlink55");
break;
case "56":
$dv = $("#hotlink56");
break;
case "57":
$dv = $("#hotlink57");
break;
case "58":
$dv = $("#hotlink58");
break;
case "59":
$dv = $("#hotlink59");
break;
case "60":
$dv = $("#hotlink60");
break;
case "61":
$dv = $("#hotlink61");
break;
case "62":
$dv = $("#hotlink62");
break;
case "63":
$dv = $("#hotlink63");
break;
case "64":
$dv = $("#hotlink64");
break;
case "65":
$dv = $("#hotlink65");
break;
}		

$dv.html($link);
if ($dv.html() == "")
{
$dv.remove();
}

}); // end each
		}
		

	});
}






		});
		
		
		
