Re: js, printing and redirection

From: Date: Wed, 12 Nov 2003 22:59:23 +0000
Subject: Re: js, printing and redirection
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-169390@lists.php.net to get a copy of this message
Martin Marques wrote:
<script> function printAndRedirect() {
    print();
    location="someotherscript.php";
} </script>
Yes, I already have this. My problem is that I want to make it work on the event "Onload" (when the page ends loading, execute the JS function). And what is so difficult about it?
<body onload="printAndRedirect();">

« previous php.general (#169390) next »