To detect the Operating System on the Client Machine, your script should analyze the navigator.appVersion string. Below is a simple example of a script that sets the variable OSName to reflect the actual client OS.paste this script after the <Title> Tag of the <Head> Tag of the Page.
1: <script language=”javascript” type=”text/javascript”>
[...]