I am wondering if it is possible to call a script through a redirect. I have a contact form using PHP mail that echos a redirect back to the home page, like so;
...
header("Location: ../index.php");
...
Is it possible to add an onload event that gets passed to the redirected page? So when “index.php” is loaded from the redirect it calls a pop up thank you or something like that.
If you’re sending them to the next page like this, you could either append some instructions to the end of the url, or you could store them in a session variable and check that upon the next page load – or even a combination of both.
And perform some type of check on the new landing page: