I have a page that's content is already inside a tab, and don't want to use a tab inside a tab. There will be 4 years 2010, 2009, 2008, 2007 that are anchors across the top of the #content div. When you click a year, it should load the specific content via jQuery's ajax load functionality into the div#content. That is easy enough. Is it possible to make a click function that will hide whatever is currently visible and display the appropriate content?
$("a#foo").click(function(){
$("#Year10").load("2010.php #content");
$("#Year09, #Year08, #Year07").hide();
});
I guess what I'm asking is it possible to make it hide anything that currently is in the #content div and show the appropriate div? Would this be better with the content being external pages or div's that are hidden on load?
thx