using window.onload instead of document.ready
Ive been advised to use "window.onload" instead of "document.ready" and im having problems implementing it, im sure its a syntax error.
here is my original code
- var chart;
- $(document).ready(function() {
and i want to change it to onload, and im trying to get this to work
- var chart;
- $(window).onload(function() {
what is the proper syntax for using window.onload with jquery?