w3pop.com :: ÍøÂçѧԺ :: HTML DOM :: HTML DOM hash ÊôÐÔ
The hash property sets or returns the part of the href property that follows the hash sign (#).
hashÊôÐÔ¿ÉÉèÖûò·µ»ØhrefÊôÐÔÖнÓÔÚ#·ûºÅºóÃæµÄÄÚÈÝ
location.hash |
Anchors array - This example opens two windows. The first window contains four buttons and the second window defines four anchors from 0 to 3. When a button is clicked in the first window, the onclick event handler goes to the specified anchor in the second window.
Õâ¸ö¾ÙÀý½«´ò¿ªÁ½¸ö´°¿Ú¡£µÚÒ»¸ö´°¿Ú°üº¬Ëĸö°´Å¥£¬µÚ¶þ¸ö¶¨ÒåÁËËĸöê¼Ç£¬·Ö±ð×Ô0µ½3¡£µ±°´Å¥°´ÏµÄʱºò£¬onclickʱ¼ä»á×÷´¦Àí£¬²¢½«µÚ¶þ¸ö´°¿ÚµÄÏÔʾλÖÃÒÆ¶¯µ½Ö¸¶¨µÄλÖÃÉÏ¡£