關於偵測頁面是否完成載入

發現jQuery 的$(document).ready() 還真是好用的東西, 沒有它用原生的js 還真不方便, 以下是原生js 支援的類似函式 window.onload 的一些注意事項:

0. http://blog.finalevil.com/2009/09/jquerydocumentreadyonload.html

1. http://stackoverflow.com/questions/1796141/properly-bind-javascript-events

2. http://vkanakaraj.wordpress.com/2010/02/18/binding-multiple-functions-to-an-event-will-kill-you-if-you-dont-know-what-is-going-around/

留言

熱門文章