target()->toPage()->url(); if ($page->red_type() == 'temp') { $code = 302; }else if ($page->red_type() == 'perm') { $code = 301; }else { $code = 302; } header::redirect($target, $code); ?>