Changeset 834 in ExiteCMS for trunk/includes/core_functions.php
- Timestamp:
- 09/22/07 00:08:35 (5 years ago)
- File:
-
- 1 edited
-
trunk/includes/core_functions.php (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/includes/core_functions.php
r807 r834 1 1 <?php 2 2 /*---------------------------------------------------+ 3 | PLi-Fusion Content Management System|3 | ExiteCMS Content Management System | 4 4 +----------------------------------------------------+ 5 | Copyright 2007 WanWizard (wanwizard@gmail.com)|6 | http://www.pli-images.org/pli-fusion|5 | Copyright 2007 Harro "WanWizard" Verton, Exite BV | 6 | for support, please visit http://exitecms.exite.eu | 7 7 +----------------------------------------------------+ 8 | Some portions copyright ? 2002 - 2006 Nick Jones|8 | Some portions copyright 2002 - 2006 Nick Jones | 9 9 | http://www.php-fusion.co.uk/ | 10 +----------------------------------------------------+ 10 11 | Released under the terms & conditions of v2 of the | 11 12 | GNU General Public License. For details refer to | … … 37 38 if ((isset($_GET) == true) && (is_array($_GET) == true)) extract($_GET, EXTR_OVERWRITE); 38 39 } else { 39 trigger_error("'register_globals is on'. This is a security risk, and should be deactivated!", E_USER_WARNING); 40 // if not, unset all globals created by register_globals! 41 $rg = array_keys($_REQUEST); 42 foreach($rg as $var) { 43 if ($_REQUEST[$var] === $$var) { 44 // unset($$var); 45 } 46 } 40 47 } 41 48 … … 75 82 define("PATH_PM_ATTACHMENTS", PATH_ROOT."files/pm_attachments/"); 76 83 77 // mark that PLi-Fusionis properly initialized78 define(" IN_FUSION", TRUE);84 // mark that ExiteCMS is properly initialized 85 define("ExiteCMS_INIT", TRUE); 79 86 80 87 // load the config file … … 184 191 ".png", 185 192 ); 186 187 /*---------------------------------------------------+188 | DEVELOPMENT DEBUGGING - LOG ALL GET AND POST VARS |189 +----------------------------------------------------*/190 $skip_modules = array();191 $skip_modules[] = "bartext.php";192 if (!in_array(FUSION_SELF, $skip_modules)) {193 foreach ($_GET as $_name => $_value) {194 $result = dbquery("INSERT INTO ".$db_prefix."0_varlog (module, type, name, value) VALUES ('".FUSION_SELF."', 'G', '".$_name."', '".mysql_escape_string($_value)."')");195 }196 foreach ($_POST as $_name => $_value) {197 if (is_array($_value)) {198 $result = dbquery("INSERT INTO ".$db_prefix."0_varlog (module, type, name, value) VALUES ('".FUSION_SELF."', 'P', '".$_name."', 'array!')");199 } else {200 $result = dbquery("INSERT INTO ".$db_prefix."0_varlog (module, type, name, value) VALUES ('".FUSION_SELF."', 'P', '".$_name."', '".mysql_escape_string($_value)."')");201 }202 }203 }204 193 205 194 // debug function, handy to print a standard debug text … … 682 671 } 683 672 673 function checkCMSversion($min=false, $max=false) { 674 global $locale; 675 676 $error = ""; 677 678 if ($min) { 679 if (str_replace(".", "", $settings['version']) < str_replace(".", "", $min)) { 680 $error .= sprintf($locale['mod001'], $min); 681 } 682 } 683 if ($max) { 684 if (str_replace(".", "", $settings['version']) > str_replace(".", "", $max)) { 685 $error .= sprintf($locale['mod002'], $max); 686 } 687 } 688 return $error; 689 } 690 691 function checkCMSrevision($min=false, $max=false) { 692 global $locale; 693 694 $error = ""; 695 696 if ($min) { 697 if ($settings['revision'] < $min) { 698 $error .= sprintf($locale['mod003'], $min); 699 } 700 } 701 if ($max) { 702 if ($settings['revision'] > $max) { 703 $error .= sprintf($locale['mod005'], $max); 704 } 705 } 706 return $error; 707 } 708 684 709 function auth_BasicAuthentication() { 685 710
Note: See TracChangeset
for help on using the changeset viewer.
