# HG changeset patch # User Matti Hamalainen # Date 1382484459 -10800 # Node ID 91af5b225fd645c8a9b73226817aa0762f46473f # Parent 672c7f28fb97dbccf48845845b73d2bfc1c82671 Cleanups. diff -r 672c7f28fb97 -r 91af5b225fd6 print.php --- a/print.php Wed Oct 23 02:17:14 2013 +0300 +++ b/print.php Wed Oct 23 02:27:39 2013 +0300 @@ -12,7 +12,9 @@ $pageCSS = "hardcopy.css"; +// // Check if we are allowed to execute +// if (!stCheckHTTPS() || !stAdmSessionAuth(TRUE)) { stSetupCacheControl(); @@ -29,19 +31,22 @@ exit; } + +// +// Initialize +// stSetupCacheControl(); -// Initiate SQL database connection if (!stConnectSQLDB()) die("Could not connect to SQL database."); -// Fetch non-"hardcoded" settings from SQL database stReloadSettings(); -if (stChkRequestItem("type")) - $type = $_REQUEST["type"]; -switch ($type) +// +// Handle request +// +switch (stGetRequestItem("type")) { case "email": //