			// *** Opciones de HM4 *** (m2) Gate
				
		
				// *** función cpais (m2)
				function cpais(pais) {
							var x = new Date(2004,12,31)
					switch (pais) {
						case ("Usa"):
							mG('aps','Usa', x)
							top.location.href = "http://www.thegatewaytointernet.com/usa"
						 break
						case ("Uk"):
							mG('aps','Uk', x)
							top.location.href = "http://www.thegatewaytointernet.com/uk"
						 break
					}		
				}



				// ** aps
				function aps(){
				aps = consG("aps") 
				switch (aps) {
						case ("Uk"): 
							cpais('Uk');
						 break
						case ("Usa"):
							cpais('Usa');
						 break
			 }
				}




				function consG(nombre) {
				  var buscamos = nombre + "=";
				  if (document.cookie.length > 0) {
    				i = document.cookie.indexOf(buscamos);
    				if (i != -1) {
    				  i += buscamos.length;
      				  j = document.cookie.indexOf(";", i);
      				  if (j == -1)
        				j = document.cookie.length;
					   return unescape(document.cookie.substring(i,j));
    				 }
  					}
				   }

				function mG(nom, val, cad) {
  					document.cookie = nom + "=" + escape(val)
				    + ((cad == null) ? "" : ("; expires=" + cad.toGMTString()))
				}


