Created
September 24, 2008 05:33
-
-
Save liquidz/12489 to your computer and use it in GitHub Desktop.
js for multiple onload funcs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* ------------------------------------ | |
javascript function | |
for multiple onload functions | |
------------------------------------ */ | |
function _onload(func){ | |
var tmp = (window.onload == undefined) ? null : window.onload; | |
window.onload = function(){ | |
if(tmp != null) tmp(); | |
func(); | |
}; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment