Changeset 205 for trunk/trax/vendor/trax

Show
Ignore:
Timestamp:
05/26/06 04:50:17 (6 years ago)
Author:
john
Message:

modified redirect_to to check if header are sent

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/trax/vendor/trax/action_controller.php

    r201 r205  
    12231223            $url = url_for($options);      
    12241224        } 
    1225         echo "<html><head><META HTTP-EQUIV=\"REFRESH\" CONTENT=\"0; URL=".$url."\"></head></html>"; 
    1226         #header("Location: ".$url);    
     1225         
     1226        if(headers_sent()) { 
     1227            echo "<html><head><META HTTP-EQUIV=\"REFRESH\" CONTENT=\"0; URL=".$url."\"></head></html>"; 
     1228        } else { 
     1229            header("Location: ".$url); 
     1230        }         
     1231   
    12271232        exit;             
    12281233    }