Click here to Skip to main content
16,015,973 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i have home.php

where i am running follwing code:

XML
<script type="text/javascript">

    $(document).ready(function()
    {
     alert('Page Loaded');
    });


</script>


when the page is loaded first time it doesnt show alert(page loaded).it will show only after i refreshed that page..

help me
Posted

1 solution

if you want to show alert message at page load use this method. pageload method call everytime when page load.


function pageLoad() {
alert('Page Loaded');
}
 
Share this answer
 
Comments
Ramkumar K 27-Sep-13 7:50am    
i'm new to coding.. actually iam using php.. whether it has pageload function???
CHill60 27-Sep-13 7:55am    
This looks suspiciously like ASP not PHP - there is no pageload function in PHP
Ramkumar K 28-Sep-13 5:46am    
i have pasted full code on the follwing link..please have a look at it

http://www.codeproject.com/Questions/660275/Referrence-Error-Function-is-not-defined

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900