topical media & game development 
  
 
 
 
 
  
    
    
  
 basic-javascript-appendix-5-IEOnly.htm / htm
  <HTML>
  <HEAD>
  <SCRIPT>
  
  function getBrowserName()
  {
     var lsBrowser = navigator.appName;
     if (lsBrowser.indexOf("Microsoft") >= 0)
     {
        lsBrowser = "MSIE";
     }
     else if (lsBrowser.indexOf("Netscape") >= 0)
     {
        lsBrowser = "NETSCAPE";
     }
     else
     {
        lsBrowser = "UNKNOWN";
     }
     return lsBrowser;
  }
  
  function checkBrowser()
  {
     if (getBrowserName() == "NETSCAPE")
     {
        window.location.replace("NNOnly.htm");
     }
  }
  
  </SCRIPT>
  </HEAD>
  <BODY ONLOAD="checkBrowser()">
  
  <H2>Welcome to the Internet Explorer only page</H2>
  
  </BODY>
  </HTML>
  
  
  
(C) Æliens 
20/2/2008
You may not copy or print any of this material without explicit permission of the author or the publisher. 
In case of other copyright issues, contact the author.