jQuery.preloadImages = function()
{
  for(var i = 0; i<arguments.length; i++)
  {
    jQuery("<img>").attr("src", arguments[i]);
  }
};

function isdefined(variable)
{
	return (typeof(window[variable]) != "undefined");
}


/* 
	Use this function instead of $.load
	This turns off caching of pages and politely waits until the page is loaded
*/
function load_into_div(div, url) {
	var content = load_val(url);
        $(div).html(content);
}

function load_val(url) { 
        var content = $.ajax({
                url: url, 
                cache: false,
                async: false
        }).responseText;
	return content;
}



$(document).ready(function() {
	$("#return-to-work").click(function() {
		if ($("#work-icons").is(":visible")) { 
			$("#work-icons").slideUp(350);
		} else { 
			$("#work-icons").slideDown(350);
		}
		return false;
	});
});

