①event.preventDefault();
②return false;
<body><div id="box"><a href="/">删除</a></div></body><script>var a = document.getElementsByTagName("a")[0];a.onclick = function (event) {var event = event || window.event;//①event.preventDefault();//②this.parentNode.remove();//删除box//return false;//方法②}</script>