Go back a page onload?
javascript, jquery
Solution
PHP is server side, so no. The page will get to the client and, when it reaches the client, the browser has to be instructed to go back.
That said you have two options. Javascript or HTML Meta Tags.
Javascript mootools example would be something like this:
window.addEvent('domready', function() {
history.go(-1);
});
You can also send it in HTML Meta Tags
<meta http-equiv="refresh" content="2;url=http://example.net">
Hope it helps! Be aware that this behavior is, generally, confusing to the user and should be used with caution.
Problem
Is there a way for a page to go back a page onload using javascript or php?