// JScript 文件
////////////////////20111207fenxiang//////////////////////////////////////////////////////////////////////////////////////////////
function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function MM_showHideLayers() { //v9.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) 
  with (document) if (getElementById && ((obj=getElementById(args[i]))!=null)) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }
    obj.visibility=v; }
}
function FenSi()
{
    var s=s_gi(s_account);

    //s.linkTrackVars='eVar1,event5'; 
    s.linkTrackVars = 'eVar1,events';

    //s.linkTrackEvents = 'event5';
    s.linkTrackEvents = 'events';

    //s.events = 'event5'; 
    s.events = 'events'; 

    s.eVar1=s.pageName; 

    s.tl(this,'o','加入粉丝');


}

//定义Title内容
var titleContent= document.title ;  
titleContent=titleContent.substring(titleContent.lastIndexOf('_')+1);

function share_to(m) {
  if (m == "tsina") {//新浪微博
		void ((function(s, d, e) {
			try {
			} catch (e) {
			}
			var f = 'http://v.t.sina.com.cn/share/share.php?', u = d.location.href, p = [
					'url=', e(u), '&title=', e(encodeURIComponent(titleContent)), '&appkey=930576029' ]
					.join('');
			function a() {
				if (!window
						.open(
								[ f, p ].join(''),
								'mb',
								[
										'toolbar=0,status=0,resizable=1,width=620,height=450,left=',
										(s.width - 620) / 2, ',top=',
										(s.height - 450) / 2 ].join('')))
					u.href = [ f, p ].join('');
			}
			;
			if (/Firefox/.test(navigator.userAgent)) {
				setTimeout(a, 0)
			} else {
				a()
			}
		})(screen, document, encodeURIComponent));
	}  else if (m == "douban") { //豆瓣网
		void (function() {
			var d = document, e = encodeURIComponent, s1 = window.getSelection, s2 = d.getSelection, s3 = d.selection, s = s1 ? s1()
					: s2 ? s2() : s3 ? s3.createRange().text : '', r = 'http://www.douban.com/recommend/?url='
					+ e(d.location.href.toLowerCase().indexOf('appserver')>=0 ?d.location.href :"http://appserver.lenovo.com.cn"+d.location.href.substr(d.location.href.indexOf('/',8)))
					+ '&title='
					+ encodeURIComponent(titleContent)
					+ '&sel='
					+ e(s) + '&v=1', x = function() {
				if (!window
						.open(r, 'douban',
								'toolbar=0,resizable=1,scrollbars=yes,status=1,width=450,height=355,left='
									+ (screen.width - 450) / 2 + ',top='
									+ (screen.height - 330) / 2))
					location.href = r + '&r=1'
			};
			if (/Firefox/.test(navigator.userAgent)) {
				setTimeout(x, 0)
			} else {
				x()
			}
		})();

	} else if (m == "renren") {//人人网	
			// 官方分享方式1
		var connect_url = "http://www.connect.renren.com";
		var url = window.location.href;
		var addQS = function(url, qs) {
			var a = [];
			for ( var k in qs)
				if (qs[k])
					a.push(k.toString() + '=' + encodeURIComponent(qs[k]));
			return url + '?' + a.join('&');
		}
		var href = addQS(connect_url + '/sharer.do', {
			'url' : url,
			'title' : url == window.location.href ? titleContent : null
		});
		window.open(href, 'sharer',
				'toolbar=0,status=0,width=550,height=400,left='
						+ (screen.width - 550) / 2 + ',top='
						+ (screen.height - 500) / 2);

	// 官方分享方式2
//		 void ((function(s, d, e) {
//		 if (/renren\.com/.test(d.location))
//		 return;
//		 
//		 var fp="http://share.renren.com/share/buttonshare.do?link="+"http://appserver.lenovo.com.cn/Lenovo_Product_detail.aspx?CategoryCode=A03B07C13&gdsid=A0300014365"+"&title="+encodeURIComponent(document.title);
//		 
//		 function a() {
//		 if (!window
//		 .open(
//		 fp,
//		 'xnshare',
//		 [
//		 'toolbar=0,status=0,resizable=1,width=626,height=436,left=',
//		 (s.width - 626) / 2, ',top=',
//		 (s.height - 436) / 2 ].join('')))
//		 u.href = [ f, p ].join('');
//		 }
//		 ;
//		 if (/Firefox/.test(navigator.userAgent))
//		 setTimeout(a, 0);
//		 else
//		 a();
//		 })(screen, document, encodeURIComponent));
	} else if (m == "kaixin001") {//开心网
		var kw = window
				.open(
						'',
						'kaixin001',
						'toolbar=no,titlebar=no,status=no,menubar=no,scrollbars=no,location:no,directories:no,width=570,height=350,left='
								+ (screen.width - 570)
								/ 2
								+ ',top='
								+ (screen.height - 420) / 2);
		var tempForm = kw.document.createElement('form');
		function openPostWindow(url, data, name) {
			var tempForm = document.createElement('form');
			tempForm.id = 'tempForm1';
			tempForm.method = 'post';
			tempForm.action = url;
			tempForm.target = 'kaixin001';
			var hideInput = document.createElement('input');
			hideInput.type = 'hidden';
			hideInput.name = 'rcontent';
			hideInput.value = data;
			tempForm.appendChild(hideInput);
			document.body.appendChild(tempForm);
			tempForm.submit();
			document.body.removeChild(tempForm);
		}
		function add2Kaixin001() {
			var u = document.location.href;
			var t = titleContent;
			var c = '' + (document.getSelection ? document.getSelection()
					: document.selection.createRange().text);
			var iframec = '';
			var url = 'http://www.kaixin001.com/repaste/bshare.php?rtitle='
					+ encodeURIComponent(t) + '&rurl=' + encodeURIComponent(u)
					+ '&from=maxthon';
			var data = encodeURIComponent(c);
			openPostWindow(url, c, '_blank')
		}
		add2Kaixin001();
	}   else if (m == "qzone") {//Q空间
		window.open(
				"http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?url="
						+ encodeURIComponent(document.location)+'&title='+ encodeURIComponent(titleContent), 'qzone',
				'toolbar=0,status=0,width=900,height=760,left='
						+ (screen.width - 900) / 2 + ',top='
						+ (screen.height - 760) / 2);
	} else if (m == "qqv") {// QQ腾讯微博
		window.open(
				"http://v.t.qq.com/share/share.php?url="
						+ encodeURIComponent(document.location) 
						+'&title='+ encodeURIComponent(titleContent)
						+'&appkey=c708221677c64e1085de3195afaa7837', 'v',
				'toolbar=0,status=0,width=900,height=760,left='
						+ (screen.width - 900) / 2 + ',top='
						+ (screen.height - 760) / 2);
	}
	else if (m == "sohu") {// 搜狐微博
		window.open(
				"http://t.sohu.com/third/post.jsp?&url="
						+ encodeURIComponent(document.location) 
						+'&title='+ encodeURIComponent(titleContent)
						+'&content=utf-8&pic=', 'v',
				'toolbar=0,status=0,width=900,height=760,left='
						+ (screen.width - 900) / 2 + ',top='
						+ (screen.height - 760) / 2);
	} 

	return false;
}
///////////////////////////////////////////////////////////////////////////////////////////////////

