Determine Browser Type

[Total: 0    Average: 0/5]

This shows how to search a string for the browser type and then take appropriate action.

Body Code:

<script type=text/javascript>
if (navigator.appName.toUpperCase().match(/MICROSOFT INTERNET EXPLORER/) != null)
  document.write("You are using IE.");
if (navigator.appName.toUpperCase().match(/NETSCAPE/) != null)
  document.write("You are using NS.");
</script>

Times Viewed: 6

Leave a Reply

Your email address will not be published. Required fields are marked *