Jump to content

Page load issue


MichaelMackey

Recommended Posts

So I have a hard time figuring out what javascript is doing sometimes.  Right now I'm a little confused on why it reacts this way to a page load event.

 

Here's what I have, fairly simple:

 

  window.location = "ad_index.php?kn_mod=inst_res&done=yes";

  window.onload = loadEmailPage(emails);

 

function loadEmailPage(emails){

    document.getElementById('shortList').value = emails;

}

 

The funny thing is this will work if an alert goes off before the changing of the values.  I just don't get why it wont work without the alert.

 

Thanks

Link to comment
https://forums.phpfreaks.com/topic/109028-page-load-issue/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.