Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

how to get javascript to execute on page load

607218Jul 18 2008 — edited Jul 22 2008
Hi -- I have some javascript defined in the page header of my application home page. P1_LOGIN_MESSAGES is set by a process in the login page, as is app_item LAST_REQUEST. The login process redirects to page 1. The page1 header script is:

<script type="text/javascript">

var jsRequest = '&LAST_REQUEST.';
alert('jsRequest is: '+ jsRequest);

// Do this only if just logged in
if (jsRequest == 'LOGIN')
{
// Display login permissions messages

alert(:P1_LOGIN_MESSAGES');

if (:IS_CZAR == 1)
{
// Check slave connections
// Print any messages associated with slaves
alert((:P1_LOGIN_MESSAGES');
}
}

</script>


Is javascript in the page header supposed to execute every time on page load? it appeared to be working in a test scenario, but when I moved it to the actual login/home page, it stopped executing at all.

Help?

Thanks,
Carol
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 19 2008
Added on Jul 18 2008
7 comments
2,486 views