Changeset 1849 in ExiteCMS


Ignore:
Timestamp:
10/14/08 18:54:26 (3 years ago)
Author:
hverton
Message:

Use include instead of redirect to make the startup page equal to the index page

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/index.php

    r1828 r1849  
    1515require_once dirname(__FILE__)."/includes/core_functions.php"; 
    1616 
    17 // make sure the redirection happens from the root 
    18 if (substr($settings['opening_page'],0,1) != "/") 
    19     redirect($settings['siteurl'].$settings['opening_page']); 
    20 else 
    21     redirect($settings['opening_page']); 
     17if (file_exists(PATH_ROOT.$settings['opening_page'])) { 
     18    include PATH_ROOT.$settings['opening_page']; 
     19} else { 
     20    // make sure the redirection happens from the root 
     21    if (substr($settings['opening_page'],0,1) != "/") 
     22        redirect($settings['siteurl'].$settings['opening_page']); 
     23    else 
     24        redirect($settings['opening_page']); 
     25} 
    2226?> 
Note: See TracChangeset for help on using the changeset viewer.