var domain_name = "moneyhub.cn";
$(function () {
		
	//检测系统没有微软雅黑字体
	if ($("#font1").width() == $("#font2").width()) {
		//没有微软雅黑
		$("#headerProduct").css("background", "url(http://img.moneyhub.cn/tree.gif) no-repeat 40px 6px");
	} else {
		//有微软雅黑
		$("#headerProduct").css("background", "url(http://img.moneyhub.cn/tree.gif) no-repeat 40px 9px");
	}

	domain_name = document.domain.substr(4);
	$(".menu li#" + $("#currentMenu").val() + " .amenu").removeClass("other").addClass("current");
	$("img").each(function () {
		$(this).attr("src", $(this).attr("src").replace(/moneyhub\.cn/g, domain_name));
	});
	$("div").each(function () {
		if ($(this).attr("style")) {
			$(this).attr("style", $(this).attr("style").replace(/moneyhub\.cn/g, domain_name));
		}
	});
	$("a").each(function () {
		if ($(this).attr("style")) {
			$(this).attr("style", $(this).attr("style").replace(/moneyhub\.cn/g, domain_name));
		}
	});
	$("dd").each(function () {
		if ($(this).attr("style")) {
			$(this).attr("style", $(this).attr("style").replace(/moneyhub\.cn/g, domain_name));
		}
	});					
});