document.write("<div class='bottom_links'>")
if (location.pathname.indexOf('shop') == -1) {
    document.write("<span style='margin-top:6px;padding-left:13px;float:left;color:#949599;'>快速查询离您最近的<a href='http://appserver.lenovo.com.cn/LenovoMap/LenovoMap.aspx' target='_blank'><u>联想销售店面</u></a>和<a href='http://appserver.lenovo.com.cn/LenovoMap/LenovoMap_Service.aspx' target='_blank'><u>维修网点</u></a></span>")
}
document.write("<a href='http://www.lenovo.com.cn/Public/public_bottom/contact.shtml' target='_blank'>联系我们</a> | ")
document.write("<a href='http://appserver.lenovo.com.cn/about/job/cn/default.shtml' target='_blank'>工作机会<a> | ")
document.write("<a href='http://appserver.lenovo.com.cn/partner/search.aspx' target='_blank'>合作伙伴认证</a> | ")
document.write("<a href='http://appserver.lenovo.com.cn/About/' target='_blank'>关于联想</a>")
if (location.pathname.indexOf('shop') == 1) {
    document.write(" | <a href='../Lenovo_help_fq.aspx' target='_blank'>在线帮助</a>")

}
document.write("</div>")
document.write("<div class='copyright'>")

 
/////////////////////20111207fenxiang/////////////////////////////////////////////////////////////////
if(location.pathname.toLowerCase().indexOf('shop')==-1)
{
document.write("<div class=\"share_fans_div\">")

if(location.pathname.toLowerCase().indexOf("lenovo_mobile_detail")>=0 || location.pathname.toLowerCase().indexOf("lenovo_product_detail")>=0)//AddFenXiang
{
document.write("<ul class=\"share_ul\" onmouseover=\"MM_showHideLayers('share_div','','show')\" onmouseout=\"MM_showHideLayers('share_div','','hide')\">")
document.write("<div id=\"share_div\">")
document.write("<div class=\"title\">分享到...</div>")
document.write("<ol>")
//document.write("<li class=\"s_email\"><a href=\"#\" >寄给朋友</a></li>")
//document.write("<li class=\"s_copy\"><a href=\"#\">复制地址</a></li>")
document.write("<li class=\"s_weibo\"><a href=\"#\" onclick=\"share_to(\'tsina\');return false;\">新浪微博</a></li>")
//document.write("<li class=\"s_msn\"><a href=\"#\">MSN</a></li>")
document.write("<li class=\"s_kaixin001\"><a href=\"#\"  onclick=\"share_to(\'kaixin001\');return false;\">开心网</a></li>")
document.write("<li class=\"s_renren\"><a href=\"#\"  onclick=\"share_to(\'renren\');return false;\">人人网</a></li>")
document.write("<li class=\"s_tencent\"><a href=\"#\"  onclick=\"share_to(\'qqv\');return false;\">腾讯微博</a></li>")
//document.write("<li class=\"s_163\"><a href=\"#\">网易微博</a></li>")
document.write("<li class=\"s_sohu\"><a href=\"#\"  onclick=\"share_to(\'sohu\');return false;\">搜狐微博</a></li>")
//document.write("<li class=\"s_baidu_k\"><a href=\"#\">百度空间</a></li>")
//document.write("<li class=\"s_baidu_t\"><a href=\"#\">百度贴吧</a></li>")
document.write("<li class=\"s_douban\"><a href=\"#\"  onclick=\"share_to(\'douban\');return false;\">豆瓣网</a></li>")
document.write("<li class=\"s_qq_k\"><a href=\"#\"  onclick=\"share_to(\'qzone\');return false;\">Qzone</a></li>")
//document.write("<li class=\"s_feixin_k\"><a href=\"#\">豆瓣网</a></li>")
document.write("</ol>")
document.write("</div>")
document.write("<li class=\"share_icon\">&nbsp;</li>")
document.write("<li class=\"share_text\">分享到</li>")
document.write("</ul>")
}
document.write("<ul class=\"fans_ul\">")
document.write("<li class=\"fans_icon\">&nbsp;</li>")
document.write("<li class=\"fans_text\"><a  target=\"_blank\" href=\"http://weibo.com/lenovo\"  onclick='FenSi()'>成为联想粉丝</a></li>")
document.write("</ul>")
document.write("</div>")
}
///////////////////////////////////////////////////////////////////////////////////////////////////////////////  

document.write("版权所有：1998-2012 联想集团&nbsp; &nbsp;| ")
document.write("<a href='http://www.lenovo.com.cn/Public/public_bottom/legal.shtml' target='_blank'>法律公告<a> | ")
document.write("<a href='http://www.lenovo.com.cn/Public/public_bottom/privacy.shtml' target='_blank'>隐私保护</a>")
document.write("&nbsp; &nbsp;<a href='http://www.miibeian.gov.cn/' target='_blank'>京ICP备05000462</a>")

document.write("</div>") 
