Operating System Deduction

Operating system deduction javascript is used in order to find which operating system we are working with.

Features

  • You can find which operating system you are working with.
  • You can also find the name of the operating system using this javascript.
  • Just copy the code from the given textarea and use it.

Preview

Downloads

Javascript Code
<!-- Script by hscripts.com -->
<script type="text/javascript">
function os()
{
var os = navigator.platform;
os = os.toLowerCase();
if(os == "win32" || os == "win16")
{
document.osd.opr.value="You are using Windows operating system";
}
else if(os.indexOf("linux") >= 0)
{
document.osd.opr.value="You are using Linux operating system";
}
else if(os.indexOf("mac") >= 0)
{
document.osd.opr.value="You are using Mac operating system";
}
}
</script>
<!-- Script by hscripts.com -->

HTML Code
<table border=0 align=center width=48%>
<tr>
<td>
<body onload="os()">
<form name=osd>
<input type=text name=opr size=40 style="position: absolute; background-color:#454545; text-align:center; color:white; font-family:arial,verdhana; font-weight:bold;">
</form>
</body>
</td>
</tr>
</table>
  • Get free version without ©copyright link for just $10/-
  • For customization of this script or any script development, mail to support@hscripts.com

Usage

  • Here we have explained with form
  • Creating a form
  • <body onload="os()">
       <form name=osd>
       <input type=text name=opr size=40 style="position: absolute;
       background-color:#454545; text-align:center; color:white;
       font-family:arial,verdhana; font-weight:bold;">
       </form></body>
  • Here <body onload="os()"> is used in order to display the name of operating system whenever the form is loaded.
  • In javascript "navigator.platform" will results the name of operating system you are using.
  • Copy the code and use it.

License

Related Scripts

Free Javascript Scripts


Ask Questions

Ask Question