Forum Moderators: open
<script type="text/javascript">
<!--
var WinNetwork = new ActiveXObject("WScript.Network");
alert(WinNetwork.UserName);
//-->
</script>
Generally speaking, this type of js is only suitable for intranets and similar kinds of usage where you can know what is installed and/or set security permissions appropriately. IE will quite rightly block access to this by default.