// Set the initial height 
var sliderHeight = "66px"; 

$(document).ready(function(){ 
    // Show the slider content 
    $('.slider').show(); 
     
    $('.slider').each(function () { 
        var current = $(this); 
        current.attr("box_h", current.height()); 
    }); 
     
    $(".slider").css("height", sliderHeight); 
}); 
 
// Set the initial slider state 
var slider_state = "close"; 

function sliderAction() 
{ 
    if (slider_state == "close") 
    { 
        sliderOpen(); 
        slider_state = "open" 
        $(".slider_menu").html('<div id="m_right"><a href="#" onclick="return sliderAction();">- show less -</a></div>');   
    } 
	else if (slider_state == "open") 
    { 
        sliderClose(); 
        slider_state = "close"; 
        $(".slider_menu").html('<div id="m_left">...</div><div id="m_right"><a href="#" onclick="return sliderAction();">+ show more +</a></div>');
    } 
     
    return false; 
} 

function sliderOpen() 
{ 
    var open_height = $(".slider").attr("box_h") + "px"; 
    $(".slider").animate({"height": open_height}, {duration: "slow" }); 
} 

function sliderClose() 
{ 
    $(".slider").animate({"height": sliderHeight}, {duration: "slow" }); 
}
