$(function (){ var key = getcookie('key'); var memberHtml = '登录QQ登陆注册'; var act = GetQueryString("act"); if((act && act == "member") || key!=''){ memberHtml = '个人中心注销'; } var tmpl = ''; var tmpl2 = '
' +'
' +'' +'
' +'' +'' +'' +'
' +''; var render = template.compile(tmpl); var html = render(); $("#footer").html(html+tmpl2); //回到顶部 $(".gotop").click(function (){ $(window).scrollTop(0); }); var key = getcookie('key'); $('#logoutbtn').click(function(){ var username = getcookie('username'); var key = getcookie('key'); var client = 'wap'; $.ajax({ type:'get', url:ApiUrl+'/index.php?act=logout', data:{username:username,key:key,client:client}, success:function(result){ if(result){ delCookie('username'); delCookie('key'); location.href = WapSiteUrl+'/tmpl/member/login.html'; } } }); }); var headTitle = document.title; //当前页面 if(headTitle == "首页"){ $(".fa-home").parent().addClass("current"); }else if(headTitle == "商品分类"){ $(".fa-th-list").parent().addClass("current"); }else if(headTitle == "购物车列表"){ $(".fa-shopping-cart").parent().addClass("current"); }else if(headTitle == "我的商城"){ $(".fa-user").parent().addClass("current"); } }); //bottom nav 33 hao-v3 by 33h ao.com Qq 1244 986 40