diff --git a/includes/functions.php b/includes/functions.php index ec17cc5..ed1c973 100644 --- a/includes/functions.php +++ b/includes/functions.php @@ -1946,8 +1946,6 @@ function meta_refresh($time, $url, $disable_cd_check = false) // For XHTML compatibility we change back & to & $url = str_replace('&', '&', $url); - $current_hour = date('H'); - $day_state = $current_hour >= 6 && $current_hour <= 18 ? 'jour' : 'nuit'; $template->assign_vars(array( 'META' => '') ); @@ -4454,6 +4452,9 @@ function page_header($page_title = '', $display_online_list = false, $item_id = $template->assign_var('S_FORM_TOKEN_LOGIN', ''); } + $current_hour = date('H'); + $day_state = $current_hour >= 6 && $current_hour <= 18 ? 'jour' : 'nuit'; + // The following assigns all _common_ variables that may be used at any point in a template. $template->assign_vars(array( 'SITENAME' => $config['sitename'],