When I was writing JavaScript yesterday, I suddenly wrote a hyperlink and thought of the following questions. Html code: [html] <a href = "javascript: void (0)" onclick = "" showMesg ('zw1')> view Details </a> <a href = "javacrept: showMesg ('zw1')"> View Details </a> JS Code: [html] <script> function showMesg (obj) {}</script> think of the differences between the two hyperlinks above. Although the final effect is the same, but what is the difference? Search for the materials and summarize them as follows: www.2cto.com can use href and onlick in a hyperlink. Sometimes it must be used at the same time as a tag, sometimes let href work or expire (1) <a href = "#"> </a> after clicking it, the scroll bar will be rolled to the top of the page (2) <a href = "# top"> </a> when the page displays the position of the anchor whose id is top (3) <a href = "#" onclick = "javascript: method "> </a> call a javascript method to roll the scroll bar to the top of the page (4) <a href =" # "onclick =" javascript: method; return false; "> </a> call a javascript method and do not roll the scroll bar to the top of the page (5) <a href =" javascript: void (0) "> </a> no operation is performed after a click (some problems may occur in IE, such as: causes the GIF animation to stop playing) (6) <a href =" javascript: void (0) "onclick =" javascript: method; "> </a> calls a javascript method and does not roll the scroll bar to the top of the page.