$(document).ready(function () {

    $(".blackwhite ul li").hover(function () { //On hover...
        var img = $(this).find("img");

        var thumbOver = img.attr("src"); //Get image url and assign it to 'thumbOver'

        $(this).width(img.width());

        $(this).find("a").css({ 'background': 'url(' + thumbOver + ') no-repeat left bottom' });

        $(this).find("span").stop().fadeTo('normal', 0, function () {
            $(this).hide() //Hide the image after fade
        });
    }, function () { //on hover out...
        $(this).find("span").stop().fadeTo('normal', 1).show();
    });
});

function clickclear(thisfield, defaulttext) {
	if (thisfield.value == defaulttext) {
	    thisfield.value = "";
	}
}

function clickrecall(thisfield, defaulttext) {
    if (thisfield.value == "") {
        thisfield.value = defaulttext;
    }
}

function ToggleArea(id) {
    if ($("#item_" + id).is(":visible")) {
        $("#item_" + id).slideUp('fast');
        $("#span_" + id).html('+');

    } else {
        $("#item_" + id).slideDown('fast');
        $("#span_" + id).html('-');
    }
}
