Welcome Guest, Not a member yet? Register   Sign In
Redirect Question
#4

[eluser]gtech[/eluser]
No probs.

if you look at the url_helper.php helper that has the redirect function



Code:
if (! function_exists('redirect'))
{
    function redirect($uri = '', $method = 'location')
    {
        switch($method)
        {
            case 'refresh'    : header("Refresh:0;url=".site_url($uri));
                break;
            default            : header("Location: ".site_url($uri));
                break;
        }
        exit;
    }
}

note the Refresh bit in setting the header has a 0 next to it..

so in your success controller code all you need to do is
Code:
...
  $uri = 'controller/method';
  header("Refresh:5;url=".site_url($uri));
..

header is a php function that will add to the existing headers so nothing should in theory break.

worth a try anyway, if that works why not ask for a feature request to be able to pass a wait time to the redirect function (if it hasn't been asked already)


Messages In This Thread
Redirect Question - by El Forum - 06-19-2008, 12:31 PM
Redirect Question - by El Forum - 06-19-2008, 01:07 PM
Redirect Question - by El Forum - 06-19-2008, 01:17 PM
Redirect Question - by El Forum - 06-19-2008, 01:22 PM
Redirect Question - by El Forum - 06-19-2008, 01:54 PM
Redirect Question - by El Forum - 06-19-2008, 02:30 PM



Theme © iAndrew 2016 - Forum software by © MyBB