mirror of
https://gitee.com/lab1024/smart-admin.git
synced 2025-11-17 08:03:49 +08:00
Web code updated
This commit is contained in:
@@ -13,6 +13,23 @@
|
||||
var s = document.getElementsByTagName("script")[0];
|
||||
s.parentNode.insertBefore(hm, s);
|
||||
})();
|
||||
function bindTracking(ele,timeout)
|
||||
{
|
||||
var eventName=ele.getAttribute('evt-name');
|
||||
var eventCat=ele.getAttribute('evt-cat');
|
||||
var eventVal=ele.getAttribute('evt-val');
|
||||
var eventParams={};
|
||||
eventParams[eventCat]=eventVal;
|
||||
_hmt.push(['_trackEvent', eventName, eventCat, eventVal]); //Baidu Analytics Event Push
|
||||
if(timeout)
|
||||
{
|
||||
setTimeout(function(){
|
||||
window.location.href=ele.href;
|
||||
},timeout);
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user