\n"; foreach ( $sheets as $sheet ) { $extrasheets .= " \n"; } require 'htmlheader.php'; } // // This function outputs the HTML footer along with adding script tags // for any script files passed to the function. These files are assumed // to be in the js/ folder. // function includeHTMLFooter(...$scripts) { require 'htmlfooter.php'; foreach ( $scripts as $script ) { echo "\n \n"; } echo " \n"; echo "\n"; } // // This function will redirect to the home page if the current session // has a validated user (i.e. userid != 0). // function require_anonymous() { if ( $_SESSION['userid'] != 0 ) { header('Location: index.php'); exit(); } } // // A simple function to redirect a page while still in the header // function redirectPage($page = null) { if ( is_null($page) ) $page = "index.php"; header("Location: {$page}"); exit(); }