mmosel Posted February 16, 2006 Share Posted February 16, 2006 Help!!Argh!Things are going along just fine, until I start getting this error in IE while using a window.onload = function();I get this error 'not implemented'. The strange thing is that the function still executes, but I get this error and I can't get rid of it. ????? Quote Link to comment Share on other sites More sharing options...
ChrisDarl Posted February 16, 2006 Share Posted February 16, 2006 And you've set it out like the code bellow? window.onload = function() { [JavaScript Code to run on load] };Chris Quote Link to comment Share on other sites More sharing options...
mmosel Posted February 16, 2006 Author Share Posted February 16, 2006 [!--quoteo(post=346489:date=Feb 16 2006, 02:50 PM:name=ChrisDarl)--][div class=\'quotetop\']QUOTE(ChrisDarl @ Feb 16 2006, 02:50 PM) [snapback]346489[/snapback][/div][div class=\'quotemain\'][!--quotec--]And you've set it out like the code bellow? window.onload = function() { [JavaScript Code to run on load] };Chris[/quote]Well, I had been using this method, perhaps this was wrong?function load(){executeotherfunction();};window.onload = load();then, I found this and tried it:function loadmeup(){executeotherfunction();};var OnLoad = 'loadmeup()';window.onload = function() {eval(OnLoad);};and it seems to work in IE. I haven't had a problem with Firefox.I'll try it the other way and see what happens, thanks! Quote Link to comment Share on other sites More sharing options...
shoz Posted February 17, 2006 Share Posted February 17, 2006 [quote]Well, I had been using this method, perhaps this was wrong?function load(){executeotherfunction();};window.onload = load();[/quote]Remove the "()" after load.[code]window.onload = load;[/code] Quote Link to comment Share on other sites More sharing options...
ChrisDarl Posted February 17, 2006 Share Posted February 17, 2006 The code that i put works, you can put whatever code you like betwee n the { } be it running another function or not. Quote Link to comment Share on other sites More sharing options...
mmosel Posted February 17, 2006 Author Share Posted February 17, 2006 [!--quoteo(post=346875:date=Feb 17 2006, 04:02 PM:name=ChrisDarl)--][div class=\'quotetop\']QUOTE(ChrisDarl @ Feb 17 2006, 04:02 PM) [snapback]346875[/snapback][/div][div class=\'quotemain\'][!--quotec--]The code that i put works, you can put whatever code you like betwee n the { } be it running another function or not.[/quote]Thanks both of you. I'll try out both or your suggestions and see how it goes.Cheers. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.