function WindowPopup (url,width,height,addparam) {
	w = (width=="")?800:width;
	h = (height=="")?600:height;
	param = (addparam=="")?"scrollbars=yes,resizable=yes":addparam;
	window.open(url, "PopUp", "width="+w+",height="+h+",scrollbars=yes,resizable=yes");
}

function clearDefaultText() {
	if ($('#q').val() == 'Find a solution to your problem here') {
		$('#q').val('');
	}
}

function replaceDefaultText() {
	if ($('#q').val() == '') {
		$('#q').val(defaultText);
	}
}

function balanceColumns() {
	if ($('.blueBody').height() > $('.rightDiv').height()) {
		$('.rightDiv').height($('.blueBody').height());
	} else {
		$('.blueBody').height($('.rightDiv').height());
	}
}

$(document).ready(function() {
	//Search Box
	defaultText = $('#q').val();
	$('#q').focus(clearDefaultText);
	$('#q').blur(replaceDefaultText);
	//Solution Center Images
	$('.scImage').wrap("<div class='productimage'></div>");
	$('.scImage').parent().parent().parent().parent().addClass("productCell");
	if ($('.productCell').height() < 230) {
		$('.productCell').height("230px;");
	}
	//Place rounded corners on boxes
	$('.blueBody').corner("7px");
	$('div.whitebox').corner("5px");
	$('.lightbluebox').corner("5px");
	$('.yellowbox').corner("5px");
	$('.rightDiv').corner("7px");
	//Balance columns
	balanceColumns();
	//DHTML Nav
	$(function() {  
		if ($.browser.msie && parseInt($.browser.version)< 7) {  
			$("#tabs li").hover(  
			function() {  
				$(this).addClass("sf");  
			},  
			function() {  
				$(this).removeClass("sf");  
			});  
		}  
	});
	//var sfEls = document.getElementById("nav").getElementsByTagName("LI");
	//for (var i=0; i<sfEls.length; i++) {
	//	sfEls[i].onmouseover=function() {
	//		this.className+=" sfhover";
	//	}
	//	sfEls[i].onmouseout=function() {
	//		this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
	//	}
	//}
 });