When I need to redirect the user after the headers have been sent in PHP, I use JavaScript. I have a frequent code class that stores methods like this.
The following method, redirect(), contains 3 parameters:
The following method, redirect(), contains 3 parameters:
- $time
- Time to stay on current page before redirecting.
- i.e. if you want to display a message and redirect in 5 seconds
- $location
- The page where you're going to be redirecting the user to
- i.e. index.php
- $folder_one_up
- In case you want to use this from a folder within the directory
- i.e. somewebsite.com/admin/
- Note. You can create an additional parameter, such as $level to indicate how many folders deep your script is
- i.e. somewebsite.com/admin/manager/
go
ReplyDeletelook at more info
click over here
see this site
visit here
read more
Continued