// Initialize all variables we're using for each <div> element
// Input is the id name
function sliderInit(objId, imgLoc)
{
	$("#" + objId).data("sliderHeight", "70px");
	$("#" + objId).data("slider_state", "close");
	$("#" + objId).data("open_height", "200px");
	$("#" + objId).data("image", imgLoc);

	$("#" + objId).css("height", $("#" + objId).data("sliderHeight")); 
	$("#" + objId).css("width", "24.3em"); 
	$("#" + objId).css("position", "absolute"); 
	$("#" + objId).css("bottom", "0.28em"); 
	$("#" + objId).css("background-image", "url('http://community-lab.org/om/skimg/blackbox.png')"); 
}

$(document).ready(function(){ 
    // Show the slider content 
    $('.slider').show(); 
}); 

// Open the slider
// If it is in the process of closing, cancel that animation and start
// expaning it back up
function sliderOpen(obj) 
{ 
    $("#" + obj.id).stop(true).animate({"height": $("#" + obj.id).data("open_height")}, {duration: "slow" }); 
} 
 
// Close the slider
function sliderClose(obj) 
{ 
    $("#" + obj.id).animate({"height": $("#" + obj.id).data("sliderHeight")}, {duration: "slow" }); 
}

