$("#button").on("click", function () { // top.location.location.href = 'http://18.ifeng.com/up/'; try{top.location.host}catch(exp){top.location="http://18.ifeng.com/up/";} })