The javascript is a contribution from the forum :
http://www.codingforums.com/showthread.php?t=10114
What the script does is, when you enter the user name and password - and click login - it checks for a 'pre'created UsernamePassword.js file.
Once it finds it, it redirects to auth.htm
Code:
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" >
<head>
<title>Authorization in progress...</title>
<script type="text/javascript">
<!--
var authstring = "<script type=\"text/javascript\" src=\"" + location.search.substring(1) + ".js\"><\/script>";
if (location.search) document.write(authstring);
// -->
</script>
</head>
<body>
<script type="text/javascript">
<!--
window.auth ? location.replace(redirect) : location.replace("login.htm?auth=failed");
// -->
</script>
</body>
</html>
and redirects you to the target/admin page.
its quite smart, tbh.