﻿jQuery(function($) {

    // Enable the javascript-based main menu system
    $("#multi-level li")
        .hover(
            function() {
                $(this).addClass("active");
            },
            function() {
                $(this).removeClass("active");
            })
        .find("ul.sub li ul").parent("li").addClass("iefix");

    var defaultUsername = "Username";
    var defaultPassword = "Password";
    $("#username")
        .val(defaultUsername)
        .focus(function() {
            var $this = $(this);
            if ($this.val() == defaultUsername) {
                $this.val(""); // Clear out the default username
            }
        })
        .blur(function() {
            var $this = $(this);
            if ($this.val() == "") {
                $this.val(defaultUsername);
            }
        });

    $("#password")
        .val(defaultPassword)
        .focus(function() {
            var $this = $(this);
            if ($this.val() == defaultPassword) {
                $this.val(""); // Clear out the default password
            }
        })
        .blur(function() {
            var $this = $(this);
            if ($this.val() == "") {
                $this.val(defaultPassword);
            }
        });
});