$(document).ready(function(){
$windowHeight = document.body.clientHeight;
$pageHeight = $("body").height();
$headerHeight = $("#header").height();
$footerHeight = $("#footer").height();
$contentHeight = $("#center").height();
$subnavHeight = $("#subnav").height();
$leftHeight = $("#left").height();
$currentHeight = $headerHeight + $footerHeight +$subnavHeight +$contentHeight;
$difference = $windowHeight - $currentHeight;
$newHeight = $difference + $contentHeight -26;
if($difference > 0) {
$('#center').height($newHeight +'px');
}
$("div#wrapper").wrap('<div id="wrapper1"><div id="wrapper2"></div></div>');
leftie();

$('#breadcrumbs a').each(function(){
$('#categoriesmenu a[href="'+$(this).attr('href')+'"]').addClass('current');
});

$('#breadcrumbs strong').each(function(){
$('#categoriesmenu a:contains(' +$(this).text() +')').addClass('current');
});

});

function leftie() {
$contentHeight = $("#center").height();
$leftHeight = $("#left").height();
if($contentHeight > $leftHeight) {
$('#categoriesmenu').height($contentHeight);
}
}
