From a0c37ca650d27d0aed672ebf34e1be4601a2e0e9 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Wed, 17 Dec 2008 21:27:36 +0000 Subject: [PATCH] Fixes for 'Can't use function return value in write context in /foo/bar.php' --- inc/databases.php | 2 +- inc/libs/bonus_functions.php | 2 +- inc/libs/rallye_functions.php | 2 +- inc/libs/yoomedia_functions.php | 10 +++++----- inc/modules/admin.php | 2 +- inc/modules/admin/what-config_bonus.php | 2 +- inc/modules/admin/what-config_home.php | 3 +-- inc/modules/admin/what-list_user.php | 2 +- inc/modules/member/what-points.php | 2 +- 9 files changed, 13 insertions(+), 14 deletions(-) diff --git a/inc/databases.php b/inc/databases.php index b3acb8ea11..7a56ff898c 100644 --- a/inc/databases.php +++ b/inc/databases.php @@ -114,7 +114,7 @@ define('USAGE_BASE', "usage"); define('SERVER_URL', "http://www.mxchange.org"); // Current SVN revision -define('CURR_SVN_REVISION', "642"); +define('CURR_SVN_REVISION', "643"); // Take a prime number which is long (if you know a longer one please try it out!) define('_PRIME', 591623); diff --git a/inc/libs/bonus_functions.php b/inc/libs/bonus_functions.php index a4fdf06ce5..4e1ba34bd6 100644 --- a/inc/libs/bonus_functions.php +++ b/inc/libs/bonus_functions.php @@ -199,7 +199,7 @@ function BONUS_POINTS_HANDLER ($MODE) { UPDATE_CONFIG(array('bonus_mode'), array("JACKPOT")); // Update configuration - getConfig('bonus_mode') = "JACKPOT"; + $_CONFIG['bonus_mode'] = "JACKPOT"; } // END - if if ($MODE == "login_bonus") { diff --git a/inc/libs/rallye_functions.php b/inc/libs/rallye_functions.php index ec2af80dbd..b3da615f01 100644 --- a/inc/libs/rallye_functions.php +++ b/inc/libs/rallye_functions.php @@ -519,7 +519,7 @@ function RALLYE_LOAD_USERS_ARRAY($rallye) global $_CONFIG; // Fix zero points to 0.00000 - if (getConfig('ref_payout') == "0") getConfig('ref_payout') = "0.00000"; + if (getConfig('ref_payout') == "0") $_CONFIG['ref_payout'] = "0.00000"; // Init multi array $users = array( diff --git a/inc/libs/yoomedia_functions.php b/inc/libs/yoomedia_functions.php index 22a0fb9c6b..327d83bc8e 100644 --- a/inc/libs/yoomedia_functions.php +++ b/inc/libs/yoomedia_functions.php @@ -51,11 +51,11 @@ function YOOMEDIA_TEST_CONFIG ($data) { $_CONFIG = merge_array($_CONFIG, $data); // Temporary allow maximum - getConfig('yoomedia_tm_max_reload') = 1000; - getConfig('yoomedia_tm_min_wait') = 0; - getConfig('yoomedia_tm_clicks_remain') = 10; - getConfig('yoomedia_tm_min_pay') = 0; - getConfig('yoomedia_erotic_allowed') = 1; + $_CONFIG['yoomedia_tm_max_reload'] = 1000; + $_CONFIG['yoomedia_tm_min_wait'] = 0; + $_CONFIG['yoomedia_tm_clicks_remain'] = 10; + $_CONFIG['yoomedia_tm_min_pay'] = 0; + $_CONFIG['yoomedia_erotic_allowed'] = 1; // Query the API with a test request without couting it // If zero reply comes back the data is invalid! diff --git a/inc/modules/admin.php b/inc/modules/admin.php index c144a4dc6a..517219f898 100644 --- a/inc/modules/admin.php +++ b/inc/modules/admin.php @@ -353,7 +353,7 @@ if (!isBooleanConstantAndTrue('admin_registered')) { } // When type of admin menu is not set fallback to old menu system - if (getConfig('admin_menu') == null) getConfig('admin_menu') = "OLD"; + if (getConfig('admin_menu') == null) $_CONFIG['admin_menu'] = "OLD"; // Check for version and switch between old menu system and new "intelligent menu system" if ((ADMIN_CHECK_MENU_MODE() == "NEW") && (FILE_READABLE(PATH."inc/modules/admin/lasys-inc.php"))) { diff --git a/inc/modules/admin/what-config_bonus.php b/inc/modules/admin/what-config_bonus.php index 63e933d9f3..11bbbd58d7 100644 --- a/inc/modules/admin/what-config_bonus.php +++ b/inc/modules/admin/what-config_bonus.php @@ -64,7 +64,7 @@ if (isset($_POST['ok'])) { ADMIN_SAVE_SETTINGS($_POST); // Remember new settings - getConfig('bonus_active') = $_POST['bonus_active']; + $_CONFIG['bonus_active'] = $_POST['bonus_active']; $_CONFIG['bonus_en_notify'] = $_POST['bonus_en_notify']; $_CONFIG['bonus_di_notify'] = $_POST['bonus_di_notify']; } else { diff --git a/inc/modules/admin/what-config_home.php b/inc/modules/admin/what-config_home.php index 1cf4abc2e8..d9b8a9adde 100644 --- a/inc/modules/admin/what-config_home.php +++ b/inc/modules/admin/what-config_home.php @@ -67,8 +67,7 @@ case "settings": // Settings related to the index page case "target": // Set which what-file will be placed in home-page (only modules.php?module=index) if (isset($_GET['home'])) { // Set new home - UPDATE_CONFIG("index_home", $_GET['home']); - getConfig('index_home') = SQL_ESCAPE($_GET['home']); + UPDATE_CONFIG("index_home", SQL_ESCAPE($_GET['home'])); } // END - if // Load all what menu points diff --git a/inc/modules/admin/what-list_user.php b/inc/modules/admin/what-list_user.php index 15990d4acc..00d2c1f7fa 100644 --- a/inc/modules/admin/what-list_user.php +++ b/inc/modules/admin/what-list_user.php @@ -223,7 +223,7 @@ LIMIT 1", // Calculate page count (0.5 fixes a bug with page count) if (getConfig('user_limit') == 0) { - getConfig('user_limit') = 100; + $_CONFIG['user_limit'] = 100; LOAD_TEMPLATE("admin_settings_saved", false, EXTENSION_WARNING_USER_LIMIT); } // END - if diff --git a/inc/modules/member/what-points.php b/inc/modules/member/what-points.php index 642ae6b9cc..cdf9dcbd77 100644 --- a/inc/modules/member/what-points.php +++ b/inc/modules/member/what-points.php @@ -137,7 +137,7 @@ define('__TREF_VALUE' , $TREF); define('__TLOCK_VALUE', TRANSLATE_COMMA($TLOCK)); // Fixes a bug when there is no bonus extension installed -if (EXT_VERSION_IS_OLDER("bonus", "0.4.4")) getConfig('bonus_active') = "X"; +if (EXT_VERSION_IS_OLDER("bonus", "0.4.4")) $_CONFIG['bonus_active'] = "X"; // Display login bonus and turbo-click bonus if ((GET_EXT_VERSION("bonus") >= "0.2.2") && (EXT_IS_ACTIVE("bonus")) && (getConfig('bonus_active') == "Y")) { -- 2.39.5