I want to make a function to show and hide a div tag and hide all others:
function showPage(showdiv){ $(\'#midRight\').not(showdiv).hide(); $(showdi
DEMO
function showPage(showdiv){ $(showdiv).show().siblings().hide(); }
Or, without using IDs:
$('ul a').click(function() { var index = $(this).index(); $('#midRight > div').hide().eq(index).show(); });