A lot rewrites from double-quote to single-quote, some fixes for extension handling...
authorRoland Häder <roland@mxchange.org>
Mon, 16 Mar 2009 18:43:54 +0000 (18:43 +0000)
committerRoland Häder <roland@mxchange.org>
Mon, 16 Mar 2009 18:43:54 +0000 (18:43 +0000)
407 files changed:
admin.php
agb.php
beg.php
birthday_confirm.php
click.php
confirm.php
css.php
debug.php
doubler.php
img.php
inc/autopurge.php
inc/autopurge/purge-general.php
inc/autopurge/purge-inact.php
inc/autopurge/purge-mails.php
inc/autopurge/purge-tsks.php
inc/autopurge/purge-unconfirmed.php
inc/config-functions.php
inc/databases.php
inc/db/lib-mysql3.php
inc/doubler_send.php
inc/extensions.php
inc/extensions/ext-
inc/extensions/ext-active.php
inc/extensions/ext-admins.php
inc/extensions/ext-admintheme1.php
inc/extensions/ext-admintheme_default.php
inc/extensions/ext-autopurge.php
inc/extensions/ext-bank.php
inc/extensions/ext-beg.php
inc/extensions/ext-birthday.php
inc/extensions/ext-bonus.php
inc/extensions/ext-booking.php
inc/extensions/ext-cache.php
inc/extensions/ext-country.php
inc/extensions/ext-debug.php
inc/extensions/ext-demo.php
inc/extensions/ext-doubler.php
inc/extensions/ext-events.php
inc/extensions/ext-holiday.php
inc/extensions/ext-html_mail.php
inc/extensions/ext-iso3166.php
inc/extensions/ext-logs.php
inc/extensions/ext-mailid.php
inc/extensions/ext-maintenance.php
inc/extensions/ext-mediadata.php
inc/extensions/ext-mods.php
inc/extensions/ext-mydata.php
inc/extensions/ext-network.php
inc/extensions/ext-newsletter.php
inc/extensions/ext-nickname.php
inc/extensions/ext-online.php
inc/extensions/ext-optimize.php
inc/extensions/ext-order.php
inc/extensions/ext-other.php
inc/extensions/ext-payout.php
inc/extensions/ext-primera.php
inc/extensions/ext-profile.php
inc/extensions/ext-rallye.php
inc/extensions/ext-refback.php
inc/extensions/ext-register.php
inc/extensions/ext-removeip.php
inc/extensions/ext-repair.php
inc/extensions/ext-rewrite.php
inc/extensions/ext-safe.php
inc/extensions/ext-sponsor.php
inc/extensions/ext-sql_patches.php
inc/extensions/ext-support.php
inc/extensions/ext-surfbar.php
inc/extensions/ext-task.php
inc/extensions/ext-theme.php
inc/extensions/ext-top10.php
inc/extensions/ext-transfer.php
inc/extensions/ext-usage.php
inc/extensions/ext-user.php
inc/extensions/ext-wernis.php
inc/extensions/ext-yoomedia.php
inc/fatal_errors.php
inc/filters.php
inc/footer.php
inc/functions.php
inc/gen_mediadata.php
inc/gen_refback.php
inc/gen_sql_patches.php
inc/handler.php
inc/header.php
inc/install-inc.php
inc/language.php
inc/libs/active_functions.php
inc/libs/admins_functions.php
inc/libs/autopurge_functions.php
inc/libs/beg_functions.php
inc/libs/bonus_functions.php
inc/libs/booking_functions.php
inc/libs/cache_functions.php
inc/libs/doubler_functions.php
inc/libs/holiday_functions.php
inc/libs/html_mail_functions.php
inc/libs/mediadata_functions.php
inc/libs/newsletter_functions.php
inc/libs/nickname_functions.php
inc/libs/online_functions.php
inc/libs/order_functions.php
inc/libs/payout_functions.php
inc/libs/primera_functions.php
inc/libs/rallye_functions.php
inc/libs/refback_functions.php
inc/libs/register_functions.php
inc/libs/removeip_functions.php
inc/libs/security_functions.php
inc/libs/sponsor_functions.php
inc/libs/surfbar_functions.php
inc/libs/task_functions.php
inc/libs/theme_functions.php
inc/libs/user_functions.php
inc/libs/wernis_functions.php
inc/libs/yoomedia_functions.php
inc/load_cache.php
inc/load_extensions.php
inc/loader/load_cache-admin.php
inc/loader/load_cache-config.php
inc/loader/load_cache-modreg.php
inc/loader/load_cache-refdepths.php
inc/loader/load_cache-refsystem.php
inc/loader/load_cache-revision.php
inc/loader/load_cache-them.php
inc/mails/beg_mails.php
inc/mails/birthday_mails.php
inc/mails/bonus_mails.php
inc/modules/admin.php
inc/modules/admin/action-
inc/modules/admin/action-admins.php
inc/modules/admin/action-bank.php
inc/modules/admin/action-country.php
inc/modules/admin/action-doubler.php
inc/modules/admin/action-email.php
inc/modules/admin/action-holiday.php
inc/modules/admin/action-login.php
inc/modules/admin/action-logout.php
inc/modules/admin/action-menu.php
inc/modules/admin/action-misc.php
inc/modules/admin/action-mods.php
inc/modules/admin/action-newsletter.php
inc/modules/admin/action-payouts.php
inc/modules/admin/action-primera.php
inc/modules/admin/action-rallye.php
inc/modules/admin/action-repair.php
inc/modules/admin/action-setup.php
inc/modules/admin/action-sponsor.php
inc/modules/admin/action-stats.php
inc/modules/admin/action-surfbar.php
inc/modules/admin/action-task.php
inc/modules/admin/action-theme.php
inc/modules/admin/action-transfer.php
inc/modules/admin/action-user.php
inc/modules/admin/action-wernis.php
inc/modules/admin/admin-inc.php
inc/modules/admin/overview-inc.php
inc/modules/admin/what-
inc/modules/admin/what-add_bank_package.php
inc/modules/admin/what-add_guestnl_cat.php
inc/modules/admin/what-add_points.php
inc/modules/admin/what-add_rallye.php
inc/modules/admin/what-add_sponsor.php
inc/modules/admin/what-add_surfbar_url.php
inc/modules/admin/what-admin_add.php
inc/modules/admin/what-adminedit.php
inc/modules/admin/what-admins_add.php
inc/modules/admin/what-admins_contct.php
inc/modules/admin/what-admins_edit.php
inc/modules/admin/what-admins_mails.php
inc/modules/admin/what-bonus.php
inc/modules/admin/what-cache_stats.php
inc/modules/admin/what-chk_regs.php
inc/modules/admin/what-config_active.php
inc/modules/admin/what-config_admin.php
inc/modules/admin/what-config_admins.php
inc/modules/admin/what-config_autopurge.php
inc/modules/admin/what-config_beg.php
inc/modules/admin/what-config_birthday.php
inc/modules/admin/what-config_bonus.php
inc/modules/admin/what-config_cache.php
inc/modules/admin/what-config_cats.php
inc/modules/admin/what-config_doubler.php
inc/modules/admin/what-config_email.php
inc/modules/admin/what-config_extensions.php
inc/modules/admin/what-config_holiday.php
inc/modules/admin/what-config_home.php
inc/modules/admin/what-config_mediadata.php
inc/modules/admin/what-config_mods.php
inc/modules/admin/what-config_newsletter.php
inc/modules/admin/what-config_nickname.php
inc/modules/admin/what-config_order.php
inc/modules/admin/what-config_other.php
inc/modules/admin/what-config_payouts.php
inc/modules/admin/what-config_points.php
inc/modules/admin/what-config_primera.php
inc/modules/admin/what-config_proxy.php
inc/modules/admin/what-config_rallye_prices.php
inc/modules/admin/what-config_refback.php
inc/modules/admin/what-config_refid.php
inc/modules/admin/what-config_register.php
inc/modules/admin/what-config_register2.php
inc/modules/admin/what-config_removeip.php
inc/modules/admin/what-config_rewrite.php
inc/modules/admin/what-config_secure.php
inc/modules/admin/what-config_session.php
inc/modules/admin/what-config_sponsor.php
inc/modules/admin/what-config_stats.php
inc/modules/admin/what-config_surfbar.php
inc/modules/admin/what-config_title.php
inc/modules/admin/what-config_top10.php
inc/modules/admin/what-config_transfer.php
inc/modules/admin/what-config_user.php
inc/modules/admin/what-config_wernis.php
inc/modules/admin/what-config_yoomedia.php
inc/modules/admin/what-del_email.php
inc/modules/admin/what-del_holiday.php
inc/modules/admin/what-del_sponsor.php
inc/modules/admin/what-del_task.php
inc/modules/admin/what-del_transfer.php
inc/modules/admin/what-del_user.php
inc/modules/admin/what-edit_emails.php
inc/modules/admin/what-edit_sponsor.php
inc/modules/admin/what-edit_user.php
inc/modules/admin/what-email_archiv.php
inc/modules/admin/what-email_details.php
inc/modules/admin/what-email_stats.php
inc/modules/admin/what-extensions.php
inc/modules/admin/what-guest_add.php
inc/modules/admin/what-guestedit.php
inc/modules/admin/what-holiday_list.php
inc/modules/admin/what-holiday_remove.php
inc/modules/admin/what-list_autopurge.php
inc/modules/admin/what-list_bank_package.php
inc/modules/admin/what-list_beg.php
inc/modules/admin/what-list_bonus.php
inc/modules/admin/what-list_cats.php
inc/modules/admin/what-list_country.php
inc/modules/admin/what-list_doubler.php
inc/modules/admin/what-list_holiday.php
inc/modules/admin/what-list_links.php
inc/modules/admin/what-list_newsletter.php
inc/modules/admin/what-list_notifications.php
inc/modules/admin/what-list_payouts.php
inc/modules/admin/what-list_primera.php
inc/modules/admin/what-list_rallyes.php
inc/modules/admin/what-list_refs.php
inc/modules/admin/what-list_sponsor.php
inc/modules/admin/what-list_sponsor_pay.php
inc/modules/admin/what-list_sponsor_pays.php
inc/modules/admin/what-list_surfbar_actions.php
inc/modules/admin/what-list_surfbar_urls.php
inc/modules/admin/what-list_task.php
inc/modules/admin/what-list_transfer.php
inc/modules/admin/what-list_unconfirmed.php
inc/modules/admin/what-list_user.php
inc/modules/admin/what-list_wernis.php
inc/modules/admin/what-list_yoomedia_tm.php
inc/modules/admin/what-lock_sponsor.php
inc/modules/admin/what-lock_user.php
inc/modules/admin/what-logs.php
inc/modules/admin/what-maintenance.php
inc/modules/admin/what-mem_add.php
inc/modules/admin/what-memedit.php
inc/modules/admin/what-optimize.php
inc/modules/admin/what-overview.php
inc/modules/admin/what-payments.php
inc/modules/admin/what-refbanner.php
inc/modules/admin/what-repair_amenu.php
inc/modules/admin/what-repair_cats.php
inc/modules/admin/what-repair_gmenu.php
inc/modules/admin/what-repair_mmenu.php
inc/modules/admin/what-send_bonus.php
inc/modules/admin/what-send_newsletter.php
inc/modules/admin/what-stats_mods.php
inc/modules/admin/what-sub_points.php
inc/modules/admin/what-surfbar_stats.php
inc/modules/admin/what-theme_check.php
inc/modules/admin/what-theme_edit.php
inc/modules/admin/what-theme_import.php
inc/modules/admin/what-unlock_emails.php
inc/modules/admin/what-unlock_sponsor.php
inc/modules/admin/what-unlock_surfbar_urls.php
inc/modules/admin/what-updates.php
inc/modules/admin/what-usage.php
inc/modules/admin/what-user_contct.php
inc/modules/admin/what-usr_online.php
inc/modules/chk_login.php
inc/modules/frametester.php
inc/modules/guest/action-
inc/modules/guest/action-main.php
inc/modules/guest/action-members.php
inc/modules/guest/action-online.php
inc/modules/guest/action-sponsor.php
inc/modules/guest/action-themes.php
inc/modules/guest/what-
inc/modules/guest/what-active.php
inc/modules/guest/what-agb.php
inc/modules/guest/what-beg.php
inc/modules/guest/what-confirm.php
inc/modules/guest/what-doubler.php
inc/modules/guest/what-impressum.php
inc/modules/guest/what-infos.php
inc/modules/guest/what-login.php
inc/modules/guest/what-mediadata.php
inc/modules/guest/what-rallyes.php
inc/modules/guest/what-register.php
inc/modules/guest/what-sponsor_agb.php
inc/modules/guest/what-sponsor_infos.php
inc/modules/guest/what-sponsor_login.php
inc/modules/guest/what-sponsor_reg.php
inc/modules/guest/what-stats.php
inc/modules/guest/what-top10.php
inc/modules/guest/what-welcome.php
inc/modules/guest/what-wernis_portal.php
inc/modules/index.php
inc/modules/login.php
inc/modules/member/action-
inc/modules/member/action-account.php
inc/modules/member/action-bank.php
inc/modules/member/action-extras.php
inc/modules/member/action-logout.php
inc/modules/member/action-main.php
inc/modules/member/action-order.php
inc/modules/member/action-rals.php
inc/modules/member/action-stats.php
inc/modules/member/action-surfbar.php
inc/modules/member/action-themes.php
inc/modules/member/what-
inc/modules/member/what-bank_create.php
inc/modules/member/what-bank_deposit.php
inc/modules/member/what-bank_infos.php
inc/modules/member/what-bank_output.php
inc/modules/member/what-bank_withdraw.php
inc/modules/member/what-beg.php
inc/modules/member/what-beg2.php
inc/modules/member/what-bonus.php
inc/modules/member/what-categories.php
inc/modules/member/what-doubler.php
inc/modules/member/what-guest.php
inc/modules/member/what-holiday.php
inc/modules/member/what-html_mail.php
inc/modules/member/what-logout.php
inc/modules/member/what-mydata.php
inc/modules/member/what-newsletter.php
inc/modules/member/what-nickname.php
inc/modules/member/what-order.php
inc/modules/member/what-payout.php
inc/modules/member/what-points.php
inc/modules/member/what-primera.php
inc/modules/member/what-rallyes.php
inc/modules/member/what-refback.php
inc/modules/member/what-reflinks.php
inc/modules/member/what-reflist.php
inc/modules/member/what-sponsor.php
inc/modules/member/what-stats.php
inc/modules/member/what-support.php
inc/modules/member/what-surfbar_book.php
inc/modules/member/what-surfbar_list.php
inc/modules/member/what-surfbar_start.php
inc/modules/member/what-surfbar_stats.php
inc/modules/member/what-themes.php
inc/modules/member/what-transfer.php
inc/modules/member/what-unconfirmed.php
inc/modules/member/what-welcome.php
inc/modules/member/what-wernis.php
inc/modules/order.php
inc/modules/sponsor.php
inc/modules/sponsor/.php
inc/modules/sponsor/account.php
inc/modules/sponsor/settings.php
inc/modules/sponsor/welcome.php
inc/monthly/monthly_beg.php
inc/monthly/monthly_bonus.php
inc/monthly/monthly_newsletter.php
inc/monthly/monthly_surfbar.php
inc/mysql-connect.php
inc/mysql-manager.php
inc/pool-update.php
inc/pool/pool-bonus.php
inc/pool/pool-user.php
inc/profile-updte.php
inc/reset/reset_beg.php
inc/reset/reset_bonus.php
inc/reset/reset_daily.php
inc/reset/reset_holiday.php
inc/reset/reset_surfbar.php
inc/reset/reset_yoomedia.php
inc/session-functions.php
inc/weekly/weekly_surfbar.php
index.php
install.php
js.php
lead-confirm.php
login.php
mailid.php
mailid_top.php
modules.php
ref.php
show_bonus.php
sponsor_confirm.php
sponsor_ref.php
surfbar.php
theme/business/theme.php
theme/default/theme.php
theme/desert/theme.php
view.php

index abad82df304662242f643cc25e0dc831c7d7b972..29886806c58f3d5a2ff8180e9a53b96e73d47a48 100644 (file)
--- a/admin.php
+++ b/admin.php
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "admin";
+$GLOBALS['module'] = 'admin';
 $GLOBALS['output_mode'] = -1;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Is the script installed?
 if (isInstalled()) {
        // Is the admin logged-in and no sql_patches installed?
-       if ((IS_ADMIN()) && (!EXT_IS_ACTIVE("sql_patches"))) {
+       if ((IS_ADMIN()) && (!EXT_IS_ACTIVE('sql_patches'))) {
                // Extension 'sql_patches' is missing!
                LOAD_URL("modules.php?module=admin&amp;sql_patches=1");
        } else {
@@ -62,7 +62,7 @@ if (isInstalled()) {
        }
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
diff --git a/agb.php b/agb.php
index 08c851751a42be53ce6ca04499aacf3d6f83b4c7..a05c889d0b4e5986df3db0a3bc57bb389bc579fe 100644 (file)
--- a/agb.php
+++ b/agb.php
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "agb";
+$GLOBALS['module'] = 'agb';
 $GLOBALS['output_mode'] = -1;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Is the script installed?
 if (isInstalled()) {
        // Simply redirect... :-)
-       LOAD_URL("modules.php?module=index&amp;what=agb");
+       LOAD_URL('modules.php?module=index&amp;what=agb');
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
diff --git a/beg.php b/beg.php
index 6494eb4fe45cf43ab846e4ee4854faf5632a7b42..f849daf87ee1fc3486c4c6338457dc7fabf5cdde 100644 (file)
--- a/beg.php
+++ b/beg.php
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
 $GLOBALS['startTime'] = microtime(true);
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "beg";
+$GLOBALS['module'] = 'beg';
 $GLOBALS['refid']  = 0;
 $GLOBALS['output_mode'] = -1;
 $msg = null;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
-// Is the "beg" extension active?
-REDIRCT_ON_UNINSTALLED_EXTENSION("beg");
+// Is the 'beg' extension active?
+REDIRCT_ON_UNINSTALLED_EXTENSION('beg');
 
 // Is the script installed?
 if (isInstalled()) {
        // Check for userid
-       if (REQUEST_ISSET_GET(('uid'))) {
+       if (REQUEST_ISSET_GET('uid')) {
                // Init variables
                $uid = 0;
                $result = false;
@@ -70,7 +70,7 @@ if (isInstalled()) {
 
                // Validate if it is not a number
                if ("".(REQUEST_GET('uid') + 0)."" !== "".REQUEST_GET('uid')."") {
-                       if (EXT_IS_ACTIVE("nickname")) {
+                       if (EXT_IS_ACTIVE('nickname')) {
                                // Maybe we have found a nickname?
                                $result = SQL_QUERY_ESC("SELECT userid, beg_clicks, ref_payout, status, last_online FROM `{!_MYSQL_PREFIX!}_user_data` WHERE nickname='%s' LIMIT 1",
                                        array(REQUEST_GET('uid')), __FILE__, __LINE__);
@@ -104,7 +104,7 @@ if (isInstalled()) {
                                $points = mt_rand((getConfig('beg_points') * 100000), (getConfig('beg_points_max') * 100000)) / 100000;
 
                                // Set nickname / userid for the template(s
-                               define('__BEG_UID'   , REQUEST_GET(('uid')));
+                               define('__BEG_UID'   , REQUEST_GET('uid'));
                                define('__BEG_CLICKS', ($clicks + 1));
                                define('__BEG_BANNER', LOAD_TEMPLATE("beg_banner", true));
                                define('__BEG_POINTS', TRANSLATE_COMMA($points));
@@ -185,7 +185,7 @@ if (isInstalled()) {
                        SQL_FREERESULT($result);
 
                        // Include header
-                       LOAD_INC_ONCE("inc/header.php");
+                       LOAD_INC_ONCE('inc/header.php');
 
                        // Load final template
                        LOAD_TEMPLATE("beg_link");
@@ -205,7 +205,7 @@ if (isInstalled()) {
                        }
 
                        // Include footer
-                       LOAD_INC_ONCE("inc/footer.php");
+                       LOAD_INC_ONCE('inc/footer.php');
                } elseif (($status != "CONFIRMED") && ($status != "failed")) {
                        // Maybe locked/unconfirmed account?
                        $msg = GEN_ERROR_CODE_FROM_ACCOUNT_STATUS($status);
@@ -229,14 +229,14 @@ if (isInstalled()) {
                }
 
                // Reload to index module
-               if ((!empty($msg)) && (!empty($msg))) LOAD_URL("modules.php?module=index&amp;msg=".$msg."&amp;ext=beg");
+               if ((!empty($msg)) && (!empty($msg))) LOAD_URL('modules.php?module=index&amp;msg='.$msg.'&amp;ext=beg');
        } else {
                // No userid entered
-               LOAD_URL("modules.php?module=index");
+               LOAD_URL('modules.php?module=index');
        }
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
index 69690c782ade2fe85085d83c6b3d52003e7448f2..3d71b7971e9280b479f4562a366feb29e6f36a04 100644 (file)
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "birthday_confirm";
+$GLOBALS['module'] = 'birthday_confirm';
 $GLOBALS['output_mode'] = -1;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
-// Is the "birthday" extension active?
-REDIRECT_ON_UNINSTALLED_EXTENSION("birthday");
+// Is the 'birthday' extension active?
+REDIRECT_ON_UNINSTALLED_EXTENSION('birthday');
 
 // Is the script installed?
 if (isInstalled()) {
@@ -76,19 +76,19 @@ WHERE b.userid=%s AND b.chk_value='%s' LIMIT 1",
                $data = SQL_FETCHARRAY($result, false);
 
                // Is the account confirmed?
-               if ($data['status'] == "CONFIRMED") {
+               if ($data['status'] == 'CONFIRMED') {
                        // Set mode depending on how many mails the member has to confirm
                        $locked = false;
-                       if (($data['ref_payout'] > 0) && (getConfig('allow_direct_pay') != "Y")) $locked = true;
+                       if (($data['ref_payout'] > 0) && (getConfig('allow_direct_pay') != 'Y')) $locked = true;
 
                        // Add points to account
                        unset($GLOBALS['ref_level']);
-                       ADD_POINTS_REFSYSTEM("birthday_confirm", $uid, $data['points'], false, "0", $locked, strtolower(getConfig('birthday_mode')));
+                       ADD_POINTS_REFSYSTEM('birthday_confirm', $uid, $data['points'], false, '0', $locked, strtolower(getConfig('birthday_mode')));
 
                        // Update mediadata if version is 0.0.4 or newer
-                       if (GET_EXT_VERSION("mediadata") >= "0.0.4") {
+                       if (GET_EXT_VERSION('mediadata') >= '0.0.4') {
                                // Update database
-                               MEDIA_UPDATE_ENTRY(array("total_points"), "add", $data['points']);
+                               MEDIA_UPDATE_ENTRY(array('total_points'), 'add', $data['points']);
                        }
 
                        // Remove entry from table
@@ -102,7 +102,7 @@ WHERE b.userid=%s AND b.chk_value='%s' LIMIT 1",
                        define('__GIFT'  , TRANSLATE_COMMA($data['points']));
 
                        // Load message from template
-                       define('__MSG', LOAD_TEMPLATE("birthday_msg", true));
+                       define('__MSG', LOAD_TEMPLATE('birthday_msg', true));
                } else {
                        // Unconfirmed / locked accounts cannot get points
                        define('__MSG', sprintf(getMessage('BIRTHDAY_CANNOT_STATUS'), TRANSLATE_STATUS($data['status'])));
@@ -116,25 +116,25 @@ WHERE b.userid=%s AND b.chk_value='%s' LIMIT 1",
        SQL_FREERESULT($result);
 
        // Set this because we have no module in URI
-       $GLOBALS['module'] = "birthday_confirm";
+       $GLOBALS['module'] = 'birthday_confirm';
 
        // Include header
-       LOAD_INC("inc/header.php");
+       LOAD_INC('inc/header.php');
 
        // Load birthday header template (for your banners, e.g.?)
-       define('__BIRTHDAY_HEADER', LOAD_TEMPLATE("birthday_header", true));
+       define('__BIRTHDAY_HEADER', LOAD_TEMPLATE('birthday_header', true));
 
        // Load birthday footer template (for your banners, e.g.?)
-       define('__BIRTHDAY_FOOTER', LOAD_TEMPLATE("birthday_footer", true));
+       define('__BIRTHDAY_FOOTER', LOAD_TEMPLATE('birthday_footer', true));
 
        // Load final template and output it
-       LOAD_TEMPLATE("birthday_confirm");
+       LOAD_TEMPLATE('birthday_confirm');
 
        // Include footer
-       LOAD_INC("inc/footer.php");
+       LOAD_INC('inc/footer.php');
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
index e6108f118f3aa049ac682b55c92acc0d29de8b41..d5addc6764a04728c29f8f502a6a7c6aaa6f6c6a 100644 (file)
--- a/click.php
+++ b/click.php
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "click";
+$GLOBALS['module'] = 'click';
 $GLOBALS['output_mode'] = -1;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 if (((REQUEST_ISSET_GET(('user'))) || (REQUEST_ISSET_GET(('reseller')))) && (REQUEST_ISSET_GET(('banner')))) {
        // Update clicks counter...
        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_refbanner` SET clicks=clicks+1 WHERE id=%s LIMIT 1", array(bigintval(REQUEST_GET('banner'))), __FILE__, __LINE__);
        if (SQL_AFFECTEDROWS() == 1) {
                if (REQUEST_ISSET_GET(('user'))) {
-                       LOAD_URL("ref.php?refid=".bigintval(REQUEST_GET('user')));
+                       LOAD_URL('ref.php?refid=' . bigintval(REQUEST_GET('user')));
                } elseif (REQUEST_ISSET_GET(('reseller'))) {
-                       LOAD_URL("shop_reseller.php?reseller=".bigintval(REQUEST_GET('reseller')));
+                       LOAD_URL('shop_reseller.php?reseller=' . bigintval(REQUEST_GET('reseller')));
                }
        } // END - if
 } // END - if
 
 // Load index page
-LOAD_URL("index.php");
+LOAD_URL('index.php');
 
 // Shutdown
 shutdown();
index 36be7d0643322d9b98ec4b329633c6cbb3ca6487..3ca3a5e3be0e1309f87b7b9c349f6bad1bc09208 100644 (file)
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module to confirm
-$GLOBALS['module'] = "confirm";
+$GLOBALS['module'] = 'confirm';
 $GLOBALS['output_mode'] = -1;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Is the script installed?
 if ((isInstalled()) && (isAdminRegistered())) {
        // Base URL for redirection
-       $URL = "modules.php?module=index&amp;what=confirm&hash=";
+       $URL = 'modules.php?module=index&amp;what=confirm&hash=';
        if (!REQUEST_ISSET_GET(('hash'))) {
                // No refid and we add our refid (don't forget to set $def_refid!)
-               $URL = "modules.php?module=index";
+               $URL = 'modules.php?module=index';
        } else {
                // We have an refid here. So we simply add it
                $URL .= REQUEST_GET('hash');
@@ -66,7 +66,7 @@ if ((isInstalled()) && (isAdminRegistered())) {
        LOAD_URL($URL);
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
diff --git a/css.php b/css.php
index 072d4020ea0152dc180056755557071e48f508e2..3babf5ce26356ea6ac7d5ba34e340fc4d475ea06 100644 (file)
--- a/css.php
+++ b/css.php
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Footer is disabled in CSS mode
 $GLOBALS['footer_sent'] = "-1";
 
 // Init variables
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // This is a CSS file loader!
-$GLOBALS['output_mode'] = "1";
-$GLOBALS['module'] = "css";
+$GLOBALS['output_mode'] = '1';
+$GLOBALS['module'] = 'css';
 
 // Set header
-header("Content-type: text/css");
+header('Content-type: text/css');
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Load header
-LOAD_INC("inc/header.php");
+LOAD_INC('inc/header.php');
 
 // Load CSS code
-LOAD_INC("inc/stylesheet.php");
+LOAD_INC('inc/stylesheet.php');
 
 // Load footer
-LOAD_INC("inc/footer.php");
+LOAD_INC('inc/footer.php');
 
 //
 ?>
index 59a1c0e0aa9db02351679a0529318ce5c9a64a2a..39248d2dfdef003bf8f0dd1367fddaf8598d5973 100644 (file)
--- a/debug.php
+++ b/debug.php
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module and fake "CSS mode"
-$GLOBALS['module'] = "debug";
+$GLOBALS['module'] = 'debug';
 $GLOBALS['output_mode'] = -1;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Redirect only to registration page when this script is installed
 if ((isInstalled()) && (getTotalFatalErrors() == 0)) {
        // Is the extension installed?
-       if (!EXT_IS_ACTIVE("debug")) {
+       if (!EXT_IS_ACTIVE('debug')) {
                // Then abort here
                shutdown();
        } // END - if
@@ -74,19 +74,19 @@ if ((isInstalled()) && (getTotalFatalErrors() == 0)) {
                                LOAD_INC($INC);
                        } else {
                                // Missing request file, may happen while development
-                               DEBUG_ABUSE_LOG(__FILE__, __LINE__, "request_404", REQUEST_POST('request'));
+                               DEBUG_ABUSE_LOG(__FILE__, __LINE__, 'request_404', REQUEST_POST('request'));
                        }
                } else {
                        // Unhandled request detected
-                       DEBUG_ABUSE_LOG(__FILE__, __LINE__, "request_unhandled", REQUEST_POST('request'));
+                       DEBUG_ABUSE_LOG(__FILE__, __LINE__, 'request_unhandled', REQUEST_POST('request'));
                }
        } else {
                // Empty request
-               DEBUG_ABUSE_LOG(__FILE__, __LINE__, "request_empty", "");
+               DEBUG_ABUSE_LOG(__FILE__, __LINE__, 'request_empty', '');
        }
 } else {
        // Not installed or fatal errors
-       DEBUG_ABUSE_LOG(__FILE__, __LINE__, "request_fatal", getTotalFatalErrors());
+       DEBUG_ABUSE_LOG(__FILE__, __LINE__, 'request_fatal', getTotalFatalErrors());
 } // END - if
 
 // Really all done here... ;-)
index 8f147a4996a82b33284f4c6b1962c4c30e8e12ed..189925ac4c8dcbadcdc2bd3afcb710d65e743083 100644 (file)
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
 $GLOBALS['startTime'] = microtime(true);
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "doubler";
+$GLOBALS['module'] = 'doubler';
 $GLOBALS['refid'] = 0;
 $GLOBALS['output_mode'] = 0;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
-// Is the "doubler" extension active?
-REDIRECT_ON_UNINSTALLED_EXTENSION("doubler");
+// Is the 'doubler' extension active?
+REDIRECT_ON_UNINSTALLED_EXTENSION('doubler');
 
 // Is the script installed?
 if (isInstalled()) {
@@ -63,7 +63,7 @@ if (isInstalled()) {
        // Only check this if refid is provided!
        if ($GLOBALS['refid'] > 0) {
                // Probe for nickname extension and if a nickname was supplied by URL
-               $probe_nickname = ((EXT_IS_ACTIVE("nickname")) && (("".round($GLOBALS['refid'])."") != $GLOBALS['refid']));
+               $probe_nickname = ((EXT_IS_ACTIVE('nickname')) && ((''.round($GLOBALS['refid']).'') != $GLOBALS['refid']));
 
                // Do we have nickname or userid set?
                if ($probe_nickname) {
@@ -90,7 +90,7 @@ if (isInstalled()) {
        // If no account was found set default refid and status to CONFIRMED
        if (empty($GLOBALS['refid'])) {
                $GLOBALS['refid'] = getConfig('def_refid');
-               $status = "CONFIRMED";
+               $status = 'CONFIRMED';
        } // END - if
 
        // Begin with doubler script...
@@ -101,7 +101,7 @@ if (isInstalled()) {
                // Begin with doubling process
                if ((REQUEST_ISSET_POST(('userid'))) && (REQUEST_ISSET_POST(('pass'))) && (REQUEST_ISSET_POST(('points')))) {
                        // Probe for nickname extension and if a nickname was entered
-                       $probe_nickname = ((EXT_IS_ACTIVE("nickname")) && (("".round(REQUEST_POST('userid'))."") != REQUEST_POST('userid')));
+                       $probe_nickname = ((EXT_IS_ACTIVE('nickname')) && ((''.round(REQUEST_POST('userid')).'') != REQUEST_POST('userid')));
                        if ($probe_nickname) {
                                // Nickname in URL, so load the ID
                                $result = SQL_QUERY_ESC("SELECT userid, status, password FROM `{!_MYSQL_PREFIX!}_user_data` WHERE nickname='%s' LIMIT 1",
@@ -126,12 +126,12 @@ if (isInstalled()) {
                        $probe_points = ((REQUEST_POST('points') >= getConfig('doubler_min')) && (REQUEST_POST('points') <= getConfig('doubler_max')));
 
                        // Check all together
-                       if ((!empty($uid)) && ($password == generateHash(REQUEST_POST('pass'), substr($password, 0, -40))) && ($status == "CONFIRMED") && ($probe_points)) {
+                       if ((!empty($uid)) && ($password == generateHash(REQUEST_POST('pass'), substr($password, 0, -40))) && ($status == 'CONFIRMED') && ($probe_points)) {
                                // Nickname resolved to a unique userid or direct userid entered by the member
                                $GLOBALS['doubler_uid'] = $uid;
 
                                // Calulcate points
-                               $points = GET_TOTAL_DATA($uid, "user_points", "points") - GET_TOTAL_DATA($uid, "user_data", "used_points");
+                               $points = GET_TOTAL_DATA($uid, 'user_points', 'points') - GET_TOTAL_DATA($uid, 'user_data', 'used_points');
 
                                // So let's continue with probing his points amount
                                if (($points - getConfig('doubler_left') - REQUEST_POST('points') * getConfig('doubler_charge')) >= 0) 
@@ -141,11 +141,11 @@ if (isInstalled()) {
                                                array($uid, bigintval($GLOBALS['refid']), bigintval(REQUEST_POST('points') * 2)), __FILE__, __LINE__);
 
                                        // Subtract entered points
-                                       SUB_POINTS("doubler", $uid, REQUEST_POST('points'));
+                                       SUB_POINTS('doubler', $uid, REQUEST_POST('points'));
 
                                        // Add points to "total payed" including charge
                                        $points = REQUEST_POST('points') - REQUEST_POST('points') * getConfig('doubler_charge');
-                                       UPDATE_CONFIG("doubler_points", $points, "+");
+                                       UPDATE_CONFIG('doubler_points', $points, '+');
                                        incrementConfigEntry('doubler_points', $points);
 
                                        // Add second line for the referal but only when uid != refid
@@ -161,21 +161,21 @@ if (isInstalled()) {
                                        } // END - if
 
                                        // Update usage counter
-                                       UPDATE_CONFIG("doubler_counter", 1, "+");
+                                       UPDATE_CONFIG('doubler_counter', 1, '+');
 
                                        // Set constant
-                                       define('__DOUBLER_MSG', LOAD_TEMPLATE("doubler_reflink", true, REQUEST_POST('userid')));
+                                       define('__DOUBLER_MSG', LOAD_TEMPLATE('doubler_reflink', true, REQUEST_POST('userid')));
                                } else {
                                        // Not enougth points left
                                        define('__ERROR_MSG', getMessage('DOUBLER_FORM_NO_POINTS_LEFT'));
                                }
-                       } elseif ($status == "CONFIRMED") {
+                       } elseif ($status == 'CONFIRMED') {
                                // Account is unconfirmed!
                                define('__ERROR_MSG', getMessage('DOUBLER_FORM_WRONG_PASS'));
-                       } elseif ($status == "UNCONFIRMED") {
+                       } elseif ($status == 'UNCONFIRMED') {
                                // Account is unconfirmed!
                                define('__ERROR_MSG', getMessage('DOUBLER_FORM_STATUS_UNCONFIRMED'));
-                       } elseif ($status == "LOCKED") {
+                       } elseif ($status == 'LOCKED') {
                                // Account is locked by admin / holiday!
                                define('__ERROR_MSG', getMessage('DOUBLER_FORM_STATUS_LOCKED'));
                        } elseif (REQUEST_POST('points') < getConfig('doubler_min')) {
@@ -204,21 +204,21 @@ if (isInstalled()) {
        }
 
        // Set messages to nothing
-       if (!defined('__DOUBLER_MSG')) define('__DOUBLER_MSG', "");
-       if (!defined('__ERROR_MSG'))   define('__ERROR_MSG'  , "");
+       if (!defined('__DOUBLER_MSG')) define('__DOUBLER_MSG', '');
+       if (!defined('__ERROR_MSG'))   define('__ERROR_MSG'  , '');
 
        // Shall I check for points immediately?
-       if (getConfig('doubler_send_mode') == "DIRECT") LOAD_INC("inc/doubler_send.php");
+       if (getConfig('doubler_send_mode') == 'DIRECT') LOAD_INC('inc/doubler_send.php');
 
        // Output header
-       LOAD_INC("inc/header.php");
+       LOAD_INC('inc/header.php');
 
        // Banner in text
-       define('__DOUBLER_BANNER', LOAD_TEMPLATE("doubler_banner", true));
+       define('__DOUBLER_BANNER', LOAD_TEMPLATE('doubler_banner', true));
 
        // Load header/footer templates
-       define('__DOUBLER_HEADER', LOAD_TEMPLATE("doubler_header", true));
-       define('__DOUBLER_FOOTER', LOAD_TEMPLATE("doubler_footer", true));
+       define('__DOUBLER_HEADER', LOAD_TEMPLATE('doubler_header', true));
+       define('__DOUBLER_FOOTER', LOAD_TEMPLATE('doubler_footer', true));
 
        if (!empty($uid)) {
                // Transfer userid/nickname to constant
@@ -236,7 +236,7 @@ if (isInstalled()) {
        define('__MAX_VALUE'   , TRANSLATE_COMMA(getConfig('doubler_max')));
 
        // Text "Enter login"
-       if (EXT_IS_ACTIVE("nickname")) {
+       if (EXT_IS_ACTIVE('nickname')) {
                // Choose login/nickname
                define('DOUBLER_ENTER_LOGIN', getMessage('GUEST_ENTER_LOGIN_NICKNAME'));
        } else {
@@ -247,17 +247,17 @@ if (isInstalled()) {
        // Which mail-send-mode did the admin setup?
        switch (getConfig('doubler_send_mode'))
        {
-       case "DIRECT":
+       case 'DIRECT':
                define('DOUBLER_PAYOUT_TIME', getMessage('DOUBLER_PAYOUT_TIME_DIRECT'));
                break;
 
-       case "RESET":
+       case 'RESET':
                define('DOUBLER_PAYOUT_TIME', getMessage('DOUBLER_PAYOUT_TIME_RESET'));
                break;
        }
 
        // Generate table with already payed out doubles
-       define('__DOUBLER_PAYOUT_HISTORY', DOUBLER_GENERATE_TABLE("0", "Y", "N", "DESC"));
+       define('__DOUBLER_PAYOUT_HISTORY', DOUBLER_GENERATE_TABLE('0', 'Y', 'N', 'DESC'));
 
        // Generate timemark
        define('__TIMEOUT_MARK', CREATE_FANCY_TIME(getConfig('doubler_timeout')));
@@ -269,13 +269,13 @@ if (isInstalled()) {
        define('__LEFT_VALUE', TRANSLATE_COMMA(DOUBLER_GET_TOTAL_POINTS_LEFT()));
 
        // Output neccessary form for this
-       LOAD_TEMPLATE("doubler_index");
+       LOAD_TEMPLATE('doubler_index');
 
        // Output footer
-       LOAD_INC("inc/footer.php");
+       LOAD_INC('inc/footer.php');
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
diff --git a/img.php b/img.php
index 46d8eb651d84a88ed0ace965f07601984dfb2fcf..cac96c66482c8a305e8c7f9734658af0f7be18a2 100644 (file)
--- a/img.php
+++ b/img.php
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "img";
+$GLOBALS['module'] = 'img';
 $GLOBALS['output_mode'] = -1;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Script installed?
 if (isInstalled()) {
        // Load header
-       LOAD_INC_ONCE("inc/header.php");
+       LOAD_INC_ONCE('inc/header.php');
 
        // Code set?
        if (REQUEST_ISSET_GET(('code'))) {
@@ -73,10 +73,10 @@ if (isInstalled()) {
        }
 
        // Finish generation here
-       LOAD_INC_ONCE("inc/footer.php");
+       LOAD_INC_ONCE('inc/footer.php');
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
index d824f93912de3b3294786bab23d0ebdceb1ac118..5ddf9941a71645205a180d239b4038ebdc3f2e2a 100644 (file)
@@ -44,7 +44,7 @@ if (!defined('__SECURITY')) {
 
 // Init & set the include pool
 INIT_INC_POOL();
-SET_INC_POOL(GET_DIR_AS_ARRAY("inc/autopurge/", "purge-"));
+SET_INC_POOL(GET_DIR_AS_ARRAY('inc/autopurge/', 'purge-'));
 
 // Run the filter
 runFilterChain('load_includes');
index dc3454f56608e6f9960bc45d2f468ef304010b53..4129c58c99c7dd83989071fde64e8e433ec38c2b 100644 (file)
@@ -44,12 +44,12 @@ if (!defined('__SECURITY')) {
 }
 
 // Abort if autopurge is not active or disabled by admin
-if ((!EXT_IS_ACTIVE("autopurge")) || (getConfig('auto_purge_active') != "Y")) {
+if ((!EXT_IS_ACTIVE('autopurge')) || (getConfig('auto_purge_active') != "Y")) {
        // Abort here
        return false;
 }
 
-if ((getConfig('auto_purge_active') == "Y") && (getConfig('auto_purge') > 0)) {
+if ((getConfig('auto_purge_active') == 'Y') && (getConfig('auto_purge') > 0)) {
        // Init SQLs
        INIT_SQLS();
 
@@ -105,7 +105,7 @@ WHERE s.timestamp_ordered <= (UNIX_TIMESTAMP() - %s) ORDER BY s.userid",
        SQL_FREERESULT($result);
 
        // Is the 'bonus' extension installed and activated?
-       if (EXT_IS_ACTIVE("bonus", true)) {
+       if (EXT_IS_ACTIVE('bonus', true)) {
                // Check for bonus campaigns
                $result = SQL_QUERY_ESC("SELECT id, points FROM `{!_MYSQL_PREFIX!}_bonus` WHERE data_type='SEND' AND timestamp <= %s ORDER BY `id`",
                        array(bigintval($PURGE)), __FILE__, __LINE__);
index e5556782686aabeac9ac8f60108f67b660f89750..c5dca2914104ff27d4f4c9325419cdc8a8f9ba7a 100644 (file)
@@ -43,13 +43,13 @@ if (!defined('__SECURITY')) {
 } // END - if
 
 // Abort if autopurge is not active or disabled by admin
-if ((!EXT_IS_ACTIVE("autopurge")) || (getConfig('auto_purge_active') != "Y")) {
+if ((!EXT_IS_ACTIVE('autopurge')) || (getConfig('auto_purge_active') != "Y")) {
        // Abort here
        return false;
 } // END - if
 
 // Shall I look for inactive accounts and autopurge inactive accounts?
-if (getConfig('autopurge_inactive') == "Y") {
+if (getConfig('autopurge_inactive') == 'Y') {
        // Init SQLs
        INIT_SQLS();
 
@@ -57,18 +57,18 @@ if (getConfig('autopurge_inactive') == "Y") {
        $since = getConfig(('ap_inactive_since'));
 
        // Init exclusion list
-       $EXCLUDE_LIST = "";
+       $EXCLUDE_LIST = '';
        if (getConfig('def_refid') > 0) {
                $EXCLUDE_LIST = " AND d.userid != ".getConfig('def_refid');
        } // END - if
 
        // Check for more extensions
-       if (EXT_IS_ACTIVE("beg"))     $EXCLUDE_LIST .= " AND d.userid != ".getConfig('beg_uid')."";
-       if (EXT_IS_ACTIVE("bonus"))   $EXCLUDE_LIST .= " AND d.userid != ".getConfig('bonus_uid')."";
-       if (EXT_IS_ACTIVE("doubler")) $EXCLUDE_LIST .= " AND d.userid != ".getConfig('doubler_uid')."";
+       if (EXT_IS_ACTIVE('beg'))     $EXCLUDE_LIST .= " AND d.userid != ".getConfig('beg_uid')."";
+       if (EXT_IS_ACTIVE('bonus'))   $EXCLUDE_LIST .= " AND d.userid != ".getConfig('bonus_uid')."";
+       if (EXT_IS_ACTIVE('doubler')) $EXCLUDE_LIST .= " AND d.userid != ".getConfig('doubler_uid')."";
 
        // Check for new holiday extension
-       if (GET_EXT_VERSION("holiday") >= "0.1.3") {
+       if (GET_EXT_VERSION('holiday') >= '0.1.3') {
                // Include only users with no active holiday
                $EXCLUDE_LIST .= " AND d.holiday_active='N'";
        } // END - if
@@ -82,7 +82,7 @@ ORDER BY d.userid", array($since, $since, $since), __FILE__, __LINE__);
 
        if (SQL_NUMROWS($result_inactive) > 0) {
                // Prepare variables and constants...
-               $UIDs = "";
+               $UIDs = '';
                define('__INACTIVE_SINCE', (getConfig('ap_inactive_since') / 60 / 60));
                define('__INACTIVE_TIME' , (getConfig('ap_in_time')  / 60 / 60));
 
@@ -107,7 +107,7 @@ ORDER BY d.userid", array($since, $since, $since), __FILE__, __LINE__);
                $UIDs = str_replace(", ", "\n", substr($UIDs, 0, -2));
 
                // Send mail notification to admin
-               SEND_ADMIN_NOTIFICATION(getMessage('AUTOPURGE_ADMIN_INACTIVE_SUBJECT'), "admin_autopurge_inactive", $UIDs, "");
+               SEND_ADMIN_NOTIFICATION(getMessage('AUTOPURGE_ADMIN_INACTIVE_SUBJECT'), "admin_autopurge_inactive", $UIDs, '');
        } // END - if
 
        // Free memory
@@ -124,7 +124,7 @@ ORDER BY userid",
                array($since, $since, $time), __FILE__, __LINE__);
        if (SQL_NUMROWS($result_inactive) > 0) {
                // Prepare variable...
-               $UIDs = "";
+               $UIDs = '';
 
                // Delete inactive accounts
                while ($content = SQL_FETCHARRAY($result_inactive)) {
@@ -135,15 +135,15 @@ ORDER BY userid",
                        $content['last_online'] = MAKE_DATETIME($content['last_online'], "0");
 
                        // Finnaly delete this inactive account
-                       DELETE_USER_ACCOUNT($content['userid'], LOAD_EMAIL_TEMPLATE("member_autopurge_delete", $content['last_online'], ""));
+                       DELETE_USER_ACCOUNT($content['userid'], LOAD_EMAIL_TEMPLATE("member_autopurge_delete", $content['last_online'], ''));
                } // END - while
 
                // Remove last comma
                $UIDs = str_replace(", ", "\n", substr($UIDs, 0, -2));
 
                // Send mail notification to admin
-               if (getConfig('ap_in_notify') == "Y") {
-                       SEND_ADMIN_NOTIFICATION(getMessage('AUTOPURGE_ADMIN_DELETE_SUBJECT'), "admin_autopurge_delete", $UIDs, "");
+               if (getConfig('ap_in_notify') == 'Y') {
+                       SEND_ADMIN_NOTIFICATION(getMessage('AUTOPURGE_ADMIN_DELETE_SUBJECT'), "admin_autopurge_delete", $UIDs, '');
                } // END - if
        } // END - if
 
index 389c9279dd3fe2f77a5a84bb134f6116818ece6c..a592cc5a7d736c82e8c834fb445997ffeef2fc51 100644 (file)
@@ -43,13 +43,13 @@ if (!defined('__SECURITY')) {
 } // END - if
 
 // Abort if autopurge is not active or disabled by admin
-if ((!EXT_IS_ACTIVE("autopurge")) || (getConfig('auto_purge_active') != "Y")) {
+if ((!EXT_IS_ACTIVE('autopurge')) || (getConfig('auto_purge_active') != "Y")) {
        // Abort here
        return false;
 } // END - if
 
 // Search for mails from deleted members?
-if (getConfig('ap_del_mails') == "Y") {
+if (getConfig('ap_del_mails') == 'Y') {
        // Okay, let's check for them...
        $since = getConfig(('ap_dm_timeout'));
        $result_mails = SQL_QUERY_ESC("SELECT sender
@@ -122,9 +122,9 @@ ORDER BY sender ASC",
        SQL_FREERESULT($result_mails);
 
        // Do we have deleted mails and the admin want's to receive a notification
-       if (($DELETED > 0) && (getConfig('ap_dm_notify') == "Y")) {
+       if (($DELETED > 0) && (getConfig('ap_dm_notify') == 'Y')) {
                // Send out email to admin
-               SEND_ADMIN_NOTIFICATION(getMessage('AUTOPURGE_ADMIN_DEL_MAILS_SUBJECT'), "admin_autopurge_del_mails", $DELETED, "");
+               SEND_ADMIN_NOTIFICATION(getMessage('AUTOPURGE_ADMIN_DEL_MAILS_SUBJECT'), "admin_autopurge_del_mails", $DELETED, '');
        } // END - if
 }
 
index 8ef2be43f560a04a285fa83a62adc6be7de0904b..a27bc73cb76aa1a1afc1e8eb38bd1c1eca1a8b1d 100644 (file)
@@ -43,13 +43,13 @@ if (!defined('__SECURITY')) {
 } // END - if
 
 // Abort if autopurge is not active or disabled by admin
-if ((!EXT_IS_ACTIVE("autopurge")) || (getConfig('auto_purge_active') != "Y")) {
+if ((!EXT_IS_ACTIVE('autopurge')) || (getConfig('auto_purge_active') != "Y")) {
        // Abort here
        return false;
 } // END - if
 
 // Check version (must be > 0.0)
-if ((GET_EXT_VERSION("task") > "0.0") && (getConfig('ap_tasks') == "Y")) {
+if ((GET_EXT_VERSION('task') > '0.0') && (getConfig('ap_tasks') == 'Y')) {
        // Since when shall we purge?
        $since = getConfig(('ap_tasks_time'));
 
@@ -63,9 +63,9 @@ WHERE `status`='DELETED' AND task_created <= (UNIX_TIMESTAMP() - %s)",
        $DELETED = SQL_AFFECTEDROWS();
 
        // Do we need to send a notification?
-       if (($DELETED > 0) && (getConfig('ap_tasks_notify') == "Y")) {
+       if (($DELETED > 0) && (getConfig('ap_tasks_notify') == 'Y')) {
                // Send out email to admin
-               SEND_ADMIN_NOTIFICATION(getMessage('AUTOPURGE_ADMIN_TASKS_SUBJECT'), "admin_autopurge_tsks", $DELETED, "");
+               SEND_ADMIN_NOTIFICATION(getMessage('AUTOPURGE_ADMIN_TASKS_SUBJECT'), "admin_autopurge_tsks", $DELETED, '');
        } // END - if
 } // END - if
 
index 6066b6098511275d4576d8a16f724b30ebe4f000..b029147dcff74d891452dbda57fa281a966a77fd 100644 (file)
@@ -43,13 +43,13 @@ if (!defined('__SECURITY')) {
 } // END - if
 
 // Abort if autopurge is not active or disabled by admin
-if ((!EXT_IS_ACTIVE("autopurge")) || (getConfig('auto_purge_active') != "Y")) {
+if ((!EXT_IS_ACTIVE('autopurge')) || (getConfig('auto_purge_active') != "Y")) {
        // Abort here
        return false;
 } // END - if
 
 // Shall I auto-purge unconfirmed accounts?
-if (getConfig('autopurge_unconfirmed') == "Y") {
+if (getConfig('autopurge_unconfirmed') == 'Y') {
        // Init variables and find unconfirmed accounts which I shall auto-purge
        $time = getConfig(('ap_un_time'));
        $result_uncon = SQL_QUERY_ESC("SELECT userid, email, joined
@@ -59,7 +59,7 @@ ORDER BY userid ASC",
                array($time), __FILE__, __LINE__);
        if (SQL_NUMROWS($result_uncon) > 0) {
                // Prepare variable...
-               $UIDs = "";
+               $UIDs = '';
                define('__UNCONFIRMED_TIME' , (getConfig('ap_un_time')  / 60 / 60));
 
                // Delete inactive accounts
@@ -71,15 +71,15 @@ ORDER BY userid ASC",
                        $content['joined'] = MAKE_DATETIME($content['joined'], "0");
 
                        // Finnaly delete this inactive account
-                       DELETE_USER_ACCOUNT($content['userid'], LOAD_EMAIL_TEMPLATE("member_autopurge_unconfirmed", $content['joined'], ""));
+                       DELETE_USER_ACCOUNT($content['userid'], LOAD_EMAIL_TEMPLATE("member_autopurge_unconfirmed", $content['joined'], ''));
                } // END - while
 
                // Remove last comma
                $UIDs = str_replace(", ", "\n", substr($UIDs, 0, -2));
 
                // Send mail notification to admin
-               if (getConfig('ap_un_notify') == "Y") {
-                       SEND_ADMIN_NOTIFICATION(getMessage('AUTOPURGE_ADMIN_UNCONFIRMED_SUBJECT'), "admin_autopurge_unconfirmed", $UIDs, "");
+               if (getConfig('ap_un_notify') == 'Y') {
+                       SEND_ADMIN_NOTIFICATION(getMessage('AUTOPURGE_ADMIN_UNCONFIRMED_SUBJECT'), "admin_autopurge_unconfirmed", $UIDs, '');
                } // END - if
        } // END - if
 
index 66ae2e02f620be1ca36c95fbf5f12100ea948bc6..b977e2af621fc45d220b16ea487d2af6cf9e0205 100644 (file)
@@ -127,10 +127,10 @@ function loadConfiguration ($no="0") {
                } // END - foreach
 
                // Count cache hits if exists
-               if ((isset($_CONFIG['cache_hits'])) && (EXT_IS_ACTIVE("cache"))) {
+               if ((isset($_CONFIG['cache_hits'])) && (EXT_IS_ACTIVE('cache'))) {
                        $_CONFIG['cache_hits']++;
                } // END - if
-       } elseif ((!EXT_IS_ACTIVE("cache")) || (!isset($GLOBALS['cache_array']['config'][$no]))) {
+       } elseif ((!EXT_IS_ACTIVE('cache')) || (!isset($GLOBALS['cache_array']['config'][$no]))) {
                // Load config from DB
                $result_config = SQL_QUERY_ESC("SELECT * FROM `{!_MYSQL_PREFIX!}_config` WHERE config=%d LIMIT 1",
                        array(bigintval($no)), __FUNCTION__, __LINE__);
index 7aac6dd321c16590fffac3d0c691803bcb51ecad..8e7f98bf0cf7a02fc4dd9e599d0a4c823d76328c 100644 (file)
@@ -111,7 +111,7 @@ define('CACHE_BUSTER', mt_rand(1000000, 9999999));
 define('DEBUG_SQL', false);
 
 // Extra title is empty by default
-$EXTRA_TITLE = "";
+$EXTRA_TITLE = '';
 
 //
 ?>
index e0c63d2f0198c9a3fe09bcfa1c6757f98fbed5fe..5346e70595a3145604dd1b1b87538d56c0370816 100644 (file)
@@ -90,7 +90,7 @@ Query string:<br />
                        fwrite($fp, "Module=".$GLOBALS['module']."\n");
                        $GLOBALS['sql_first_entry'] = true;
                } // END - if
-               fwrite($fp, $F."(LINE=".$L."|NUM=".SQL_NUMROWS($result)."|AFFECTED=".SQL_AFFECTEDROWS()."|QUERYTIME:".$queryTime."): ".str_replace('\r', "", str_replace('\n', " ", $sql_string))."\n");
+               fwrite($fp, $F."(LINE=".$L."|NUM=".SQL_NUMROWS($result)."|AFFECTED=".SQL_AFFECTEDROWS()."|QUERYTIME:".$queryTime."): ".str_replace('\r', '', str_replace('\n', " ", $sql_string))."\n");
                fclose($fp);
        } // END - if
 
@@ -212,12 +212,12 @@ function SQL_CLOSE ($F, $L) {
 
        // Do we need to update cache/db counter?
        //* DEBUG: */ echo "DB=".getConfig('db_hits').",CACHE=".getConfig('cache_hits')."<br />\n";
-       if ((GET_EXT_VERSION("cache") >= "0.0.7") && (getConfig('db_hits') > 0) && (getConfig('cache_hits') > 0) && (isCacheInstanceValid())) {
+       if ((GET_EXT_VERSION('cache') >= '0.0.7') && (getConfig('db_hits') > 0) && (getConfig('cache_hits') > 0) && (isCacheInstanceValid())) {
                // Add new hits
                incrementConfigEntry('db_hits', getConfig('db_hits_run'));
 
                // Update counter for db/cache
-               UPDATE_CONFIG(array("db_hits", "cache_hits"), array(getConfig(('db_hits')), getConfig(('cache_hits'))));
+               UPDATE_CONFIG(array('db_hits', 'cache_hits'), array(getConfig(('db_hits')), getConfig(('cache_hits'))));
        } // END - if
 
        // Close database link and forget the link
@@ -274,7 +274,7 @@ function SQL_QUERY_ESC ($qstring, $data, $F, $L, $run=true, $strip=true, $secure
        // Debugging
        //
        //* DEBUG: */ $fp = fopen(constant('PATH')."inc/cache/escape_debug.log", 'a') or app_die(__FILE__, __LINE__, "Cannot write debug.log!");
-       //* DEBUG: */ fwrite($fp, $F."(".$L."): ".str_replace("\r", "", str_replace("\n", " ", $eval))."\n");
+       //* DEBUG: */ fwrite($fp, $F."(".$L."): ".str_replace("\r", '', str_replace("\n", " ", $eval))."\n");
        //* DEBUG: */ fclose($fp);
 
        // Run the code
@@ -356,12 +356,12 @@ function SQL_ALTER_TABLE ($sql, $F, $L) {
 
        // Extract table name
        $tableArray = explode(" ", $sql);
-       $tableName = str_replace("`", "", $tableArray[2]);
+       $tableName = str_replace("`", '', $tableArray[2]);
 
        // Shall we add/drop?
        if (((ereg("ADD", $sql)) || (ereg("DROP", $sql))) && ($noIndex)) {
                // And column name as well
-               $columnName = str_replace("`", "", $tableArray[4]);
+               $columnName = str_replace("`", '', $tableArray[4]);
 
                // Get column information
                $result = SQL_QUERY_ESC("SHOW COLUMNS FROM %s LIKE '%s'",
@@ -379,7 +379,7 @@ function SQL_ALTER_TABLE ($sql, $F, $L) {
                //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("Skipped FULLTEXT: sql=%s,file=%s,line=%s", $sql, $F, $L));
        } elseif (!$noIndex) {
                // And column name as well
-               $columnName = str_replace("`", "", $tableArray[4]);
+               $columnName = str_replace("`", '', $tableArray[4]);
 
                // Is this "UNIQUE" or so? FULLTEXT has been handled the elseif() block above
                if (in_array(strtoupper($columnName), array("INDEX", "UNIQUE", "KEY", "FULLTEXT"))) {
@@ -387,11 +387,11 @@ function SQL_ALTER_TABLE ($sql, $F, $L) {
                        $begin = 1; $columnName = ",";
                        while (strpos($columnName, ",") !== false) {
                                // Use last
-                               $columnName = str_replace("`", "", $tableArray[count($tableArray) - $begin]);
+                               $columnName = str_replace("`", '', $tableArray[count($tableArray) - $begin]);
                                //* DEBUG: */ print __LINE__.":".$columnName."----------------".$begin."<br />\n";
 
                                // Remove brackes
-                               $columnName = str_replace("(", "", str_replace(")", "", $columnName));
+                               $columnName = str_replace("(", '', str_replace(")", '', $columnName));
                                //* DEBUG: */ print __LINE__.":".$columnName."----------------".$begin."<br />\n";
 
                                // Continue
index 8aceddd494f9db03287dcbc01e6caa2d550e7dc2..1ba26c71d321db460a6d5d6a224313d5fbcf6593 100644 (file)
@@ -55,7 +55,7 @@ if ($DOUBLER_POINTS == 0) {
 // If not currently doubled set it to zero
 unset($_GET['DOUBLER_UID']);
 unset($_POST['DOUBLER_UID']);
-set_session('DOUBLER_UID', "");
+set_session('DOUBLER_UID', '');
 if (empty($GLOBALS['doubler_uid'])) $GLOBALS['doubler_uid'] = 0;
 
 // Check for doubles which we can pay out
@@ -77,17 +77,17 @@ ORDER BY d.timemark
 LIMIT %d", array($DOUBLER_POINTS, $min, getConfig('doubler_max_sent')), __FILE__, __LINE__);
 
 // Do we have entries found?
-if (((SQL_NUMROWS($result_total) > 0) && (getConfig('doubler_sent_all') == "Y")) || ((SQL_NUMROWS($result_main) == getConfig('doubler_group_sent')) && (getConfig('doubler_sent_all') != "Y"))) {
+if (((SQL_NUMROWS($result_total) > 0) && (getConfig('doubler_sent_all') == 'Y')) || ((SQL_NUMROWS($result_main) == getConfig('doubler_group_sent')) && (getConfig('doubler_sent_all') != "Y"))) {
        // Switch to matching SQL resource
        $result_load = $result_main;
-       if ((SQL_NUMROWS($result_total) > 0) && (getConfig('doubler_sent_all') == "Y")) $result_load = $result_total;
+       if ((SQL_NUMROWS($result_total) > 0) && (getConfig('doubler_sent_all') == 'Y')) $result_load = $result_total;
 
        // At least one account was found
        while ($content = SQL_FETCHARRAY($result_load)) {
                // Only double when points are enougth!
                if ($DOUBLER_POINTS >= $content['points']) {
                        // Check for his ref points
-                       $ref = GET_TOTAL_DATA($content['userid'], "doubler", "points", "refid", false, " AND completed='N' AND is_ref='Y'");
+                       $ref = GET_TOTAL_DATA($content['userid'], 'doubler', 'points', 'refid', false, " AND completed='N' AND is_ref='Y'");
 
                        // Zero refid when empty (might be helpful!)
                        if (empty($ref)) $ref = 0;
@@ -113,7 +113,7 @@ if (((SQL_NUMROWS($result_total) > 0) && (getConfig('doubler_sent_all') == "Y"))
 
                        $okay = false;
                        // Check for jackpot inclusion in doubling process
-                       if (($jackpot > 0) && ($jackpot >= $content['points']) && (getConfig('doubler_jackpot') == "Y")) {
+                       if (($jackpot > 0) && ($jackpot >= $content['points']) && (getConfig('doubler_jackpot') == 'Y')) {
                                // Subtract points from jackpot
                                SUB_JACKPOT($content['points']);
                                $jackpot -= $content['points'];
index 2ef4bb88fdbdf051f0961a29ed6e0db091a88073..18650ab5e0c1af0660ba359ee3ff2d8bdb2380b8 100644 (file)
@@ -113,7 +113,7 @@ function LOAD_EXTENSION ($ext_name, $EXT_LOAD_MODE = "", $EXT_VER = "", $dry_run
        require($FQFN);
 
        // Is this extension deprecated?
-       if (EXT_GET_DEPRECATED() == "Y") {
+       if (EXT_GET_DEPRECATED() == 'Y') {
                // Deactivate the extension
                DEACTIVATE_EXTENSION($ext_name);
 
@@ -184,7 +184,7 @@ function REGISTER_EXTENSION ($ext_name, $task_id, $dry_run = false, $logout = tr
 
        // Does this extension exists?
        //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, "currName=".EXT_GET_CURR_NAME()."");
-       if (LOAD_EXTENSION(EXT_GET_CURR_NAME(), "register", "", $dry_run)) {
+       if (LOAD_EXTENSION(EXT_GET_CURR_NAME(), 'register', '', $dry_run)) {
                // Set current extension name again
                EXT_SET_CURR_NAME($ext_name);
 
@@ -194,7 +194,7 @@ function REGISTER_EXTENSION ($ext_name, $task_id, $dry_run = false, $logout = tr
                foreach ($history as $ver) {
                        //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, "ext_name=".EXT_GET_CURR_NAME().", ext_ver={$ver}");
                        // Load extension in update mode
-                       LOAD_EXTENSION(EXT_GET_CURR_NAME(), "update", $ver, $dry_run);
+                       LOAD_EXTENSION(EXT_GET_CURR_NAME(), 'update', $ver, $dry_run);
 
                        // Add update notes to our output
                        ADD_EXTENSION_NOTES($ver);
@@ -209,7 +209,7 @@ function REGISTER_EXTENSION ($ext_name, $task_id, $dry_run = false, $logout = tr
                        EXT_INCREMENT_UPDATE_INTERATOR();
 
                        // Check for required file
-                       if (LOAD_EXTENSION($ext_update, "register", "", $dry_run)) {
+                       if (LOAD_EXTENSION($ext_update, 'register', '', $dry_run)) {
                                // Set current extension name again
                                EXT_SET_CURR_NAME($ext_name);
 
@@ -255,7 +255,7 @@ function REGISTER_EXTENSION ($ext_name, $task_id, $dry_run = false, $logout = tr
                } // END - if
 
                // Switch back to register mode
-               $EXT_LOAD_MODE = "register";
+               $EXT_LOAD_MODE = 'register';
 
                // Remains true if extension registration reports no failures
                //* DEBUG: */ print __FUNCTION__."[".__LINE__."]:currName=".EXT_GET_CURR_NAME().":"; var_dump($test);
@@ -275,6 +275,7 @@ function REGISTER_EXTENSION ($ext_name, $task_id, $dry_run = false, $logout = tr
                                runFilterChain('pre_extension_installed', array('dry_run' => $dry_run));
 
                                // Register extension
+                               //* DEBUG: */ print __FUNCTION__."[".__LINE__."]:insert=".EXT_GET_CURR_NAME()."/".EXT_GET_VERSION()." - INSERT!<br />\n";
                                SQL_QUERY_ESC("INSERT INTO `{!_MYSQL_PREFIX!}_extensions` (ext_name, ext_active, ext_version) VALUES ('%s','%s','%s')",
                                        array(EXT_GET_CURR_NAME(), EXT_GET_ALWAYS_ACTIVE(), EXT_GET_VERSION()), __FUNCTION__, __LINE__);
 
@@ -320,7 +321,7 @@ function REGISTER_EXTENSION ($ext_name, $task_id, $dry_run = false, $logout = tr
 
        // Is this the sql_patches?
        //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, ":".EXT_GET_CURR_NAME()."/{$EXT_LOAD_MODE}");
-       if ((EXT_GET_CURR_NAME() == "sql_patches") && (($EXT_LOAD_MODE == "register") || ($EXT_LOAD_MODE == "remove")) && (!$dry_run) && ($test)) {
+       if ((EXT_GET_CURR_NAME() == 'sql_patches') && (($EXT_LOAD_MODE == 'register') || ($EXT_LOAD_MODE == 'remove')) && (!$dry_run) && ($test)) {
                //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, ": LOAD!");
                if ($logout === true) {
                        // Then redirect to logout
@@ -364,7 +365,7 @@ function EXTENSION_RUN_SQLS ($ext_id, $load_mode) {
 
        // Load extension in detected mode
        //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, ":ext_name[{$ext_id}]=".EXT_GET_CURR_NAME()."");
-       LOAD_EXTENSION(EXT_GET_CURR_NAME(), $load_mode, "", false);
+       LOAD_EXTENSION(EXT_GET_CURR_NAME(), $load_mode, '', false);
 
        // Init these SQLs
        INIT_SQLS();
@@ -376,7 +377,7 @@ function EXTENSION_RUN_SQLS ($ext_id, $load_mode) {
                runFilterChain('run_sqls');
 
                // Removal mode?
-               if ($load_mode == "remove") {
+               if ($load_mode == 'remove') {
                        // Delete this extension (remember to remove it from your server *before* you click on welcome!
                        SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_extensions` WHERE ext_name='%s' LIMIT 1",
                                array(EXT_GET_CURR_NAME()), __FUNCTION__, __LINE__);
@@ -384,14 +385,14 @@ function EXTENSION_RUN_SQLS ($ext_id, $load_mode) {
        } // END - if
 
        // Remove cache file(s) if extension is active
-       if (((EXT_IS_ACTIVE("cache")) || (GET_EXT_VERSION("cache") != "")) && (((SQL_AFFECTEDROWS() == 1)) || ($sqlRan === true) || ($load_mode == "activate") || ($load_mode == "deactivate"))) {
+       if (((EXT_IS_ACTIVE('cache')) || (GET_EXT_VERSION('cache') != "")) && (((SQL_AFFECTEDROWS() == 1)) || ($sqlRan === true) || ($load_mode == 'activate') || ($load_mode == 'deactivate'))) {
                // Run filters
                runFilterChain('post_extension_run_sql', EXT_GET_CURR_NAME());
        } // END - if
 
        // Is this the sql_patches?
        //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, ": id=".$ext_id.",currName=".EXT_GET_CURR_NAME().",loadMode=".$load_mode);
-       if ((EXT_GET_CURR_NAME() == "sql_patches") && (($load_mode == "register") || ($load_mode == "remove"))) {
+       if ((EXT_GET_CURR_NAME() == 'sql_patches') && (($load_mode == 'register') || ($load_mode == 'remove'))) {
                // Then redirect to logout
                //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, ": LOAD!");
                LOAD_URL("modules.php?module=admin&amp;logout=1&amp;".$load_mode."=sql_patches");
@@ -417,7 +418,7 @@ function EXT_IS_ACTIVE ($ext_name) {
        } elseif (isset($GLOBALS['ext_loaded'][$ext_name])) {
                // @TODO Extension is loaded, what next?
                app_die(__FUNCTION__, __LINE__, "LOADED:$ext_name");
-       } elseif (($ext_name == "cache") || (GET_EXT_VERSION("cache") == "")) {
+       } elseif (($ext_name == 'cache') || (GET_EXT_VERSION('cache') == "")) {
                //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, "DB! ext_name={$ext_name}");
                // Load from database
                $result = SQL_QUERY_ESC("SELECT ext_active FROM `{!_MYSQL_PREFIX!}_extensions` WHERE ext_name='%s' LIMIT 1",
@@ -445,7 +446,7 @@ function EXT_IS_ACTIVE ($ext_name) {
        //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, " ext_name={$ext_name},active={$active}");
 
        // Is this extension activated? (For admins we always have active extensions...)
-       return ($active == "Y");
+       return ($active == 'Y');
 }
 // Get version from extensions
 function GET_EXT_VERSION ($ext_name) {
@@ -508,7 +509,7 @@ function EXTENSION_UPDATE ($ext_name, $ext_ver, $dry_run = false) {
        INIT_INC_POOL();
 
        // Load extension in test mode
-       LOAD_EXTENSION($ext_name, "test", $ext_ver, $dry_run);
+       LOAD_EXTENSION($ext_name, 'test', $ext_ver, $dry_run);
 
        // Save version history
        $history = EXT_GET_VER_HISTORY();
@@ -527,7 +528,7 @@ function EXTENSION_UPDATE ($ext_name, $ext_ver, $dry_run = false) {
                        $GLOBALS['cache_array']['update_ver'][EXT_GET_CURR_NAME()] = $history[$idx];
 
                        // Load again...
-                       LOAD_EXTENSION(EXT_GET_CURR_NAME(), "update", $GLOBALS['cache_array']['update_ver'][EXT_GET_CURR_NAME()], $dry_run);
+                       LOAD_EXTENSION(EXT_GET_CURR_NAME(), 'update', $GLOBALS['cache_array']['update_ver'][EXT_GET_CURR_NAME()], $dry_run);
 
                        if (EXT_GET_UPDATE_DEPENDS() != "") {
                                // Is the extension there?
@@ -593,10 +594,10 @@ function EXTENSION_VERBOSE_TABLE ($queries = array(), $title = "", $dashed = "",
 
        // Init variables
        $SW = 2; $i = 1;
-       $OUT = "";
+       $OUT = '';
 
        // Do we have queries?
-       if ((IS_SQLS_VALID()) && (GET_EXT_VERSION("sql_patches") >= "0.0.7") && (getConfig('verbose_sql') == "Y")) {
+       if ((IS_SQLS_VALID()) && (GET_EXT_VERSION('sql_patches') >= '0.0.7') && (getConfig('verbose_sql') == 'Y')) {
                foreach (GET_SQLS() as $idx => $sql) {
                        // Trim out spaces
                        $sql = trim($sql);
@@ -629,9 +630,9 @@ function EXTENSION_VERBOSE_TABLE ($queries = array(), $title = "", $dashed = "",
 
                // Load main template
                $OUT = LOAD_TEMPLATE("admin_ext_sql_table", true, $content);
-       } elseif ((GET_EXT_VERSION("sql_patches") >= "0.0.7") && (getConfig('verbose_sql') == "Y")) {
+       } elseif ((GET_EXT_VERSION('sql_patches') >= '0.0.7') && (getConfig('verbose_sql') == 'Y')) {
                // No addional SQL commands to run
-               $OUT = LOAD_TEMPLATE("admin_settings_saved", true, getMessage('ADMIN_NO_ADDITIONAL_SQLS'));
+               $OUT = LOAD_TEMPLATE('admin_settings_saved', true, getMessage('ADMIN_NO_ADDITIONAL_SQLS'));
        } // END - if
 
        // Return output
@@ -641,7 +642,7 @@ function EXTENSION_VERBOSE_TABLE ($queries = array(), $title = "", $dashed = "",
 // Get extension name from id
 function GET_EXT_NAME ($ext_id) {
        // Init extension name
-       $ret = "";
+       $ret = '';
 
        // Is cache there?
        if (isset($GLOBALS['cache_array']['extensions']['ext_name'][$ext_id])) {
@@ -650,7 +651,7 @@ function GET_EXT_NAME ($ext_id) {
 
                // Count cache hits
                incrementConfigEntry('cache_hits');
-       } elseif (!EXT_IS_ACTIVE("cache")) {
+       } elseif (!EXT_IS_ACTIVE('cache')) {
                // Load from database
                $result = SQL_QUERY_ESC("SELECT ext_name FROM `{!_MYSQL_PREFIX!}_extensions` WHERE id=%s LIMIT 1",
                        array(bigintval($ext_id)), __FUNCTION__, __LINE__);
@@ -670,7 +671,7 @@ function GET_EXT_ID ($ext_name) {
 
                // Count cache hits
                incrementConfigEntry('cache_hits');
-       } elseif (!EXT_IS_ACTIVE("cache")) {
+       } elseif (!EXT_IS_ACTIVE('cache')) {
                // Load from database
                $result = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_extensions` WHERE ext_name='%s' LIMIT 1",
                        array($ext_name), __FUNCTION__, __LINE__);
@@ -691,7 +692,7 @@ function ACTIVATE_EXTENSION ($ext_name) {
        // Extension has been activated?
        if (SQL_AFFECTEDROWS() == 1) {
                // Then run all queries
-               EXTENSION_RUN_SQLS(GET_EXT_ID($ext_name), "activate");
+               EXTENSION_RUN_SQLS(GET_EXT_ID($ext_name), 'activate');
        } // END - if
 }
 
@@ -704,7 +705,7 @@ function DEACTIVATE_EXTENSION($ext_name) {
        // Extension has been activated?
        if (SQL_AFFECTEDROWS() == 1) {
                // Then run all queries
-               EXTENSION_RUN_SQLS(GET_EXT_ID($ext_name), "deactivate");
+               EXTENSION_RUN_SQLS(GET_EXT_ID($ext_name), 'deactivate');
 
                // Create new task
                CREATE_EXTENSION_DEACTIVATION_TASK($ext_name);
@@ -724,8 +725,8 @@ function EXT_VERSION_IS_OLDER ($ext_name, $ext_ver) {
        $currVersion = GET_EXT_VERSION($ext_name);
 
        // Remove all dots from both versions
-       $currVersion = str_replace(".", "", $currVersion);
-       $ext_ver = str_replace(".", "", $ext_ver);
+       $currVersion = str_replace(".", '', $currVersion);
+       $ext_ver = str_replace(".", '', $ext_ver);
 
        // Now compare both and return the result
        return ($currVersion < $ext_ver);
@@ -805,22 +806,22 @@ function MODULE_HAS_MENU ($mod, $forceDb = false) {
        // All is false by default
        $ret = false;
 
-       //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, "mod={$mod},cache=".GET_EXT_VERSION("cache"));
-       if (GET_EXT_VERSION("cache") >= "0.1.2") {
+       //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, "mod={$mod},cache=".GET_EXT_VERSION('cache'));
+       if (GET_EXT_VERSION('cache') >= '0.1.2') {
                // Cache version is okay, so let's check the cache!
                if (isset($GLOBALS['cache_array']['modules']['has_menu'][$mod])) {
                        // Check module cache and count hit
-                       $ret = ($GLOBALS['cache_array']['modules']['has_menu'][$mod] == "Y");
+                       $ret = ($GLOBALS['cache_array']['modules']['has_menu'][$mod] == 'Y');
                        incrementConfigEntry('cache_hits');
                } elseif (isset($GLOBALS['cache_array']['extensions']['ext_menu'][$mod])) {
                        // Check cache and count hit
-                       $ret = ($GLOBALS['cache_array']['extensions']['ext_menu'][$mod] == "Y");
+                       $ret = ($GLOBALS['cache_array']['extensions']['ext_menu'][$mod] == 'Y');
                        incrementConfigEntry('cache_hits');
-               } elseif ((IS_ADMIN()) && ($mod == "admin")) {
+               } elseif ((IS_ADMIN()) && ($mod == 'admin')) {
                        // Admin module has always a menu!
                        $ret = true;
                }
-       } elseif ((GET_EXT_VERSION("sql_patches") >= "0.3.6") && ((!EXT_IS_ACTIVE("cache")) || ($forceDb === true))) {
+       } elseif ((GET_EXT_VERSION('sql_patches') >= '0.3.6') && ((!EXT_IS_ACTIVE('cache')) || ($forceDb === true))) {
                // Check database for entry
                $result = SQL_QUERY_ESC("SELECT has_menu FROM `{!_MYSQL_PREFIX!}_mod_reg` WHERE `module`='%s' LIMIT 1",
                        array($mod), __FUNCTION__, __LINE__);
@@ -834,14 +835,14 @@ function MODULE_HAS_MENU ($mod, $forceDb = false) {
                        $GLOBALS['cache_array']['extensions']['ext_menu'][$mod] = $has_menu;
 
                        // Does it have a menu?
-                       $ret = ($has_menu == "Y");
+                       $ret = ($has_menu == 'Y');
                } // END  - if
 
                // Free memory
                SQL_FREERESULT($result);
-       } elseif (GET_EXT_VERSION("sql_patches") == "") {
+       } elseif (GET_EXT_VERSION('sql_patches') == "") {
                // No sql_patches installed, so maybe in admin area or no admin registered?
-               $ret = (((IS_ADMIN()) || (!isAdminRegistered())) && ($mod == "admin")); // Then there is a menu!
+               $ret = (((IS_ADMIN()) || (!isAdminRegistered())) && ($mod == 'admin')); // Then there is a menu!
        }
 
        // Return status
@@ -896,13 +897,13 @@ function DETERMINE_TASK_ID_BY_SUBJECT ($subject) {
 // Add updates notes for given version
 function ADD_EXTENSION_NOTES ($ver) {
        // Init notes/content
-       $out = ""; $content = array();
+       $out = ''; $content = array();
 
        // Is do we have verbose output enabled?
-       if ((getConfig('verbose_sql') == "Y") || (!EXT_IS_ACTIVE("sql_patches"))) {
+       if ((getConfig('verbose_sql') == 'Y') || (!EXT_IS_ACTIVE('sql_patches'))) {
 
                // Update notes found?
-               if (EXT_GET_UPDATE_NOTES() != "") {
+               if (EXT_GET_UPDATE_NOTES() != '') {
                        // Update notes found
                        $content = array(
                                'ver'   => $ver,
@@ -911,7 +912,7 @@ function ADD_EXTENSION_NOTES ($ver) {
 
                        // Reset them
                        EXT_SET_UPDATE_NOTES("");
-               } elseif (($ver == "0.0") || ($ver == "0.0.0")) {
+               } elseif (($ver == '0.0') || ($ver == '0.0.0')) {
                        // Initial release
                        $content = array(
                                'ver'   => $ver,
@@ -926,7 +927,7 @@ function ADD_EXTENSION_NOTES ($ver) {
                }
 
                // Load template
-               $out = LOAD_TEMPLATE("admin_ext_notes", true, $content);
+               $out = LOAD_TEMPLATE('admin_ext_notes', true, $content);
        } // END - if
 
        // Add the notes
@@ -978,7 +979,7 @@ function EXT_GET_ALWAYS_ACTIVE () {
 
 // Setter for EXT_VERSION flag
 function EXT_SET_VERSION ($version) {
-       $GLOBALS['ext_version'][EXT_GET_CURR_NAME()] = (float) $version;
+       $GLOBALS['ext_version'][EXT_GET_CURR_NAME()] = (string) $version;
 }
 
 // Getter for EXT_VERSION flag
@@ -1145,7 +1146,7 @@ function EXT_GET_UPDATE_NOTES () {
 
 // Init extension notice
 function EXT_INIT_NOTES () {
-       $GLOBALS['ext_notes'] = "";
+       $GLOBALS['ext_notes'] = '';
 }
 
 // Append extension notice
index c0117b452c9543fb878cc17cd261bfee273d9ee7..89fef58f4869bc2516ba19782705c9e1c371715c 100644 (file)
@@ -43,33 +43,33 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                $SQLs[] = "";
 
                // Update notes (these will be set as task text!)
@@ -78,10 +78,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index cd70f5108a0a26ddb64188f0abdcbb12e078ddeb..0b1f195e77399e000715929165194ed6fa556fa6 100644 (file)
@@ -43,19 +43,19 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.9");
+EXT_SET_VERSION('0.0.9');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','active','Heute Online', 10, 'N','Y')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_guest_menu` WHERE `what`='active'");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_active'");
@@ -64,40 +64,40 @@ case "remove": // Do stuff when removing extension
        UNREGISTER_FILTER('online_extra_links', 'ADD_LINK_ACTIVE_LIST', true, $dry_run);
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='N', `locked`='N' WHERE `what`='active' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='N', `locked`='Y' WHERE `what`='active' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wegen des Theme-Supportes hat sich die URL zur CSS-Datei ge&auml;ndert.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Design &quot;Solid-Business&quot; eingebaut.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD active_limit BIGINT(20) UNSIGNED NOT NULL DEFAULT 10");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_active','Aktiv-Liste','Einstellungen an der Aktiv-Liste (<strong>Heute Online</strong> im Gastbereich) vornehmen.', 8)");
 
@@ -105,24 +105,24 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Aktiven-Liste im Gastbereich ist nun einschr&auml;nkbar.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate: SQL-Anweisungen gesch&uuml;tzt.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
-               // Make update depending on "online"
-               EXT_ADD_UPDATE_DEPENDS("online");
+       case '0.0.9': // SQL queries for v0.0.9
+               // Make update depending on 'online'
+               EXT_ADD_UPDATE_DEPENDS('online');
 
                // Register filter
                REGISTER_FILTER('online_extra_links', 'ADD_LINK_ACTIVE_LIST', false, true, $dry_run);
@@ -133,10 +133,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 7e9265b9c083028e91be51a5fc470f9650b7078c..19c8387927828f5ac818919fafd2872f171d20c2 100644 (file)
@@ -43,21 +43,21 @@ if (!defined('__SECURITY')) {
 }
 
 // Version of this extension
-EXT_SET_VERSION("0.7.2");
+EXT_SET_VERSION('0.7.2');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.1", "0.2", "0.3", "0.3.1", "0.4.0", "0.4.1", "0.4.2", "0.4.3", "0.4.4", "0.4.5", "0.4.6", "0.4.7", "0.4.8", "0.4.9", "0.5.0", "0.5.1", "0.5.2", "0.5.3", "0.5.4", "0.5.5", "0.5.6", "0.5.7", "0.5.8", "0.5.9", "0.6.0", "0.6.1", "0.6.2", "0.6.3", "0.6.4", "0.6.5", "0.6.6", "0.6.7", "0.6.8", "0.6.9", "0.7.0", "0.7.1", "0.7.2"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.1.0', '0.2.0', '0.3.0', '0.3.1', '0.4.0', '0.4.1', '0.4.2', '0.4.3', '0.4.4', '0.4.5', '0.4.6', '0.4.7', '0.4.8', '0.4.9', '0.5.0', '0.5.1', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6', '0.5.7', '0.5.8', '0.5.9', '0.6.0', '0.6.1', '0.6.2', '0.6.3', '0.6.4', '0.6.5', '0.6.6', '0.6.7', '0.6.8', '0.6.9', '0.7.0', '0.7.1', '0.7.2'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('admins', NULL, 'Admin-Management','Administratoren anlegen, l&ouml;schen oder Passwort/E-Mail Adresse &auml;ndern.','1')");
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('admins','admins_add','Admin hinzuf&uuml;gen','Neuen Admin-Account anlegen','0')");
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('admins','admins_edit','Admin-Account &auml;ndern','Bestehende Admin-Accounts bearbeiten: E-Mail-Adresse, Passwort und/oder Login-Name &auml;ndern.','1')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `action`='admins'");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_admins_acls`");
@@ -68,27 +68,27 @@ case "remove": // Do stuff when removing extension
        UNREGISTER_FILTER('sql_admin_extra_data', 'ADD_EXTRA_SQL_DATA', true, $dry_run);
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.2": // SQL queries for v0.2
+       case '0.2.0': // SQL queries for v0.2
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('admins','admins_contact','Admin kontaktieren','Kontaktiert einen Admin per Mail oder Nachricht (nur wenn messaging-Erweiterung installiert ist).','2')");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("F&uuml;gt den Men&uuml;punkt &quot;Admin kontaktieren&quot; hinzu.");
                break;
 
-       case "0.3": // SQL queries for v0.3
+       case '0.3.0': // SQL queries for v0.3
                // Add admin menu
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('admins','config_admins','ACL einstellen','Richten Sie Zugriffskontrollzeilen f&uuml;r jeden Admin individuell ein, um ihm nur bestimmte Bereiche des Admin-Bereiches zug&auml;nglich zu machen oder zu sperren.','4')");
 
@@ -115,11 +115,11 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Sogn. ACLs werden hinzugef&uuml;gt: <strong>A</strong>ccess <strong>C</strong>ontrol <strong>L</strong>ines sind zu deutsch Zugriffkontrollzeilen, mit denen Sie einstellen k&ouml;nnen, was welcher Admin machen darf oder nicht.");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_admins_acls` MODIFY id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT");
                break;
 
-       case "0.4.0": // SQL queries for v0.4.0
+       case '0.4.0': // SQL queries for v0.4.0
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_admins_mails`");
                ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_admins_mails` (
 id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT,
@@ -134,160 +134,160 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Kontrollieren Sie, welche Mails welcher Admin oder alle (admin_id=0) bekommen soll oder im UserLog (admin_id=-1) verzeichnet werden soll. Standartm&auml;ssig wird weiter an alle versendet.");
                break;
 
-       case "0.4.1": // SQL queries for v0.4.1
+       case '0.4.1': // SQL queries for v0.4.1
                ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admins_mails` WHERE mail_template LIKE '% %'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Admins-Mails-Tabelle geleert.");
 
-       case "0.4.4": // SQL queries for v0.4.4
+       case '0.4.4': // SQL queries for v0.4.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("&amp;admin= in &amp;amp;admin= umgewandelt.");
                break;
 
-       case "0.4.5": // SQL queries for v0.4.5
+       case '0.4.5': // SQL queries for v0.4.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Vorbereitet auf Cache-System");
                break;
 
-       case "0.4.6": // SQL queries for v0.4.6
+       case '0.4.6': // SQL queries for v0.4.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit cache-Erweiterung gefixt. Der Admin-Bereich war permanent gesperrt.");
                break;
 
-       case "0.4.7": // SQL queries for v0.4.7
+       case '0.4.7': // SQL queries for v0.4.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Es wurde die Zeitmarke der Cache-Datei admins.cache mit ber&uuml;cksichtigt.");
                break;
 
-       case "0.4.8": // SQL queries for v0.4.8
+       case '0.4.8': // SQL queries for v0.4.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.4.9": // SQL queries for v0.4.9
+       case '0.4.9': // SQL queries for v0.4.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.5.0": // SQL queries for v0.5.0
+       case '0.5.0': // SQL queries for v0.5.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.5.1": // SQL queries for v0.5.1
+       case '0.5.1': // SQL queries for v0.5.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Cache wird endlich gel&oumlscht, wenn Admin entfernt wird.");
                break;
 
-       case "0.5.2": // SQL queries for v0.5.2
+       case '0.5.2': // SQL queries for v0.5.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("L&ouml;schen von Admin-Accounts repariert und HTML-Code ausgelagert in Templates.");
                break;
 
-       case "0.5.3": // SQL queries for v0.5.3
+       case '0.5.3': // SQL queries for v0.5.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.5.4": // SQL queries for v0.5.4
+       case '0.5.4': // SQL queries for v0.5.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("IP-Nummer und Browserbezeichnung wird in Admin-Mails eingesetzt.");
                break;
 
-       case "0.5.5": // SQL queries for v0.5.5
+       case '0.5.5': // SQL queries for v0.5.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkt Admin-Mails korregiert: SQL-Anweisung war fehlerhaft; und HTML-Code in Templates ausgelagert.");
                break;
 
-       case "0.5.6": // SQL queries for v0.5.6
+       case '0.5.6': // SQL queries for v0.5.6
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `what`='admins_contct' WHERE `what`='admins_contact' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Namenskonflikt zwischen den Erweiterungen <strong>admins</strong> und (kommender) <strong>contact</strong>.");
                break;
 
-       case "0.5.7": // SQL queries for v0.5.7
+       case '0.5.7': // SQL queries for v0.5.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Links wegen <strong>what=admins_contct</strong> ge&auml;ndert.");
                break;
 
-       case "0.5.8": // SQL queries for v0.5.8
+       case '0.5.8': // SQL queries for v0.5.8
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `what`='admins_contct' WHERE `what`='admins_contact' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ein Punkt in der Versionsnummernliste verhinderte das 0.5.6-Update.");
                break;
 
-       case "0.5.9": // SQL queries for v0.5.9
+       case '0.5.9': // SQL queries for v0.5.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate: SQL-Anweisungen gesch&uuml;tzt.");
                break;
 
-       case "0.6.0": // SQL queries for v0.6.0
+       case '0.6.0': // SQL queries for v0.6.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link in &quot;ACL Einstellen&quot; zum Admin-Kontaktformular korregiert.");
                break;
 
-       case "0.6.1": // SQL queries for v0.6.1
+       case '0.6.1': // SQL queries for v0.6.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Speichern von Admin-Accounts klappt wieder.");
                break;
 
-       case "0.6.2": // SQL queries for v0.6.2
+       case '0.6.2': // SQL queries for v0.6.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bitte verschieben Sie die admins-Templates (Ordner: {!PATH!}/templates/de/emails/) in den neuen Order admins!");
                break;
 
-       case "0.6.3": // SQL queries for v0.6.3
+       case '0.6.3': // SQL queries for v0.6.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.6.4": // SQL queries for v0.6.4
+       case '0.6.4': // SQL queries for v0.6.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit der Rechtevererbung beseitigt: Geben Sie nun ein Hauptmen&uuml; frei (Allow), dann kann der Admin auch die Untermen&uuml;s erreichen. Zudem k&ouml;nnen Sie gezielte Untermen&uuml;s im freigegeben Hauptmen&uuml; dennoch sperren.");
                break;
 
-       case "0.6.5": // SQL queries for v0.6.5
+       case '0.6.5': // SQL queries for v0.6.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
 
-       case "0.6.6": // SQL queries for v0.5.6
+       case '0.6.6': // SQL queries for v0.5.6
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `what`='admins_contct' WHERE `what`='admins_contact' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Namenskonflikt zwischen den Erweiterungen <strong>admins</strong> und (kommender) <strong>contact</strong>.");
                break;
 
-       case "0.6.7": // SQL queries for v0.6.7
+       case '0.6.7': // SQL queries for v0.6.7
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_admins` ADD la_mode ENUM('global','OLD','NEW') NOT NULL DEFAULT 'global'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Namenskonflikt zwischen den Erweiterungen <strong>admins</strong> und (kommender) <strong>contact</strong>. Beseitigung eines Fehlers <strong>HTTP_POSR_VARS</strong> beim &Auml;ndern von Administratoren.");
                break;
 
-       case "0.6.8": // SQL queries for v0.6.8
+       case '0.6.8': // SQL queries for v0.6.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("<strong>set_session()</strong> mit @-Zeichen gegen ungewollte Ausgaben abgesichert.");
                break;
 
-       case "0.6.9": // SQL queries for v0.6.9
+       case '0.6.9': // SQL queries for v0.6.9
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET title = 'Admin-Management' WHERE action = 'admins' AND (`what`='' OR `what` IS NULL) LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Verwaltung nach Management umbenannt.");
                break;
 
-       case "0.7.0": // SQL queries for v0.7.0
+       case '0.7.0': // SQL queries for v0.7.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Veraltetes Update.");
                break;
 
-       case "0.7.1": // SQL queries for v0.7.1
+       case '0.7.1': // SQL queries for v0.7.1
                // Update depends on sql_patches
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Add filters
                REGISTER_FILTER('sql_admin_extra_data', 'ADD_EXTRA_SQL_DATA', false, true, $dry_run);
@@ -296,7 +296,7 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Filter hinzugef&uuml;gt und ist von <strong>sql_patches</strong> abh&auml;ngig.");
                break;
 
-       case "0.7.2": // SQL queries for v0.7.2
+       case '0.7.2': // SQL queries for v0.7.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_admins` DROP login_failtures");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_admins` DROP last_failture");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_admins` ADD login_failures BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
@@ -308,10 +308,10 @@ PRIMARY KEY (id)
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index fa42a678589c27af87d0c30d2da6e9210ec7cf5c..b2f1b5ec160404a796486df73e57ab4dd98af338 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // Remove all other themes
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_extensions` WHERE ext_name LIKE 'admintheme%'");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `action`='stats' WHERE `what`='usr_online'");
@@ -58,35 +58,35 @@ case "register": // Do stuff when installation is running (modules.php?module=ad
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `action`='misc' WHERE `what`='maintenance'");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.1
+       case '0.0.1': // SQL queries for v0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index aec488f5f9b62f6ec4302be3dc5731282c45408e..087b949d713c539d53ef49cb2e1ab419d27f927b 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // Remove all other menu themes
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_extensions` WHERE ext_name LIKE 'admintheme%'");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `action`='misc' WHERE `what`='usr_online' LIMIT 1");
@@ -58,35 +58,35 @@ case "register": // Do stuff when installation is running (modules.php?module=ad
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `action`='setup' WHERE `what`='maintenance' LIMIT 1");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 87286979fd3a3f4c9ccba9c377769b8ac5be0af4..1fc7d6f3d30d3db7e00506cad72a6056d5b45cfe 100644 (file)
@@ -43,47 +43,45 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.4.0");
+EXT_SET_VERSION('0.4.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.1", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9", "0.3.0", "0.3.1", "0.3.2", "0.3.3", "0.3.4", "0.3.5", "0.3.6", "0.3.7", "0.3.8", "0.3.9", "0.4.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9', '0.4.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_pool` MODIFY data_type ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE','DELETED') NOT NULL DEFAULT 'TEMP'");
-       if (EXT_IS_ACTIVE("bonus"))
-       {
+       if (EXT_IS_ACTIVE('bonus')) {
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_bonus` MODIFY data_type ENUM('NEW','QUEUE','SEND','DELETED') NOT NULL DEFAULT 'NEW'");
        }
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_pool` MODIFY data_type ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE') NOT NULL DEFAULT 'TEMP'");
-       if (EXT_IS_ACTIVE("bonus"))
-       {
+       if (EXT_IS_ACTIVE('bonus')) {
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_bonus` MODIFY data_type ENUM('NEW','QUEUE','SEND') NOT NULL DEFAULT 'NEW'");
        }
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE what IN('config_autopurge','list_autopurge')");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` DROP ap_notified");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.1": // SQL queries for v0.1
+       case '0.1.0': // SQL queries for v0.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD autopurge_inactive ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD autopurge_unconfirmed ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD ap_inactive_since BIGINT(20) UNSIGNED NOT NULL DEFAULT '2592000'");
@@ -97,38 +95,38 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Automatisches L&ouml:schen von inaktiven bzw. nicht best&auml;tigten Accounts hinzugef&uuml;gt.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Automatisches L&ouml;schen von als zu l&ouml;schen markierte Tasks hinzugef&uuml;gt.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler <div class=\"admin_failed\">Warning: Missing argument 2 for create_timestamp_from_selections() in {!PATH!}inc/libs/pro_functions.php on line 227</div> behoben.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
 
                EXT_SET_UPDATE_NOTES("Anstelle von <strong>ref_depth</strong> wurde <strong>level</strong> programmiert.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD autopurge_tasks ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD ap_tasks_time BIGINT(20) UNSIGNED NOT NULL DEFAULT '".(getConfig('one_day')*7)."'");
 
@@ -136,7 +134,7 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Bereinigung von zu l&ouml;schenden Aufgaben klappt wieder. Zeitlimit f&uuml;r genanntes kann eingestellt werden (Default = 7 Tage).<br /><br /><u>Bitte aktualisieren Sie auch die Admin-Templates!</u>");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD ap_in_notify ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD ap_un_notify ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD ap_tasks_notify ENUM('Y','N') NOT NULL DEFAULT 'Y'");
@@ -145,67 +143,67 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Mail wird bei L&ouml;schung von Aufgaben ausgesendet.<br /><br /><u>Bitte aktualisieren Sie auch die Admin-Templates!</u>");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Diverse angebundene Erweiterungen gefixt.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Betreffzeile f&uuml;r gel&ouml;schte Aufgaben korregiert.");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erweiterung bleibt wegen integrierten Schalters immer aktiv.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Auto-L&ouml;schung von Best&auml;tigungslinks kann unter &quot;Sonstige Einstellungen&quot; abgeschaltet werden (0 setzen!)");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Jackpot beseitigt ({!POINTS!} wurden nicht gutgeschrieben.)");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link zum Mitgliedsprofil in Funktion <u>ADMIN_USER_PROFILE_LINK()</u> ausgelagert.");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link zum Mitgliedsprofil in Funktion <u>ADMIN_USER_PROFILE_LINK()</u> ausgelagert.");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mailbetreffs korregiert.");
                break;
 
-       case "0.3.0": // SQL queries for v0.3.0
+       case '0.3.0': // SQL queries for v0.3.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Template <u>admin_config_autopurge_pro.tpl</u> ist &uuml;berfl&uuml;ssig geworden. Bitte l&ouml;schen Sie dies!");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Datumsformat festgelegt auf ausf&uuml;hrlich.");
                break;
 
-       case "0.3.2": // SQL queries for v0.3.2
+       case '0.3.2': // SQL queries for v0.3.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.3.3": // SQL queries for v0.3.3
+       case '0.3.3': // SQL queries for v0.3.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD ap_del_mails ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD ap_dm_notify ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD ap_dm_timeout BIGINT(20) UNSIGNED NOT NULL DEFAULT '86400'");
@@ -214,47 +212,47 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Von bereits gel&ouml;schten Mitgliedern die Mails l&ouml;schen integriert.");
                break;
 
-       case "0.3.4": // SQL queries for v0.3.4
+       case '0.3.4': // SQL queries for v0.3.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler mit <strong>timestamp_send</strong> (Zeile 308) beseitigt.");
                break;
 
-       case "0.3.5": // SQL queries for v0.3.5
+       case '0.3.5': // SQL queries for v0.3.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler mit <strong>ap_del_emails</strong> (Einstellungen im Admin-Bereich) beseitigt.");
                break;
 
-       case "0.3.6": // SQL queries for v0.3.6
+       case '0.3.6': // SQL queries for v0.3.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Die Accounts der Standart-Referal-ID, der Bonus-ID, Bettellink-ID und der Verdoppler-ID werden nun nicht mehr gel&ouml;scht und tauchen auch unterhalb der Inaktiven-Liste nicht mehr auf.");
                break;
 
-       case "0.3.7": // SQL queries for v0.3.7
+       case '0.3.7': // SQL queries for v0.3.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.3.8": // SQL queries for v0.3.8
+       case '0.3.8': // SQL queries for v0.3.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Vorbereitung auf die neue Mediendaten v0.0.4.");
                break;
 
-       case "0.3.9": // SQL queries for v0.3.9
+       case '0.3.9': // SQL queries for v0.3.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("if-Anweisungen auf Funktion <strong>empty()</strong> umgestellt. Unter <strong>Auto-L&ouml;schung</strong> finden Sie nun auch die Einstellungen zu Mailbest&auml;tigungs wieder. Zudem werden keine Urlauber (neue Urlaubsschaltung beachtet) mehr als inaktiv erkannt.");
                break;
 
-       case "0.4.0": // SQL queries for v0.4.0
+       case '0.4.0': // SQL queries for v0.4.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Template-Problem beseitigt. Dies verhinderte das Abspeichern der Einstellungen.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index c606372984b93dad9313f48b08e414cf3500dd88..f4d376418795fb0bb72e257800c8f6a0536a80c5 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_bank_accounts`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_bank_accounts` (
@@ -154,7 +154,7 @@ UNIQUE (account_id, tan)
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES ('bank','bank_remove','Konto K&uuml;ndigen','N','Y', 7)");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_bank_accounts`");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_bank_transfers`");
@@ -164,20 +164,20 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `action`='bank'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `action`='bank' LIMIT 8");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `action`='bank' LIMIT 8");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("");
 
                // Update notes (these will be set as task text!)
@@ -186,10 +186,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 4373ea38f602f7f0f283fec47aff9d823358bbfb..b097f6a853fc3acb0890860115613d7d7105b6c5 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.2.6");
+EXT_SET_VERSION('0.2.6');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_beg','Bettel-Link','IP-Sperre, {!POINTS!}-Verg&uuml;tung usw. k&ouml;nnen Sie hier einstellen.', 10)");
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','beg','{!POINTS!} erbetteln!',4,'Y','Y')");
@@ -70,7 +70,7 @@ PRIMARY KEY(id)
 ) TYPE={!_TABLE_TYPE!}");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_beg' OR `what`='list_beg'");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_guest_menu` WHERE `what`='beg'");
@@ -78,80 +78,80 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_beg_ips`");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='Y', `locked`='N' WHERE `what`='beg' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='beg' LIMIT 1");
-       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', hidden='N', admin_only='N', mem_only='N' WHERE `module`='beg' LIMIT 1");
+       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', `hidden`='N', `admin_only`='N', `mem_only`='N' WHERE `module`='beg' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='N', `locked`='Y' WHERE `what`='beg' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE what IN('beg','beg2') LIMIT 2");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='Y' WHERE `module`='beg' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Design &quot;Solid-Business&quot; eingebaut.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD beg_points_max FLOAT(20,5) UNSIGNED NOT NULL DEFAULT '0.10000'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Maximale Obergrenze an {!POINTS!} einstellbar (Standart: 0,1 {!POINTS!})");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("&Uuml;berlange Kommastellen bei Punktangaben aus Bettellink und Gastbereich entfernt und Admin-Templates repariert (&quot;Unbekannte Spalte <u>beg_points_ma</u>&quot;).");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Im Mitgliedsmen&uuml; wurde die Beschreibung aus dem Gastmen&uuml; verwendet.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD beg_uid BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ein Mitgliedsaccount (empfehlenswert ist Ihr eigenes!) kann zum Abbuchen der {!POINTS!} verwendet werden. Template <u>admin_config_beg.tpl</u> (und pro!) nicht vergessen, zu aktualisieren.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD beg_ip_timeout BIGINT(20) UNSIGNED NOT NULL DEFAULT 1800");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Zeitsperre gegen die selbe IP-Nummer hinzugef&uuml;gt.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bitte verschieben Sie die beg-Templates (Ordner: {!PATH!}/templates/".GET_LANGUAGE()."/html/) in den neuen Order beg!");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Vorbereitung auf die neue Mediendaten v0.0.4.");
                break;
 
-       case "0.1.2":
+       case '0.1.2':
                // SQL queries for v0.1.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD beg_mode ENUM('DIRECT','REF') NOT NULL DEFAULT 'REF'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD beg_ranks TINYINT(3) UNSIGNED NOT NULL DEFAULT 10");
@@ -160,7 +160,7 @@ case "update": // Update an extension
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD beg_points FLOAT(21,5) UNSIGNED NOT NULL DEFAULT 0.00000");
 
                $VIS = "N"; $LOCKED = "Y";
-               if (EXT_IS_ACTIVE("beg")) { $VIS = "Y"; $LOCKED = "N"; }
+               if (EXT_IS_ACTIVE('beg')) { $VIS = "Y"; $LOCKED = "N"; }
 
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES ('main','beg2','Bettel-Rallye','".$VIS."','".$LOCKED."','7')");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('user','list_beg','Bettel-Rallye','Listet alle Teilnehmer der monatlichen Bettel-Rallye auf.','12')");
@@ -169,29 +169,29 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Optionale Bettel-Rallye m&ouml;glich. Und die erbettelten {!POINTS!} k&ouml;nnen entweder nur dem bettelndem Mitglied direkt oder auch seinem Werber gutgeschrieben werden k&ouml;nnen.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erbettelte {!POINTS!} werden nach Deaktivierung der Bettel-Rallye gel&ouml;scht.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Rechtlichen Hinweis im Mitgliedsbereich vergessen (<strong>member_list_beg.tpl</strong>); Template <strong>member_beg_404.tpl</strong> fehlte!");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `title`='Bettellink/-rallye', descr='IP-Sperre, {!POINTS!}-Verg&uuml;tung und auch die Bettel-Rallye k&ouml;nnen Sie hier einstellen.' WHERE `what`='config_beg' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlendes Template im Admin-Bereich hinzugef&uuml;gt. Im Admin-Bereich Hinweis hinzugef&uuml;gt, wenn Bettel-Rallye inaktiv ist. Bitte Script inc/monthly_beg.php l&ouml;schen!");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Es wurden immer dem ersten bettelndem Mitglied die {!POINTS!} gutgeschrieben.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD beg_ral_en_notify ENUM('Y','N') NOT NULL DEFAULT 'N'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD beg_ral_di_notify ENUM('Y','N') NOT NULL DEFAULT 'N'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD beg_new_mem_notify ENUM('Y','N') NOT NULL DEFAULT 'N'");
@@ -205,39 +205,39 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Die Mitglieder k&ouml;nnen nun optional automatisch &uuml;ber eine aktivierte und/oder deaktivierte Bettel-Rallye informiert werden. Beide Benachrichtigungen k&ouml;nnen Sie unter <strong>Einstellungen --&gt; Bettel-Link/-rallye</strong> seperat ein- und ausschalten! Zudem ist eine Sperre gegen eingeloggte Mitglieder eingebaut, die das Klicken auf den eigenen Bettel-Link etwas erschweren soll.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler im t&auml;glichen Reset beseitigt.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("De-/Aktivieren des mit dieser Erweiterung verkn&uuml;pften Modules eingebunden.");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bei {!POINTS!}-Gleichstand wird als n&auml;chstes nach wer als letztes Online war umsortiert.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler <strong>unknown column &#39;uid&#39;</strong> beseitigt.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD beg_include_own ENUM('Y','N') NOT NULL DEFAULT 'N'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Eigene User-ID von Bettel-Rallye ausschliessbar.");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abfrage des Account-Status eingebaut. Es k&ouml;nnen nur best&auml;tigte Accounts betteln.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `action`='extras', `sort`='1' WHERE `what`='beg' LIMIT 1");
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `action`='rals', `sort`='3', `title`='Bettel-Rallye' WHERE `what`='beg2' LIMIT 1");
 
@@ -245,12 +245,12 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Mitgliedsmen&uuml; komplett umgebaut.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_beg_ips` ADD sid VARCHAR(255) NOT NULL DEFAULT ''");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `beg_pay_mode` ENUM('IMG','JS','BOTH','NONE') DEFAULT 'NONE' NOT NULL ;");
 
@@ -260,10 +260,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
@@ -273,7 +273,7 @@ default: // Do stuff when extension is loaded
        $result_ext = SQL_QUERY("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_beg_ips` WHERE timeout < (UNIX_TIMESTAMP() -".($OLD + 60*60).")", __FILE__, __LINE__);
 
        // Check for beg rallye is active and send mails out
-       if ((getConfig('beg_rallye') == "Y") && (getConfig('beg_new_mem_notify') == "Y")) {
+       if ((getConfig('beg_rallye') == 'Y') && (getConfig('beg_new_mem_notify') == 'Y')) {
                // Include file for sending out mails
                ADD_INC_TO_POOL(sprintf("%sinc/mails/beg_mails.php", constant('PATH')));
        } // END - if
index dd9596dc8958d019c4a0a7a64872193117263952..7721f41919b986efe8d6d606ebb6b3737dc67102 100644 (file)
@@ -43,44 +43,44 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.3.9");
+EXT_SET_VERSION('0.3.9');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.1", "0.2", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9", "0.3.0", "0.3.1", "0.3.2", "0.3.3", "0.3.4", "0.3.5", "0.3.6", "0.3.7", "0.3.8", "0.3.9"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.1.0', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD birthday_sent VARCHAR(10) NOT NULL DEFAULT 0");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` DROP birthday_sent");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_birthday`");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_birthday'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.1": // SQL queries for v0.1
+       case '0.1.0': // SQL queries for v0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wenn t&auml;glicher Reset war, wird eine ben&ouml;tigte Include-Datei nicht mehr von daily-reset.php eingebunden, sondern von der Erweiterungsdatei selber.");
                break;
 
-       case "0.2": // SQL queries for v0.2
+       case '0.2.0': // SQL queries for v0.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD birthday_points BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_birthday`");
                ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_user_birthday` (
@@ -97,72 +97,72 @@ PRIMARY KEY(id)
                EXT_SET_UPDATE_NOTES("Es kann nun eine Gutschrift an die Geburtstagmail angeh&auml;ngt werden. Diese wird erst beim Klick auf einen Best&auml;tigungslink gutgeschrieben.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abstand zwischen ausgesendeter Geburtstagsmails auf 364 Tage erh&ouml;ht.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Laden der birthday_mails.php &quot;intelligenter&quot; per Datenfeld und Lade-Schleife in load_extensions.php realisiert.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate am Script <u>birtday_confirm.php</u> durchgef&uuml;hrt.");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Vergessenes <strong>_OB_CACHING</strong> gesetzt.");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.3.0": // SQL queries for v0.3.0
+       case '0.3.0': // SQL queries for v0.3.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ausgabe des generierten HTML-Codes nach <u>inc/footer.php</u> verlagert.");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wort <strong>Punkte</strong> dynamisiert.");
                break;
 
-       case "0.3.2": // SQL queries for v0.3.2
+       case '0.3.2': // SQL queries for v0.3.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate: SQL-Anweisungen gesch&uuml;tzt.");
                break;
 
-       case "0.3.3": // SQL queries for v0.3.3
+       case '0.3.3': // SQL queries for v0.3.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bitte verschieben Sie die birthday-Templates (Ordner: {!PATH!}/templates/".GET_LANGUAGE()."/html/) in den neuen Order birthday!");
                break;
 
-       case "0.3.4": // SQL queries for v0.3.4
+       case '0.3.4': // SQL queries for v0.3.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.3.5": // SQL queries for v0.3.5
+       case '0.3.5': // SQL queries for v0.3.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Vorbereitung auf die neue Mediendaten v0.0.4.");
                break;
 
-       case "0.3.6": // SQL queries for v0.3.6
+       case '0.3.6': // SQL queries for v0.3.6
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD birthday_mode ENUM('DIRECT','REF') NOT NULL DEFAULT 'DIRECT'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD birthday_active ENUM('Y','N') NOT NULL DEFAULT 'N'");
 
@@ -170,17 +170,17 @@ PRIMARY KEY(id)
                EXT_SET_UPDATE_NOTES("Verg&uuml;tungsmodus des Geburtstagsbonus einstellbar.");
                break;
 
-       case "0.3.7": // SQL queries for v0.3.7
+       case '0.3.7': // SQL queries for v0.3.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Im Script <strong>inc/birthday_mails.php</strong> hat sich ein Zeichen mit dem Code 160 eingeschlichen, welches einen <strong>Parser Error</strong> verursachte, aber wie eine gew&ouml;hnliche Leerstelle aussah.");
                break;
 
-       case "0.3.8": // SQL queries for v0.3.8
+       case '0.3.8': // SQL queries for v0.3.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Hash-Erstellung von <strong>md5()</strong> auf bessere Funktion <strong>generateHash()</strong> umgestellt.");
                break;
 
-       case "0.3.9": // SQL queries for v0.3.9
+       case '0.3.9': // SQL queries for v0.3.9
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` CHANGE `birth_day` `birth_day` SMALLINT(2) UNSIGNED ZEROFILL NOT NULL DEFAULT '01',
 CHANGE `birth_month` `birth_month` SMALLINT(2) UNSIGNED ZEROFILL NOT NULL DEFAULT '01',
 CHANGE `birth_year` `birth_year` SMALLINT(4) UNSIGNED ZEROFILL NOT NULL DEFAULT 1970");
@@ -191,10 +191,10 @@ CHANGE `birth_year` `birth_year` SMALLINT(4) UNSIGNED ZEROFILL NOT NULL DEFAULT
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index c57a708353aa9fd7e5db5bc895d81ff8c711e8ab..5cd5fa82a44dedcbf5087c1d195435d956b4a44d 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version of this extension
-EXT_SET_VERSION("0.8.8");
+EXT_SET_VERSION('0.8.8');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.1.6", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9", "0.3.0", "0.3.1", "0.3.2", "0.3.3", "0.3.4", "0.3.5", "0.3.6", "0.3.7", "0.3.8", "0.3.9", "0.4.0", "0.4.1", "0.4.2", "0.4.3", "0.4.4", "0.4.5", "0.4.6", "0.4.7", "0.4.8", "0.4.9", "0.5.0", "0.5.1", "0.5.2", "0.5.3", "0.5.4", "0.5.5", "0.5.6", "0.5.7", "0.5.8", "0.5.9", "0.6.0", "0.6.1", "0.6.2", "0.6.3", "0.6.4", "0.6.5", "0.6.6", "0.6.7", "0.6.8", "0.6.9", "0.7.0", "0.7.1", "0.7.2", "0.7.3", "0.7.4", "0.7.5", "0.7.6", "0.7.7", "0.7.8", "0.7.9", "0.8.0", "0.8.1", "0.8.2", "0.8.3", "0.8.4", "0.8.5", "0.8.6", "0.8.7", "0.8.8"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.1.6', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9', '0.4.0', '0.4.1', '0.4.2', '0.4.3', '0.4.4', '0.4.5', '0.4.6', '0.4.7', '0.4.8', '0.4.9', '0.5.0', '0.5.1', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6', '0.5.7', '0.5.8', '0.5.9', '0.6.0', '0.6.1', '0.6.2', '0.6.3', '0.6.4', '0.6.5', '0.6.6', '0.6.7', '0.6.8', '0.6.9', '0.7.0', '0.7.1', '0.7.2', '0.7.3', '0.7.4', '0.7.5', '0.7.6', '0.7.7', '0.7.8', '0.7.9', '0.8.0', '0.8.1', '0.8.2', '0.8.3', '0.8.4', '0.8.5', '0.8.6', '0.8.7', '0.8.8'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`sort`,`descr`) VALUES ('email','send_bonus','Bonusmail senden',5,'Versenden Sie hier Bonus-Mails an alle Mitglieder oder nur an alle aus einer Kategorie. Es spielt keine Rolle, wie viele Mails bereits versendet worden, Sie k&ouml;nnen hier immer senden.')");
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`,`counter`) VALUES ('main','bonus','Bonuspunkte',7,'Y','Y', 0)");
@@ -77,10 +77,10 @@ PRIMARY KEY  (id)
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_links` ADD INDEX (bonus_id)");
 
        // Run this SQL when html or html_mail extension is installed
-       if (EXT_IS_ACTIVE("html_mail")) ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_bonus` add html_msg ENUM('Y','N') NOT NULL DEFAULT 'N'");
+       if (EXT_IS_ACTIVE('html_mail')) ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_bonus` add html_msg ENUM('Y','N') NOT NULL DEFAULT 'N'");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE what IN ('bonus','config_bonus','send_bonus','list_bonus','list_notifications')");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='bonus'");
@@ -93,36 +93,36 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_bonus_turbo`");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='bonus' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='Y', `locked`='N' WHERE `action`='bonus' LIMIT 1");
-       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', hidden='N', admin_only='N', mem_only='N' WHERE `module`='show_bonus' LIMIT 1");
+       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', `hidden`='N', `admin_only`='N', `mem_only`='N' WHERE `module`='show_bonus' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='bonus' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='N', `locked`='Y' WHERE `action`='bonus' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='Y' WHERE `module`='show_bonus' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Paid-Links wurden verschoben in die Erweiterung <strong>paidlinks</strong>.");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_bonus` SET target_send=mails_sent WHERE target_send='0' AND mails_sent>0 AND receivers != ''");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Behebt ein Versand-Problem mit den Bonus-Mails. Es wurde die Spalte target_send nicht beim Einf&uuml;gen der Buchung gessetzt. Bitte laden Sie sich dazu - wenn nicht bereits geschehen - alle Patches bis mindestens Patch 240 unter <a href=\"{!URL!}/modules.php?module=admin&amp;what=updates\">Updates pr&uuml;fen</a> herunter.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_bonus' LIMIT 1");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`sort`,`descr`) VALUES ('setup','config_bonus','Bonus-{!POINTS!}',8,'Richten Sie Bonus-{!POINTS!} ein, die beim x&#39;ten Klick auf die Mail verbucht werden sollen. Beispiele: Der 1. Klick sollte mehr {!POINTS!} zus&auml;tzlich bekommen, als der 10. Klick.')");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD login_bonus FLOAT(20,3) NOT NULL DEFAULT 10.000");
@@ -139,7 +139,7 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Login-Bonus und Turbo-Klick-Bonus intergriert.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_bonus_turbo`");
                ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_bonus_turbo` (
 id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT,
@@ -159,7 +159,7 @@ KEY userid (userid)
                EXT_SET_UPDATE_NOTES("Turbo-Bonus wird in Tabelle gez&auml;hlt f&uuml;r Anzeige, wer alles bereits geklickt hat und welchen Platz er gemacht hat.");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='bonus' LIMIT 1");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`,`counter`) VALUES ('main','bonus','Aktiv-Rallye',7,'Y','Y', 0)");
 
@@ -167,12 +167,12 @@ KEY userid (userid)
                EXT_SET_UPDATE_NOTES("Aktiv-Rallye mit Klick-Verg&uuml;tung hinzugef&uuml;gt.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wegen des Theme-Supportes hat sich die URL zur CSS-Datei ge&auml;ndert.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_bonus_urls`");
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_bonus_customer`");
 
@@ -180,17 +180,17 @@ KEY userid (userid)
                EXT_SET_UPDATE_NOTES("Tabellen <u>{!MYSQL_PREFIX!}_bonus_urls</u> und <u>{!MYSQL_PREFIX!}_bonus_customer</u> entfernt, da dies bald von der Erweiterung <u>paidlinks</u> erledigt wird.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Turbo-Bonus klappt wieder (dies sind {!POINTS!} die an die schnellsten Klicker verg&uuml;tet werden!)");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_bonus` SET timestamp='0' WHERE timestamp='0000000000'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_bonus_turbo` CHANGE points points FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 0.00000");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` CHANGE turbo_bonus turbo_bonus FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 0.00000");
@@ -202,39 +202,39 @@ KEY userid (userid)
                EXT_SET_UPDATE_NOTES("5 Nachkommastellen implementiert");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.3.0": // SQL queries for v0.3.0
+       case '0.3.0': // SQL queries for v0.3.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate am Script <u>show_bonus.php</u> durchgef&uuml;hrt.");
                break;
 
-       case "0.3.2": // SQL queries for v0.3.2
+       case '0.3.2': // SQL queries for v0.3.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Design &quot;Solid-Business&quot; eingebaut.");
                break;
 
-       case "0.3.3": // SQL queries for v0.3.3
+       case '0.3.3': // SQL queries for v0.3.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.3.4": // SQL queries for v0.3.4
+       case '0.3.4': // SQL queries for v0.3.4
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('user','list_bonus','Aktiv-Rallye-Teilnehmer','Listet alle Mitglieder auf, die einen Aktiv-Bonus haben und zeigt die derzeit m&ouml;glichen Gewinner an.', 10)");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link <u>Aktiv-Rallye-Teilnehmer</u> hinzugef&uuml;gt, inklusive manuelle Vorbereitung der Verg&uuml;tung.");
                break;
 
-       case "0.3.5": // SQL queries for v0.3.5
+       case '0.3.5': // SQL queries for v0.3.5
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_mode ENUM('UID','JACKPOT','ADD') NOT NULL DEFAULT 'ADD'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_uid BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
 
@@ -242,27 +242,27 @@ KEY userid (userid)
                EXT_SET_UPDATE_NOTES("Der Login-Bonus Aktiv-Bonus (= Klick-Bonus) k&ouml;nnen nun zuerst von einem Mitgliederaccount (das sollte Ihres sein!), vom Jackpot abgezogen oder einfach dazuadiert werden.");
                break;
 
-       case "0.3.6": // SQL queries for v0.3.6
+       case '0.3.6': // SQL queries for v0.3.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("In der Admin-Liste werden nur aktive Mitglieder gelistet und zudem die sp&auml;teste Zeitmarke f&uuml;r die Auswertung angezeigt.");
                break;
 
-       case "0.3.7": // SQL queries for v0.3.7
+       case '0.3.7': // SQL queries for v0.3.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mitglieder-Account auw&auml;hlbar, von dem die {!POINTS!} f&uuml;r den Aktiv- und Login-Bonus abgebucht werden.");
                break;
 
-       case "0.3.8": // SQL queries for v0.3.8
+       case '0.3.8': // SQL queries for v0.3.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ausgabe des generierten HTML-Codes nach <u>inc/footer.php</u> verlagert.");
                break;
 
-       case "0.3.9": // SQL queries for v0.3.9
+       case '0.3.9': // SQL queries for v0.3.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlende Variablen gefixt.");
                break;
 
-       case "0.4.0": // SQL queries for v0.4.0
+       case '0.4.0': // SQL queries for v0.4.0
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_timeout BIGINT(20) UNSIGNED NOT NULL DEFAULT ".(getConfig('one_day')*7)."");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_lines BIGINT(20) UNSIGNED NOT NULL DEFAULT 10");
 
@@ -270,22 +270,22 @@ KEY userid (userid)
                EXT_SET_UPDATE_NOTES("Automatisches L&ouml;schen von Turbo-Bonus-Zeilen ({!MYSQL_PREFIX!}_bonus_turbo) und begrenzte Anzahl von Eintr&auml;gen hinzugef&uuml;gt.");
                break;
 
-       case "0.4.1": // SQL queries for v0.4.1
+       case '0.4.1': // SQL queries for v0.4.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Verg&uuml;tung des Aktiv-Bonus repariert.");
                break;
 
-       case "0.4.2": // SQL queries for v0.4.2
+       case '0.4.2': // SQL queries for v0.4.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Admin-Bereich / Aktiv-Teilnehmer auflisten: Problem mit Konstante __AUTOPURGE_TIMEOUT und das Template <u>admin_list_bonus.tpl</u> korregiert.");
                break;
 
-       case "0.4.3": // SQL queries for v0.4.3
+       case '0.4.3': // SQL queries for v0.4.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Verbesserung des Versandes von  HTML-Bonus-Mails.");
                break;
 
-       case "0.4.4": // SQL queries for v0.4.4
+       case '0.4.4': // SQL queries for v0.4.4
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_order FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 15.00000");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_ref FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 100.00000");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_stats FLOAT(20,5) UNSIGNED NOT NULL DEFAULT '5.00000'");
@@ -298,64 +298,64 @@ KEY userid (userid)
                EXT_SET_UPDATE_NOTES("Bonus-{!POINTS!} f&uuml;r: Mailbestellung, Referal-Werbung (bei Best. der EMail-Adresse) und wenn 100% Klickrate jeder Mailbuchung erreicht wurde.<br />Template <u>admin_config_bonus_pro.tpl</u> ist &uuml;berfl&uuml;ssig geworden. Bitte l&ouml;schen Sie dies!<br />Eingestellte Bonus-{!POINTS!} f&uuml;r Rank 2 war um eins verschoben.");
                break;
 
-       case "0.4.5": // SQL queries for v0.4.5
+       case '0.4.5': // SQL queries for v0.4.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abzug vom Bonus-Account integriert.");
                break;
 
-       case "0.4.6": // SQL queries for v0.4.6
+       case '0.4.6': // SQL queries for v0.4.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Rank 2 bekommt nun auch seine {!POINTS!} gutgeschrieben.");
                break;
 
-       case "0.4.7": // SQL queries for v0.4.7
+       case '0.4.7': // SQL queries for v0.4.7
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET login_bonus=0, turbo_bonus=0,bonus_ref=0,bonus_order=0,bonus_stats=0");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Die Aktiv-Rallye wurde nicht auf 0 {!POINTS!} gesetzt. Dieser Fehler ist nun behoben. Allerdings ist mit diesem Update auch die Aktiv-Rallye zur&uuml;ckgesetzt worden.");
                break;
 
-       case "0.4.8": // SQL queries for v0.4.8
+       case '0.4.8': // SQL queries for v0.4.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("In <u>inc/monthly_bonus.php</u> fehlte ein Punkt; Fehler besseitigt.");
                break;
 
-       case "0.4.9": // SQL queries for v0.4.9
+       case '0.4.9': // SQL queries for v0.4.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Login-Bonus wird mit angezeigt.");
                break;
 
-       case "0.5.0": // SQL queries for v0.5.0
+       case '0.5.0': // SQL queries for v0.5.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit <strong>is_hundred</strong> beim t&auml;glichen Reset beseitigt.");
                break;
 
-       case "0.5.1": // SQL queries for v0.5.1
+       case '0.5.1': // SQL queries for v0.5.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit <strong>bonus_stats / Zeile 31</strong> beim t&auml;glichen Reset beseitigt.");
                break;
 
-       case "0.5.2": // SQL queries for v0.5.2
+       case '0.5.2': // SQL queries for v0.5.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.5.3": // SQL queries for v0.5.3
+       case '0.5.3': // SQL queries for v0.5.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Speichern der Aktiv-{!POINTS!} f&uuml;r Platz 2 bis <strong>x</strong> korregiert.");
                break;
 
-       case "0.5.4": // SQL queries for v0.5.4
+       case '0.5.4': // SQL queries for v0.5.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Variablenfehler in <strong>inc/monthly_bonus.php</strong> behoben.");
                break;
 
-       case "0.5.5": // SQL queries for v0.5.5
+       case '0.5.5': // SQL queries for v0.5.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Weitere Variablenfehler in <strong>inc/monthly_bonus.php</strong> haben daf&uuml;r gesorgt, dass die monatliche Aktiv-Rallye nicht ausgesch&uuml;ttet wurde. Mit diesem Update wurde die Aussch&uuml;ttung initialisiert. Ihre Mitglieder bekommen voraussichtlicht nichts doppelt verg&uuml;tet.");
                break;
 
-       case "0.5.6": // SQL queries for v0.5.6
+       case '0.5.6': // SQL queries for v0.5.6
                // Get current month
                $curr = date("m", time());
                if (strlen($curr) == 1) $curr = "0".$curr;
@@ -373,64 +373,64 @@ WHERE last_online < ".$mark." ORDER BY userid");
                EXT_SET_UPDATE_NOTES("Ein weiterer Scriptfehler hat nur die Gewinner aus der Aktiv-Rallye genommen. Die anderen Mitglieder sind somit &quot;nach oben gerutsch&quot;.");
                break;
 
-       case "0.5.7": // SQL queries for v0.5.7
+       case '0.5.7': // SQL queries for v0.5.7
                break;
 
-       case "0.5.8": // SQL queries for v0.5.8
+       case '0.5.8': // SQL queries for v0.5.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit <strong>is_hundred</strong> beim t&auml;glichen Reset endlich beseitigt.");
                break;
 
-       case "0.5.9": // SQL queries for v0.5.9
+       case '0.5.9': // SQL queries for v0.5.9
                EXT_SET_UPDATE_NOTES("Fehlermeldung <strong>/home/verzeichnis/html/inc/stats_bonus.php (42):You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near '' WHERE userid='59' LIMIT 1' at line 1</strong> beseitigt.");
                break;
 
-       case "0.6.0": // SQL queries for v0.6.0
+       case '0.6.0': // SQL queries for v0.6.0
                EXT_SET_UPDATE_NOTES("SQL-Fehlermeldung in <strong>inc/monthly_bonus.php</strong> beseitigt.");
                break;
 
-       case "0.6.1": // SQL queries for v0.6.1
+       case '0.6.1': // SQL queries for v0.6.1
                EXT_SET_UPDATE_NOTES("Versand von Bonus-Mails repariert.");
                break;
 
-       case "0.6.2": // SQL queries for v0.6.2
+       case '0.6.2': // SQL queries for v0.6.2
                EXT_SET_UPDATE_NOTES("L&ouml;schen von bereits gel&ouml;schten Mails wird nun abgelehnt.");
                break;
 
-       case "0.6.3": // SQL queries for v0.6.3
+       case '0.6.3': // SQL queries for v0.6.3
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.6.4": // SQL queries for v0.6.4
+       case '0.6.4': // SQL queries for v0.6.4
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `title`='Aktiv-Rallye' WHERE `what`='config_bonus' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Der Men&uuml;punkt &quot;Bonus-{!POINTS!}&quot; unter Einstellungen wird nach &quot;Aktiv-Rallye umbenannt. Und die Aktiv-Rallye konnte aufgrund eines Template-Fehlers nicht gespeichert werden.");
                break;
 
-       case "0.6.5": // SQL queries for v0.6.5
+       case '0.6.5': // SQL queries for v0.6.5
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_stats` ADD bonus_stats ENUM('Y','N') NOT NULL DEFAULT 'N'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler mit bonus_stats beseitigt.");
                break;
 
-       case "0.6.6": // SQL queries for v0.6.6
+       case '0.6.6': // SQL queries for v0.6.6
                EXT_SET_UPDATE_NOTES("Template-Fehler beseitigt im Admin-Bereich.");
                break;
 
-       case "0.6.7": // SQL queries for v0.6.7
+       case '0.6.7': // SQL queries for v0.6.7
                EXT_SET_UPDATE_NOTES("Vorbereitung auf die neue Mediendaten v0.0.4.");
                break;
 
-       case "0.6.8": // SQL queries for v0.6.8
+       case '0.6.8': // SQL queries for v0.6.8
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_bonus` SET data_type='SEND' WHERE data_type != 'SEND' AND data_type != 'DELETED' AND receivers='' AND target_send='0'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Eingegebene Anzahl auszusendener Bonus-Mails wurde bei der Empf&auml;nderauswahl nicht ber&uuml;cksichtigt. Zudem wird jetzt das eingestellte Auswahlverfahren mitber&uuml;cksichtigt.");
                break;
 
-       case "0.6.9": // SQL queries for v0.6.9
+       case '0.6.9': // SQL queries for v0.6.9
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_order_yn ENUM('Y','N') NOT NULL DEFAULT 'N'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_ref_yn ENUM('Y','N') NOT NULL DEFAULT 'N'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_stats_yn ENUM('Y','N') NOT NULL DEFAULT 'N'");
@@ -441,35 +441,35 @@ WHERE last_online < ".$mark." ORDER BY userid");
                EXT_SET_UPDATE_NOTES("Es k&ouml;nnen nun auch die folgenden Verg&uuml;tungen bei der Auswertung der monatlichen Aktiv-Rallye mit ber&uuml;cksichtigt werden: Mailbest&auml;tigung (war vorher schon), Login-, Mailbuchung, Referal und Statistik-Bonus (100% Klickrate erreicht).");
                break;
 
-       case "0.7.0": // SQL queries for v0.7.0
+       case '0.7.0': // SQL queries for v0.7.0
                EXT_SET_UPDATE_NOTES("Zuschaltung von weiteren Bonis wird jetzt auch bei der Auflistung der mitmachenden Mitglieder im Mitgliedsbereich beachtet.");
                break;
 
-       case "0.7.1": // SQL queries for v0.7.1
+       case '0.7.1': // SQL queries for v0.7.1
                EXT_SET_UPDATE_NOTES("Im Adminbereich wird nun ebenfalls die Zuschaltung von weiteren Bonis ber&uuml;cksichtigt. Zudem wird der Gesamtbonus an alle Mitglieder errechnet und auch angezeigt.");
                break;
 
-       case "0.7.2": // SQL queries for v0.7.2
+       case '0.7.2': // SQL queries for v0.7.2
                EXT_SET_UPDATE_NOTES("Die Verg&uuml;tung der erreichten 100%-Klickrate war noch wegen Programmierungen am Script auskommentiert. Sorry!");
                break;
 
-       case "0.7.3": // SQL queries for v0.7.3
+       case '0.7.3': // SQL queries for v0.7.3
                EXT_SET_UPDATE_NOTES("Gutgeschriebene Bonus-{!POINTS!} werden nach Deaktivierung der Aktiv-Rallye gel&ouml;scht.");
                break;
 
-       case "0.7.4": // SQL queries for v0.7.4
+       case '0.7.4': // SQL queries for v0.7.4
                EXT_SET_UPDATE_NOTES("Rechtlichen Hinweis im Mitgliedsbereich vergessen. (<strong>member_bonus.tpl</strong>)");
                break;
 
-       case "0.7.5": // SQL queries for v0.7.5
+       case '0.7.5': // SQL queries for v0.7.5
                EXT_SET_UPDATE_NOTES("Im Admin-Bereich Hinweis hinzugef&uuml;gt, wenn Aktiv-Rallye inaktiv ist. Bitte Script inc/monthly_bonus.php l&ouml;schen!");
                break;
 
-       case "0.7.6": // SQL queries for v0.7.6
+       case '0.7.6': // SQL queries for v0.7.6
                EXT_SET_UPDATE_NOTES("Auswahlmechanismus der Gewinner repariert. Trotz Hinzuschalten von weiteren zu ber&uuml;cksichtigen Boni wurden diese bei der Sortierung der User-IDs nicht ber&uuml;cksichtig.");
                break;
 
-       case "0.7.7": // SQL queries for v0.7.7
+       case '0.7.7': // SQL queries for v0.7.7
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_en_notify ENUM('Y','N') NOT NULL DEFAULT 'N'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_di_notify ENUM('Y','N') NOT NULL DEFAULT 'N'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_new_mem_notify ENUM('Y','N') NOT NULL DEFAULT 'N'");
@@ -483,24 +483,24 @@ WHERE last_online < ".$mark." ORDER BY userid");
                EXT_SET_UPDATE_NOTES("Optionale automatische Benachrichtigung &uuml;ber aktivierte und/oder deaktivierte Aktiv-Rallye einstellbar.");
                break;
 
-       case "0.7.8": // SQL queries for v0.7.8
+       case '0.7.8': // SQL queries for v0.7.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler im t&auml;glichen Reset beseitigt.");
                break;
 
-       case "0.7.9": // SQL queries for v0.7.9
+       case '0.7.9': // SQL queries for v0.7.9
                EXT_SET_UPDATE_NOTES("Dollarzeichen fehlte in <strong>inc/reset/reset_bonus.php</strong>, Zeile 39");
                break;
 
-       case "0.8.0": // SQL queries for v0.8.0
+       case '0.8.0': // SQL queries for v0.8.0
                EXT_SET_UPDATE_NOTES("De-/Aktivieren des mit dieser Erweiterung verkn&uuml;pften Modules eingebunden.");
                break;
 
-       case "0.8.1": // SQL queries for v0.8.1
+       case '0.8.1': // SQL queries for v0.8.1
                EXT_SET_UPDATE_NOTES("Bei {!POINTS!}-Gleichstand wird als n&auml;chstes nach wer als letztes Online war umsortiert.");
                break;
 
-       case "0.8.2": // SQL queries for v0.8.2
+       case '0.8.2': // SQL queries for v0.8.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD bonus_include_own ENUM('Y','N') NOT NULL DEFAULT 'N'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_bonus` ADD is_notify ENUM('Y','N') NOT NULL DEFAULT 'N'");
 
@@ -508,33 +508,33 @@ WHERE last_online < ".$mark." ORDER BY userid");
                EXT_SET_UPDATE_NOTES("Eigene User-ID von Aktiv-Rallye ausschliessbar. Benachrichtigungsmails sind von Aktiv-Rallye ausgeschlossen.");
                break;
 
-       case "0.8.3": // SQL queries for v0.8.3
+       case '0.8.3': // SQL queries for v0.8.3
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `action`='rals', `sort`='2', `title`='Aktiv-Rallye' WHERE `what`='bonus' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mitgliedsmen&uuml; komplett umgebaut.");
                break;
 
-       case "0.8.4": // SQL queries for v0.8.4
+       case '0.8.4': // SQL queries for v0.8.4
                EXT_SET_UPDATE_NOTES("Ladeproblem bei nicht installierter Erweiterung <strong>cache</strong> gefixt.");
                break;
 
-       case "0.8.5": // SQL queries for v0.8.5
+       case '0.8.5': // SQL queries for v0.8.5
                EXT_SET_UPDATE_NOTES("CSS-Klassenname gefixt in Templates.");
                break;
 
-       case "0.8.6": // SQL queries for v0.8.6
+       case '0.8.6': // SQL queries for v0.8.6
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
 
-       case "0.8.7": // SQL queries for v0.8.7
+       case '0.8.7': // SQL queries for v0.8.7
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','list_notifications','Benachrichtigungen','Listet alle an die Mitglieder ausgesandten Benachrichtigungen auf.', 10)");
 
                // Update notes
                EXT_SET_UPDATE_NOTES("Benachrichtigungsmails f&uuml;r z.B. Bettel- oder Aktiv-Rallye werden nun angezeigt.");
                break;
 
-       case "0.8.8": // SQL queries for v0.8.8
+       case '0.8.8': // SQL queries for v0.8.8
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_stats` ADD bonus_stats_active ENUM('Y','N') NOT NULL DEFAULT 'N'");
 
                // Update notes
@@ -543,16 +543,16 @@ WHERE last_online < ".$mark." ORDER BY userid");
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
        if (isResetModeEnabled() && (!isDebugModeEnabled()) && ($GLOBALS['output_mode'] != 1)) {
                // Daily reset was run so let's check if active rallye is activated
-               if (getConfig('bonus_active') == "Y") {
+               if (getConfig('bonus_active') == 'Y') {
                        // Run active rallye
                        if (getConfig('bonus_stats') > 0) ADD_INC_TO_POOL(sprintf("%sinc/stats_bonus.php", constant('PATH')));
                        ADD_INC_TO_POOL(sprintf("%sinc/monthly/monthly_bonus.php", constant('PATH')));
@@ -563,7 +563,7 @@ default: // Do stuff when extension is loaded
        }
 
        // Check for bonus rallye is active and send mails out
-       if ((getConfig('bonus_active') == "Y") && (getConfig('bonus_new_mem_notify') == "Y")) {
+       if ((getConfig('bonus_active') == 'Y') && (getConfig('bonus_new_mem_notify') == 'Y')) {
                // Include file for sending out mails
                ADD_INC_TO_POOL(sprintf("%sinc/mails/bonus_mails.php", constant('PATH')));
        }
index 3a3038cfdc4c830463b03cab992815776a8c3770..e2b29f7516161535558392c4962686d3cbbeff56 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // Configuration entries
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `booking_per_page` TINYINT(3) UNSIGNED NOT NULL DEFAULT 10");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `booking_purge` BIGINT(20) UNSIGNED NOT NULL DEFAULT ".(getConfig('one_day') * 3)."");
@@ -75,29 +75,26 @@ PRIMARY KEY(`id`)
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','booking','{!POINTS!}-Kontoauszug',5,'Y','Y')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_book`");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what` IN ('config_booking','list_booking')");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='booking'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='booking' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='booking' LIMIT 1");
        break;
 
-case "modify": // When the extension got modified
-       break;
-
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("");
 
                // Update notes (these will be set as task text!)
@@ -105,7 +102,10 @@ case "update": // Update an extension
                break;
        }
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'modify': // When the extension got modified
+       break;
+
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index a75cccdd8ba34d05e87e8a54fa098b860a90e08c..18a8814f7119c870c31b57212dc09e238dc679c7 100644 (file)
@@ -44,14 +44,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.2.2");
+EXT_SET_VERSION('0.2.2');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD cache_update BIGINT(20) UNSIGNED NOT NULL DEFAULT 3600");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD cache_path VARCHAR(255) NOT NULL DEFAULT 'cache/'");
@@ -59,7 +59,7 @@ case "register": // Do stuff when installation is running (modules.php?module=ad
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_cache','Cache-Einstellungen','Update-Interval des Caches usw. k&ouml;nnen Sie hier &auml;ndern.', 9)");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what` IN('config_cache','cache_stats')");
 
@@ -76,37 +76,37 @@ case "remove": // Do stuff when removing extension
        UNREGISTER_FILTER('extension_remove', 'CACHE_DESTROY_ALL', true, $dry_run);
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Es wurde die Zeitmarke der Cache-Datei extensions.cache mit ber&uuml;cksichtigt. Dies hatte die Folge, dass wenn bei einem Gast die Datei aktualisiert wurde, nur aktivierte und nicht die deaktivierten mit geladen wurden. Folglich fiehlen einfach ein paar Erweiterungen aus.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Cache-Update repariert.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Is the cache extension itself there?
-               if (EXT_IS_ACTIVE("cache")) {
+               if (EXT_IS_ACTIVE('cache')) {
                        // Check for cache when extension is already installed
                        if ($GLOBALS['cache_instance']->loadCacheFile("extensions", true)) $GLOBALS['cache_instance']->destroyCacheFile();
                } // END - if
@@ -115,17 +115,17 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Spalte &quot;keep_active&quot; ist hinzugef&uuml;gt. Cache wurde reinitialisiert.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Registrierung der Cache-Erweiterung repariert");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Validierung der Cache-Datei admins.cache integriert.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD db_hits BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD cache_hits BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('stats','cache_stats','DB-Cache','Auf Cache und gesamte Datenbank registrierte Anfragen anzeigen.', 4)");
@@ -134,32 +134,32 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Hits auf den Cache werden gez&auml;hlt.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Das Umschreiben der Cache-Daten hat eine Fehlermeldung <strong>Falsches Passwort!</strong> im Admin-Bereich verursacht.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Interne Datenfeld-Management korregiert und Cache-Statistiken korregiert.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit fehlender admins-Erweiterung beseitigt.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler <strong>Division durch 0</strong> repariert in den DB-Cache Statistiken.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Die Tabelen <strong>{!_MYSQL_PREFIX!}_config</strong>, <strong>{!_MYSQL_PREFIX!}_refsystem</strong>, <strong>{!_MYSQL_PREFIX!}_refdepths</strong> und <strong>{!_MYSQL_PREFIX!}_mod_reg</strong> werden nun auch ausgelagert.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD cache_admins ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD cache_acls ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD cache_exts ENUM('Y','N') NOT NULL DEFAULT 'Y'");
@@ -172,49 +172,49 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Alle cache-baren Tabellen sind nun einzelnt ein- bzw. ausschaltbar. Falls die eine oder andere ausgelagerte Tabelle also Fehler verursachen sollte, so k&ouml;nnen Sie diese hier abschalten. Beachten Sie aber bitte, dass dann mehr Abfragen an die Datenbank gestellt wird und dies bedeutend mehr Zeit braucht, als nur die Daten aus einem Datenfeld zu laden, das sich im Speicher aufh&auml;lt.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler <strong>Division durch 0</strong> repariert in <strong>inc/load_cache.php</strong>.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Weitere Fehler im System beseitigt.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Probleme w&auml;hrend des Installationsvorganges beseitigt.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("CSS-Klassenname gefixt in Templates.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD cache_themes ENUM('Y','N') NOT NULL DEFAULT 'Y'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Daten von installierten Themes werden nun gecacht.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD cache_admin_menu ENUM('Y','N') NOT NULL DEFAULT 'N'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Administratormen&uuml; experimentell gecacht.");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                // This update depends on sql_patches
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Die Erweiterung h&auml;ngt nun von der <strong>sql_patches</strong> ab.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                // Register the new filter
                REGISTER_FILTER('extension_update', 'CACHE_DESTROY_ON_EXT_CHANGE', false, true, $dry_run);
                REGISTER_FILTER('post_extension_installed', 'CACHE_DESTROY_ON_EXT_CHANGE', false, true, $dry_run);
@@ -229,7 +229,7 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Filter f&uuml;r Erweiterungsmanagement hinzugef&uuml;gt.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                // Register the new filter
                REGISTER_FILTER('post_extension_installed', 'CACHE_PURGE_ADMIN_MENU', false, true, $dry_run);
                REGISTER_FILTER('post_extension_run_sql', 'CACHE_PURGE_ADMIN_MENU', false, true, $dry_run);
@@ -240,10 +240,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 2fc6bc23dd531686cb03d782086eb65cb16a2f1a..447916f77b48344b1adfa57ad813aad4cbeb8120 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.4");
+EXT_SET_VERSION('0.0.4');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_countries`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_countries` (
@@ -71,51 +71,51 @@ PRIMARY KEY(id)
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD country_code BIGINT(20) UNSIGNED NOT NULL DEFAULT 1");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_countries`");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `action`='country'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("SQL-Dateien hinzugef&uuml;gt, die Sie mit z.B. phpMyAdmin einspielen k&ouml;nnen. (DOCS/country/README.de lesen!)");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate: SQL-Anweisungen gesch&uuml;tzt.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 85c7ee3b77075b5e3d37911d1533a2696463a4da..0fa72bdff88adcd6f00abdecc4f89b2e7ec66a2a 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // Table for debug log entries
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_debug_log`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_debug_log` (
@@ -135,7 +135,7 @@ PRIMARY KEY (`id`)
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `debug_master_url` VARCHAR(255) NOT NULL DEFAULT '{!SERVER_URL!}'");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_debug_client_log`");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_debug_client`");
@@ -145,20 +145,20 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `action`='debug'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='Y',`locked`='N' WHERE `action`='debug' LIMIT 5");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `locked`='Y' WHERE `action`='debug' LIMIT 5");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("");
 
                // Update notes (these will be set as task text!)
@@ -167,10 +167,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index bab0551a392856c93dba515f5837d00b2f6c1921..9d97f2218102991869b6e0e6315cfd38b854f6c7 100644 (file)
@@ -43,47 +43,47 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.1");
+EXT_SET_VERSION('0.0.1');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 9b7e64b0a8ac045b3d745b27bf5aa9a7bd42f699..5c2bc7b65367855685754ac537451f1676447fcf 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.1.6");
+EXT_SET_VERSION('0.1.6');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // Doubler table
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_doubler`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_doubler` (
@@ -117,7 +117,7 @@ PRIMARY KEY(id)
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES ('main','doubler','Verdoppeln!','Y','Y',7)");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_doubler`");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `action`='doubler'");
@@ -125,29 +125,29 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='doubler'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='doubler' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='Y', `locked`='N' WHERE `what`='doubler' LIMIT 1");
-       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', hidden='N', admin_only='N', mem_only='N' WHERE `module`='doubler' LIMIT 1");
+       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', `hidden`='N', `admin_only`='N', `mem_only`='N' WHERE `module`='doubler' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='doubler' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='N', `locked`='Y' WHERE `what`='doubler' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='Y' WHERE `module`='doubler' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit User-ID behoben!");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Total used points
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD doubler_used FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 0.00000");
 
@@ -155,12 +155,12 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Geb&uuml;hr wird vom Verdoppler-Pott abgezogen.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Drei SQL-Fehler beseitigt.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Shall I use the doubler's account to take points from? (Y/N, default=Y)
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD doubler_own ENUM('Y','N') NOT NULL DEFAULT 'Y'");
 
@@ -168,12 +168,12 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES(POINTS."-Guthaben des Verdopplers kann optional nicht mit einbezogen werden.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Counter-Stand und noch zum Verdoppeln &uuml;brige {!POINTS!} in Templates eingebunden. Auflistung in Admin-Bereich komplettiert.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD doubler_max_sent TINYINT(3) UNSIGNED NOT NULL DEFAULT 1");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD doubler_group_sent TINYINT(3) UNSIGNED NOT NULL DEFAULT 1");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD doubler_sent_all ENUM('Y','N') NOT NULL DEFAULT 'Y'");
@@ -182,64 +182,64 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Geb&uuml;hrenabzug wird beim Einzahlen abgezogen (wurde von Auszahlung abgezogen) und maximal bei Auszahlung zu kontrollierende Accounts einstellbar.<br />Template <u>admin_config_doubler_pro.tpl</u> ist &uuml;berfl&uuml;ssig geworden. Bitte l&ouml;schen Sie dies!");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.<br /><br />Minus-Guthaben des Verdoppler-Accounts repariert und Mitgliedsmail erweitert mit Transaktionsummer und IP-Nummer.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bitte verschieben Sie die doubler-Templates (Ordner: {!PATH!}/templates/".GET_LANGUAGE()."/html/) in den neuen Order doubler!");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Vorbereitung auf die neue Mediendaten v0.0.4.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Zwei SQL-Fehler in <strong>inc/doubler_send.php</strong> beseitigt.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("De-/Aktivieren des mit dieser Erweiterung verkn&uuml;pften Modules eingebunden.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `action`='extras', `sort`='4' WHERE `what`='doubler' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mitgliedsmen&uuml; komplett umgebaut.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Hash-Erstellung von <strong>md5()</strong> auf bessere Funktion <strong>generateHash()</strong> umgestellt.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 47b64ed21fbe660dea47771d242fe4e73489ab59..756ad1cded81701f3c27509a4acc0507a3c3b1c8 100644 (file)
@@ -44,33 +44,33 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("");
 
                // Update notes (these will be set as task text!)
@@ -79,10 +79,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 10fb21a64294221f5bf4dcb531f7b52d35926518..262c1d2824b3617ab75c7941fc26386604c7cd25 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.2.1");
+EXT_SET_VERSION('0.2.1');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // Create database
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_holidays`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_user_holidays` (
@@ -79,7 +79,7 @@ PRIMARY KEY(id)
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_max_receive` WHERE value='0' LIMIT 1");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_holidays`");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='holiday' LIMIT 1");
@@ -88,75 +88,75 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_max_receive` (value, comment) VALUES ('0','Urlaub')");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='holiday' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='holiday' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlende Abfrage im Mitlieder-Modul, on Erweiterung auch aktiviert ist.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("IP-Nummer und Browserbezeichnung wird in Admin-Mails eingesetzt.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link zum Mitgliedsprofil in Funktion <u>ADMIN_USER_PROFILE_LINK()</u> ausgelagert.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate: SQL-Anweisungen gesch&uuml;tzt.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern der Urlaubsanfrage korregiert.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD holiday_active ENUM('Y','N') NOT NULL DEFAULT 'N'");
                ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_max_receive` WHERE value='0' LIMIT 1");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD holiday_lock BIGINT(20) UNSIGNED NOT NULL DEFAULT '".(getConfig('one_day')*2)."'");
@@ -165,69 +165,69 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Die Mitglieder-Accounts werden nicht mehr gesperrt, sondern nur auf <strong>Urlaub</strong> geschaltet. Lassen Sie sich nicht davon verwirren, dass sie &quot;freigegeben&quot; sind!");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD holiday_mode ENUM('DIRECT','RESET') NOT NULL DEFAULT 'RESET'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Urlaubsschaltung wird erst Abends um 00:00 Uhr aktiv und nicht durch die Beantragung. Dies kann nun auch auf direkte Umstellung eingestellt werden.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD holiday_mode ENUM('DIRECT','RESET') NOT NULL DEFAULT 'RESET'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD holiday_activated BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlende Tabellenspalte hinzugef&uuml;gt.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("if-Anweisungen auf Funktion <strong>empty()</strong> umgestellt.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu_las` (la_id, la_action, la_what) VALUES ('member', '', 'list_holiday')");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu_las` (la_id, la_action, la_what) VALUES ('member', '', 'del_holiday')");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu_las` (la_id, la_action, la_what) VALUES ('config', '', 'config_holiday')");
 
                // Depends on sql_patches (or you have to execute these both SQL statements by phpMyAdmin
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erweiterung in's neue Men&uuml;system integriert.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `action`='account', `sort`='2', `title`='In Urlaub' WHERE `what`='holiday' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mitgliedsmen&uuml; komplett umgebaut.");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET title = 'Urlaubsmanagement' WHERE action = 'holiday' AND (`what`='' OR `what` IS NULL) LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mitgliedsmen&uuml; komplett umgebaut.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index a4c285c7a8cb468cf7a0d539c759ef9c6da91a5c..876c0bddd395e9c6ad45bcd95fff8c63e5e30347 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.1.6");
+EXT_SET_VERSION('0.1.6');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.51", "0.0.52", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', "0.0.51", "0.0.52", '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD html ENUM('Y','N') NOT NULL DEFAULT 'Y'");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_bonus` ADD html_msg ENUM('Y','N') NOT NULL DEFAULT 'N'");
@@ -58,7 +58,7 @@ case "register": // Do stuff when installation is running (modules.php?module=ad
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','html_mail','HTML-Empfang','3','Y','Y')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` DROP html");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_bonus` DROP html_msg");
@@ -66,76 +66,76 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='html_mail'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='html_mail' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='html_mail' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Der erstellte HTML-Code wird noch kompiliert (eigene HTML-Codes umgewandelt).");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlende Abfrage im Mitlieder-Modul, on Erweiterung auch aktiviert ist.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate: SQL-Anweisungen gesch&uuml;tzt.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
 
-       case "0.1.6":
+       case '0.1.6':
                // Dependency is needed for ext-registration!! (want to alter a non existent Table)
-               EXT_ADD_UPDATE_DEPENDS("bonus");
+               EXT_ADD_UPDATE_DEPENDS('bonus');
                EXT_SET_UPDATE_NOTES("Abh&auml;nigkeit von der Erweiterung <strong>bonus</strong> hinzugef&uuml;gt.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 084e967448cdbff5a7032c015615ee404325974e..a751908268f583e67c896539b09a15becdc03cf8 100644 (file)
@@ -44,38 +44,38 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.1");
+EXT_SET_VERSION('0.0.1');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE FROM `{!_MYSQL_PREFIX!}_countries` WHERE provider = 'ext-iso3166';");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_countries` DROP `provider`;");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_countries` SET is_active = 'Y' WHERE provider = 'ext-iso3166';");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_countries` SET is_active='N' WHERE provider = 'ext-iso3166';");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.2
+       case '0.0.1': // SQL queries for v0.0.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_countries` ADD `provider` ENUM( 'user', 'ext-iso3166' ) NOT NULL DEFAULT 'user';");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_countries` (`code`,`descr`,`provider`)
 VALUES ('AD', 'Andorra', 'ext-iso3166'),
@@ -323,7 +323,7 @@ VALUES ('AD', 'Andorra', 'ext-iso3166'),
 ('ZW', 'Zimbabwe', 'ext-iso3166');");
 
                // This extension depends on the country extension
-               EXT_ADD_UPDATE_DEPENDS("country");
+               EXT_ADD_UPDATE_DEPENDS('country');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erste Liste von 243 L&auml;ndercodes nach ISO 3166. (Quelle: Selfhtml)<br />Alle L&auml;nder sind zuerst deaktiviert. Achtung DE k&ouml;nnte doppelt vorkommen.<br />Ein Aktivieren/Deaktivieren l&auml;sst alle L&auml;nder beim Registrieren anzeigen oder nicht Anzeigen.");
@@ -332,10 +332,10 @@ VALUES ('AD', 'Andorra', 'ext-iso3166'),
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 96878b1c3eb568233154c3b14c96707abbc00dcd..75f1e7ec8a27fa3d08fce74cafe9764b2b9428e9 100644 (file)
@@ -43,36 +43,36 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('stats','logs','Aufruflogb&uuml;cher','Verwalten Sie Ihre Aufruflogb&uuml;cher mit diesem Admin-Bereich! (Derzeit nur Download!)',8)");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `logs_base` VARCHAR(255) NOT NULL DEFAULT 'logs'");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='logs'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("");
 
                // Update notes (these will be set as task text!)
@@ -81,10 +81,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index c546b5ab9d5e9d06e30491e9d75ef5d696e01bff..f1262fa5ea8a9a595d9dd72c810b4f44f64f11e1 100644 (file)
@@ -43,202 +43,202 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.3.3");
+EXT_SET_VERSION('0.3.3');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9", "0.3.0", "0.3.1", "0.3.2", "0.3.3"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
-       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', hidden='N', admin_only='N', mem_only='N' WHERE `module`='mailid' LIMIT 1");
+       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', `hidden`='N', `admin_only`='N', `mem_only`='N' WHERE `module`='mailid' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='Y' WHERE `module`='mailid' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Veraltetes Update.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Turbo-Bonus interegiert, nur wenn bonus-Erweiterung v0.2.2 oder h&ouml;her ist.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Absicherung der Variablen <em>uid</em>, <em>mailid</em> und <em>bonusid</em> durch die eigene Funktion <em>bigintval()</em> in den beiden Dateien <em>mailid.php</em> und <em>mailid_top.php</em>.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Weisse Seite im Mozilla bzw. <em>Seite nicht gefunden</em> unter dem IE behoben.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("register_globals-Problem behoben");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mailbest&auml;tigung klappt wieder.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("5 Nachkommastellen implementiert");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Probe-Fix wegen falschen Best&auml;tigungcodes bei Druck auf Return-Taste. Bitte aktualisieren Sie auch das Template <u>mailid_confirm_buttom.tpl</u>, damit die Best&auml;tigung ohne Code auch klappt!");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate an den Scripten <u>mailid.php</u> und <strong>mailid_top.php</strong> durchgef&uuml;hrt.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sende-Pool wird nicht mehr ben&ouml;tigt, um die Best&auml;tigung durchzuf&uuml;hren.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Template <u>mailid_frameset.tpl</u> nach <u>mailid_frames.tpl</u> umbenannt.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ausgabe des generierten HTML-Codes nach <u>inc/footer.php</u> verlagert.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlende Variablen gefixt.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Gesamt-{!POINTS!} werden nun nach Best&auml;tigung angezeigt. Bitte aktualisieren Sie die Templates <u>mailid_points_done.tpl</u>, <u>mailid_points_done2.tpl</u> und <u>mailid_frames.tpl</u> !");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Variablen abgesichert (Diverse Warnhinweise des Webservers sind damit unterbunden).");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Parser-Fehler beseitigt.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler wegen fehlende Datenfeldelementen behoben.");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Modul <strong>mailid</strong> war nicht gesetzt. Dadurch wurden die URLs (loader z.B.) umgeschrieben und f&uuml;hrten somit zu Fehlern.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Vorbereitung auf die neue Mediendaten v0.0.4.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Den Punkte in der Gesamt-{!POINTS!}-Anzahl in ein Komma umgewandelt.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("De-/Aktivieren des mit dieser Erweiterung verkn&uuml;pften Modules eingebunden.");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wenn die {!POINTS!} dem <strong>noch auf Auszahlung wartendem Guthaben</strong> aufaddiert wird, wird eine entsprechende Nachricht ausgegeben (neue Templates <strong>mailid_points_locked</strong> und <strong>mailid_points_locked2</strong> sind hinzugekommen!)");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bonus- und Standart-Referal-ID ausblendbar aus Aktiv-Rallye und bekommt kein Aktiv-Guthaben.");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("<strong>Code wiederholen</strong> nach <strong>Code eingeben</strong> hin ge&auml;ndert.");
                break;
 
-       case "0.3.0": // SQL queries for v0.3.0
+       case '0.3.0': // SQL queries for v0.3.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlende Templates hinzugef&uuml;gt.");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("mailid.php und mailid_top.php k&ouml;nnen erst bei aktivierter Erweiterung <strong>mailid</strong> benutzt werden. Solange gibt es fatale Fehlermeldungen.");
                break;
 
-       case "0.3.2": // SQL queries for v0.3.2
+       case '0.3.2': // SQL queries for v0.3.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bitte das Template <em><strong>{!PATH!}/templates/de/html/mailid/mailid_points_lcoked2.tpl</strong></em> l&ouml;schen. Noices fixed.");
                break;
 
-       case "0.3.3": // SQL queries for v0.3.3
+       case '0.3.3': // SQL queries for v0.3.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Variablen-Handling skriptglobal ge&auml;ndert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 21861a1344b54d6493613a302201f7a0c458095e..68450d6deac2526d8301d94ee1423d5aeed398d9 100644 (file)
@@ -43,73 +43,73 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.6");
+EXT_SET_VERSION('0.0.6');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD maintenance ENUM('Y','N') NOT NULL DEFAULT 'N';");
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','maintenance','Wartungsmodus','Schalten Sie den Wartungsmodus ein, nur wenn sehr schwerwiegende Fehler vorliegen, die Sie oder mxchange.org nicht schenll genug beheben k&ouml;nnen.','10')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='maintenance'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erweiterung bleibt wegen integrierten Schalters immer aktiv.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate: SQL-Anweisungen gesch&uuml;tzt.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 10f60565a470e1e061a0dd065b5bcd0e7542aa74..8856c68211757bc88fc87c0c86897d8b045b20ba 100644 (file)
@@ -43,54 +43,54 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.9");
+EXT_SET_VERSION('0.0.9');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_mediadata`");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_mediadata'");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_guest_menu` WHERE `what`='mediadata'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Berechnung der Gesamt-{!POINTS!} korregiert.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Daten des Scriptes mit eingebunden.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate: SQL-Anweisungen gesch&uuml;tzt.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // SQL commands to run
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_mediadata`");
                ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_mediadata` (
@@ -103,17 +103,17 @@ PRIMARY KEY(media_key)
                EXT_SET_UPDATE_NOTES("Teile der Mediendaten werden in seperater Tabelle gesichert. Bitte beachten Sie, dass dieses Update nur Daten des <strong>aktuellen</strong> Zustandes ber&uuml;cksichtigen kann und <strong>nicht</strong> bereits gel&ouml;schter Mitglieder.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("if-Anweisungen auf Funktion <strong>empty()</strong> umgestellt.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mediendaten mussten komplett regeneriert werden.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD mt_start BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD mt_stage BIGINT(20) UNSIGNED NOT NULL DEFAULT '500'");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_mediadata','Mediendaten','Stellen Sie allgemeine Einstellungen zu den Mediendaten ein.', 10)");
@@ -123,12 +123,12 @@ PRIMARY KEY(media_key)
 Bitte stellen Sie diesen derzeit manuell unter <a href=\"{!URL!}/modules.php?module=admin&amp;what=config_mediadata\">Einstellungen-Medidata</a> selber einstellen.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','mediadata','Mediendaten',3,'Y','N')");
 
                // Update notes (these will be set as task text!)
@@ -137,10 +137,10 @@ Bitte stellen Sie diesen derzeit manuell unter <a href=\"{!URL!}/modules.php?mod
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
@@ -148,7 +148,7 @@ default: // Do stuff when extension is loaded
 }
 
 if ((isset($dry_run)) && (isset($EXT_LOAD_MODE))) {
-       if ((!$dry_run) && ($EXT_LOAD_MODE == "update") && ($EXT_VER == "0.0.4")) {
+       if ((!$dry_run) && ($EXT_LOAD_MODE == 'update') && ($EXT_VER == '0.0.4')) {
                // Add auto-check file
                ADD_INC_TO_POOL(sprintf("%sinc/gen_mediadata.php", constant('PATH')));
        } // END - if
index dfbe5fabf3badc4441a67436e19cf2bc034aa1db..525dd840c016acff7fae8b3eb9a6edb089d5f1b7 100644 (file)
@@ -43,69 +43,69 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.8");
+EXT_SET_VERSION('0.0.8');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('mods', NULL, 'Modul-Management','Verwalten Sie die Basis-Module index, login, admin usw.', 4)");
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('mods','config_mods','Module &auml;ndern','&Auml;ndern Sie hier die Zugtiffsrechte auf die Module. Was dennoch nicht geht: Mitglied- oder Gastzugriffsrtechte auf Admin-Module bzw. Gastzugriffsrechte auf Mitglieder-Module. Diese sind extra abgesichert.', 1)");
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('mods','stats_mods','Modul-Statistiken','Sehen Sie sich hier die Statistiken der Module und die damit verkn&uuml;pften action- und what-Dateien an. Bei einigen Modulen gibt es allerdings keine verkn&uuml;pften Dateien und somit keine Extra-Statistik.', 2)");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `action`='mods'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Dummy-Release im Internet???");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates und SQL-Anweisungen abgesichert.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET title = 'Modul-Management' WHERE action = 'mods' AND (`what`='' OR `what` IS NULL) LIMIT 1");
 
                // Update notes (these will be set as task text!)
@@ -114,10 +114,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 04730bb21add089dfc3b8606f2bbaa13204e4b81..3d59ac095db27d8dab89f78c61d94473bc8adefb 100644 (file)
@@ -43,132 +43,132 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.1.8");
+EXT_SET_VERSION('0.1.8');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlende Abfrage im Mitlieder-Modul, on Erweiterung auch aktiviert ist.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sperrung des Mitgliederprofiles nach &Auml;nderung kann unter &quot;Sonstige Einstellungen&quot; abgeschaltet werden (0 setzen!)");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Anrede &quot;Firma&quot; hinzugef&uuml;gt.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Datumsformat festgelegt auf ausf&uuml;hrlich.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Email-Adresse wird vor dem Speichern auf G&uml;tigkeit hin getestet.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Einbindung der Erweiterung <strong>country</strong>, die Sie sich noch optional von <a href=\"{!URL!}/modules.php?module=admin&amp;what=extensions&amp;do=search\">meiner Seite herunterladen</a> m&uuml;ssen.<br />
 <br />
 <strong>Wichtig: Laden Sie noch die Template member_mydata_overview und member_mydata_edit (beide zu finden unter templates/".GET_LANGUAGE()."/html/member/ !) mit hoch!</strong>");
 
                // Depends on 'country'!
-               EXT_ADD_UPDATE_DEPENDS("country");
+               EXT_ADD_UPDATE_DEPENDS('country');
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Es werden dem Mitglied nur aktivierte L&auml;ndercodes zur Auswahl angeboten.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("SQL-Anweisungen mit SQL_QUERY_ESC() abgesichert.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Die Einstellungen k&ouml;nnen nun auch ohne der Erweiterung <strong>country</strong> abgespeichert werden.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Hash-Erstellung von <strong>md5()</strong> auf bessere Funktion <strong>generateHash()</strong> umgestellt.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 7032e51e57dc024b321ef209edabb800a91a0f55..38ea95a18be500e29291e5fa456e2c2267b3bfb0 100644 (file)
@@ -43,33 +43,33 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("");
 
                // Update notes (these will be set as task text!)
@@ -78,10 +78,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 97c88b39edf0968c9b5fdb2e3a7d934d2f98bd6f..2158cf021691d3b6b644d0dd7a34c67307aad786 100644 (file)
@@ -43,38 +43,38 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.1.2");
+EXT_SET_VERSION('0.1.2');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `action`='newsletter' AND what != 'send_newsletter'");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='newsletter'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `locked`='N', `visible`='Y' WHERE `what`='newsletter' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `locked`='Y', `visible`='N' WHERE `what`='newsletter' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('newsletter', NULL, 'Newsletter','Einstellungen am Newsletter, Newsletter versenden, Abbestellungen auflisten usw.', 3)");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('newsletter','list_newsletter','Abbestellungen','Alle Abbestellungen auflisten und bearbeiten.', 2)");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('newsletter','config_newsletter','Einstellungen','Geb&uuml;hr zum Abbestellen des Newsletters usw. sind hier einstellbar.', 3)");
@@ -89,68 +89,68 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Vor der eigentlichen Freigabe dieser Erweiterungen habe ich sie versehendlich im Archiv mit auf den Server hochgeladen. Diese Version f&uuml;gt die bereits angek&uuml;ndigte Funktionalit&auml;ten, wie zum Beispiel das Einstellen der Abschaltgeb&uuml;hr.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("URL im Versendeformular und Option <em>Immer aktiv</em> f&uuml;r diese Erweiterung deaktiviert.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates und SQL-Anweisungen abgesichert.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bitte Script inc/monthly_newsletter.php l&ouml;schen!");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Script <strong>inc/monthly/monthly_newsletter.php</strong> wird nicht mehr ausgef&uuml;hrt, wenn die Erweiterung nicht aktiviert ist.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Nur bei installierter Erweiterung <strong>html_mail</strong> k&ouml;nnen Sie auch HTML-Mails versenden.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Nur bei installierter Erweiterung <strong>html_mail</strong> k&ouml;nnen Sie auch HTML-Mails versenden.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&auml;hrung auf die Erweiterung <a href=\"#\"><strong>ext-other.zip</strong></a> verlagert. Bitte auch diese aktualisieren.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index a2e1a5c3a84458f5392d9859d9fda08124261bd1..57ce9a8b39e69074b89465398f2bf0153edb3e15 100644 (file)
@@ -43,66 +43,66 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.1.9");
+EXT_SET_VERSION('0.1.9');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD nickname VARCHAR(255) NOT NULL DEFAULT ''");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD nick_uid ENUM ('nick','uid') NOT NULL DEFAULT 'uid'");
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','nickname','Nicknamen','5','Y','Y')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='nickname'");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE what IN ('config_nickname','list_nickname')");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_nickname_history`");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='nickname' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='nickname' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_extensions` SET ext_has_css='Y' WHERE ext_name='nickname' AND ext_has_css='N' LIMIT 1");
 
                // This update depends on sql_patches update!
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("CSS-Datei kann per Adminbereich ein- und ausgeschaltet werden.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlende Abfrage im Mitlieder-Modul, on Erweiterung auch aktiviert ist.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wegen des Theme-Supportes hat sich die URL zur CSS-Datei ge&auml;ndert.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD nickname_len TINYINT(3) UNSIGNED NOT NULL DEFAULT '5'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD nickname_pattern VARCHAR(255) NOT NULL DEFAULT 'a-zA-Z0-9_'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD nickname_chars VARCHAR(255) NOT NULL DEFAULT 'a-z, A-Z, 0-9, _'");
@@ -112,71 +112,71 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Minimale L&auml;nge, sowie erlaubte Zeichen sind per Adminbereich &auml;nderbar. Setzen Sie als erlaubte Zeichen nur URL-konforme Zeichen ein!");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Design &quot;Solid-Business&quot; eingebaut.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` DROP nick_uid");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Auswahlf&uuml;r Mitglied ob mit Nickname oder User-ID einloggen entfernt.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Zum Zusenden eines neuen Passwortes kann jetzt entweder der Nickname / User-ID <u>ODER</u> die angemeldete EMail-Adresse eingegeben werden.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("CSS-Datei in general.css verschmolzen (Patch 435!)");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates und SQL-Anweisungen abgesichert.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `action`='extras', `sort`='2' WHERE `what`='nickname' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mitgliedsmen&uuml; komplett umgebaut.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mitglieder ohne Nickname sollten kein <strong>*failed*</strong> mehr sehen.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('user','list_nickname','Nickname-Historie','Listet alle verwendeten Nicknames der Mitglieder auf.', 12)");
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_nickname_history`");
                ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_nickname_history` (
@@ -196,10 +196,10 @@ PRIMARY KEY(id)
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index d6a6b30dfeb9d770a31f41cd8f0da596e5465c62..95cb2ac4db64a4dd378a8ff5866b086171c737d8 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.5");
+EXT_SET_VERSION('0.0.5');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_online`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_online` (
@@ -73,7 +73,7 @@ KEY `admin_member` (`is_admin`,`is_member`)
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('misc','usr_online','Online-Statistik','Eine Liste von derzeit &quot;Online&quot; Usern. Doppelte Eintr&auml;ge k&ouml;nnte auf mangelnden Cookie-Support des Browsers oder auf einen Spider hindeuten.', 1)");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_online`");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='usr_online'");
@@ -83,40 +83,40 @@ case "remove": // Do stuff when removing extension
        UNREGISTER_FILTER('init', 'UPDATE_ONLINE_LIST', true, $dry_run);
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='Y', `locked`='N' WHERE `action`='online' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='N', `locked`='Y' WHERE `action`='online' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler <u>Unknown column 'visibled' in 'field list'</u> behoben.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates und SQL-Anweisungen abgesichert.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erstellung der Datenbanktabelle `{!_MYSQL_PREFIX!}_online` in diese Erweiterung ausgelagert.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('online',NULL,'Jetzt Online','2','Y','N')");
 
                // Register filter
@@ -128,10 +128,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index ca46cd679c954bb02dc101032d58920a713733aa..0f59cda0a334b9c05332e42f480efe9ef2c58ce2 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.6");
+EXT_SET_VERSION('0.0.6');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_optimize_gain`(
   id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT,
@@ -60,61 +60,61 @@ case "register": // Do stuff when installation is running (modules.php?module=ad
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('misc','optimize','DB optimieren','F&uuml;hren Sie dies ab und an aus, damit &uuml;berfl&uuml;ssige Daten aus der Datenbank entfernt werden.','5')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_optimize_gain`");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='optimize'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erweiterung bleibt wegen integrierten Schalters immer aktiv.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index b78a82573141a5a8432d57e2d8ec2e542fb34835..30b12b27f3f735b88f5ff4a5df0ec56a430b7f4f 100644 (file)
@@ -43,39 +43,39 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.5.0");
+EXT_SET_VERSION('0.5.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.1", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9", "0.3.0", "0.3.1", "0.3.2", "0.3.3", "0.3.4", "0.3.5", "0.3.6", "0.3.7", "0.3.8", "0.3.9", "0.4.0", "0.4.1", "0.4.2", "0.4.3", "0.4.4", "0.4.5", "0.4.6", "0.4.7", "0.4.8", "0.4.9", "0.5.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9', '0.4.0', '0.4.1', '0.4.2', '0.4.3', '0.4.4', '0.4.5', '0.4.6', '0.4.7', '0.4.8', '0.4.9', '0.5.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_order'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='order' LIMIT 1");
-       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', hidden='N', admin_only='N', mem_only='Y' WHERE `module`='order' LIMIT 1");
+       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', `hidden`='N', `admin_only`='N', `mem_only`='Y' WHERE `module`='order' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='order' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `visible`='N', `locked`='Y' WHERE `module`='order' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.1": // SQL queries for v0.1
+       case '0.1.0': // SQL queries for v0.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD order_max_full ENUM('ORDER','MAX') NOT NULL DEFAULT 'MAX'");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`sort`,`descr`) VALUES ('setup','config_order','Mailbuchungsseite','7','Einstellungen am Mailbuchungsformular.')");
 
@@ -83,7 +83,7 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Maximale Mailbuchungen sind nun vom maximalen Empfang abh&auml;gig.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_order' LIMIT 1");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`sort`,`descr`) VALUES ('setup','config_order','Mailbuchungsseite','7','Einstellungen am Mailbuchungsformular.')");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD mail_orders BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
@@ -92,74 +92,74 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Maximale Mailbuchung vervollst&auml;ndigt (Admin-Bereich und im Buchungsformular selber).");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Maximale Mailbuchungen repariert (werden nun hochgez&auml;hlt und bei t&auml;glichem Reset auf 0 gesetzt).");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Dummy-Datenfeld wird wieder gel&ouml;scht, um Probleme zu vermeiden. Fehlende Spalte <em>mail_order</em> korregiert auf <em>mail_orders</em>.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Templates <u>member_frameset-back.tpl</u> und <u>member_frameset-send.tpl</u> nach <u>member_order_back.tpl</u> und <u>member_order_send.tpl</u> umbenannt.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Es wird nun &uuml;berpr&uuml;ft ob auch gen&uuml;gend Empf&auml;nger eingegeben worden sind und ob auch gen&uuml;gend empfangsbereit sind.");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD order_min BIGINT(20) UNSIGNED NOT NULL DEFAULT 10");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Minimum an Empf&auml;nger pro Mailbuchung einstellbar. Standart: 10 Empf&auml;nger");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Anzahl mindestens einszustellende Empf&auml;nger wird nun auch angezeigt.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Speicherung der Einstellungen klappt.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler in Mailbuchung behoben: Es wurde beim Ermitteln der n&ouml;tigen {!POINTS!} die maximale Anzahl von Usern in der Kategorie gew&auml;hlt und
 nicht die vom Mitglied eingegebene. Resultat: Das Script beschwerte sich, der User h&auml;tte nicht gen&uuml;gend {!POINTS!} auf dem Konto. Ein Rechenbeispiel:
@@ -174,27 +174,27 @@ nicht die vom Mitglied eingegebene. Resultat: Das Script beschwerte sich, der Us
 </ol>");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler mit <u>__MIN_VALUE</u> behoben.");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Konstantenproblem beseitigt.");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit nicht funktionierenden Mailbuchungen beseitigt.");
                break;
 
-       case "0.3.0": // SQL queries for v0.3.0
+       case '0.3.0': // SQL queries for v0.3.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Basis-Modul <strong>order.php</strong> abgesichert, wenn Erweiterung nicht aktiviert ist.");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD order_select VARCHAR(255) NOT NULL DEFAULT 'userid'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD order_mode ENUM('ASC','DESC') NOT NULL DEFAULT 'DESC'");
 
@@ -202,77 +202,77 @@ nicht die vom Mitglied eingegebene. Resultat: Das Script beschwerte sich, der Us
                EXT_SET_UPDATE_NOTES("Beworbene URL wird nun getestet.");
                break;
 
-       case "0.3.2": // SQL queries for v0.3.2
+       case '0.3.2': // SQL queries for v0.3.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Datumsformat festgelegt auf ausf&uuml;hrlich.");
                break;
 
-       case "0.3.3": // SQL queries for v0.3.3
+       case '0.3.3': // SQL queries for v0.3.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Unter <strong>Einstellungen - Mailbuchungsseite</strong> war immer die Tabellenspalte <strong>Mitgliedsnummer</strong> ausgew&auml;hlt.");
                break;
 
-       case "0.3.4": // SQL queries for v0.3.4
+       case '0.3.4': // SQL queries for v0.3.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Dateiamenskonflikt zwischen den Erweiterungen <strong>support</strong> und <strong>order</strong> behoben.");
                break;
 
-       case "0.3.5": // SQL queries for v0.3.5
+       case '0.3.5': // SQL queries for v0.3.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Das Mitglied konnte geziehlt die Anzahl Mailbuchungen durch Abspeichern seines Profiles beeinflussen. Der Fehler war eine falsche Tabellenspalte. Dies war <strong>max_mails</strong>, die durch das Mitglieder ver&auml;nderbar ist und zur Festellung der Maximalen Mailbuchungen herangezogen wurde.");
                break;
 
-       case "0.3.6": // SQL queries for v0.3.6
+       case '0.3.6': // SQL queries for v0.3.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Im Modul order (<strong>inc/modules/order.php</strong>) wurde fehlerhafterweise die Erweiterung <strong>beg</strong> getestet.");
                break;
 
-       case "0.3.7": // SQL queries for v0.3.7
+       case '0.3.7': // SQL queries for v0.3.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("SQL-Anweisungen mit SQL_QUERY_ESC() abgesichert.");
                break;
 
-       case "0.3.8": // SQL queries for v0.3.8
+       case '0.3.8': // SQL queries for v0.3.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mailbuchungsseite korregiert.");
                break;
 
-       case "0.3.9": // SQL queries for v0.3.9
+       case '0.3.9': // SQL queries for v0.3.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erneuten Fehler in Mailbuchungsseite behoben.");
                break;
 
-       case "0.4.0": // SQL queries for v0.4.0
+       case '0.4.0': // SQL queries for v0.4.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES(POINTS."-Abzug klappt wieder. Danke an Andreman!");
                break;
 
-       case "0.4.1": // SQL queries for v0.4.1
+       case '0.4.1': // SQL queries for v0.4.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.4.2": // SQL queries for v0.4.2
+       case '0.4.2': // SQL queries for v0.4.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Vorbereitung auf die neue Mediendaten v0.0.4.");
                break;
 
-       case "0.4.3": // SQL queries for v0.4.3
+       case '0.4.3': // SQL queries for v0.4.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Neue Urlaubsschaltung mit integriert.");
                break;
 
-       case "0.4.4": // SQL queries for v0.4.4
+       case '0.4.4': // SQL queries for v0.4.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ein <strong>WHERE ext_active='Y'</strong> tauchte bei einigen Betreibern auf und ist mit dieser Version beseitigt.");
                break;
 
-       case "0.4.5": // SQL queries for v0.4.5
+       case '0.4.5': // SQL queries for v0.4.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("De-/Aktivieren des mit dieser Erweiterung verkn&uuml;pften Modules eingebunden.");
                break;
 
-       case "0.4.6": // SQL queries for v0.4.6
+       case '0.4.6': // SQL queries for v0.4.6
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('order',NULL,'Mailbuchungen',3,'Y','N')");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('order','order2','Framekiller-Mails',2,'Y','N')");
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `action`='order', `sort`='1', `title`='Klick-Mails' WHERE `what`='order' LIMIT 1");
@@ -281,26 +281,26 @@ nicht die vom Mitglied eingegebene. Resultat: Das Script beschwerte sich, der Us
                EXT_SET_UPDATE_NOTES("Mitgliedsmen&uuml; komplett umgebaut.");
                break;
 
-       case "0.4.7": // SQL queries for v0.4.7
+       case '0.4.7': // SQL queries for v0.4.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
 
-       case "0.4.8": // SQL queries for v0.4.8
+       case '0.4.8': // SQL queries for v0.4.8
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `title`='Mailbuchung' WHERE `what`='config_order' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkt &quot;Mailbuchungsseite&quot; nach &quot;Mailbuchung&quot; umbenannt und weitere Einstellungen aus Sonstige Einstellungen verschoben.");
                break;
 
-       case "0.4.9": // SQL queries for v0.4.9
+       case '0.4.9': // SQL queries for v0.4.9
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD repay_deleted_mails ENUM('REPAY','JACKPOT','SHRED') NOT NULL DEFAULT 'REPAY'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bei L&ouml;schung von Mailbuchungen kann nun global entschieden werden (Einstellungen also), ob die verbliebenen {!POINTS!} wieder gutgeschrieben werden sollen oder in den Jackpot landen.");
                break;
 
-       case "0.5.0": // SQL queries for v0.5.0
+       case '0.5.0': // SQL queries for v0.5.0
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_url_blacklist`");
                ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_url_blacklist` (
 `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT,
@@ -317,15 +317,15 @@ INDEX (`pool_id`)
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
        // Do daily reset only when installed and extension version is at least 0.1.1
-       if ((isResetModeEnabled()) && (isInstalled()) && (isAdminRegistered()) && (GET_EXT_VERSION("order") >= "0.1.1")) {
+       if ((isResetModeEnabled()) && (isInstalled()) && (isAdminRegistered()) && (GET_EXT_VERSION('order') >= '0.1.1')) {
                // Reset mail order values
                $result_ext = SQL_QUERY("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET mail_orders=0 WHERE mail_orders > 0", __FILE__, __LINE__);
        } // END - if
index 6c394b89836ddbf5a424c6323d3fa493e90644c7..7f8f2aee833f6d9e0c6a02933d4f24689df4e0cf 100644 (file)
@@ -43,84 +43,84 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.2.1");
+EXT_SET_VERSION('0.2.1');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_other','Sonstige Einstellungen','Sonstige Einstellungen an Ihrem Mailtausch.',13)");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_other'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler <div class=\"admin_failed\">Warning: Missing argument 2 for create_timestamp_from_selections() in {!PATH!}inc/libs/pro_functions.php on line 227</div> behoben.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Speichern der Einstellungen vereinfacht. Es wird dazu die Funktion ADMIN_SAVE_SETTINGS() verwendet.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD max_comma TINYINT(3) UNSIGNED NOT NULL DEFAULT '3'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Angezeigte Kommastellen k&ouml;nnen zwischen 0 und 5 eingestellt werden.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen endlich beseitigt.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ausgabemodus der CSS-Dateien hinzugef&uuml;gt. Bitte auch das Admin-Template aktualisieren!");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erweiterung bleibt wegen integrierten Schalters immer aktiv.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern der Einstellungen repariert.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Folgende Einstellungen k&ouml;nnen auf 0 gesetzt werden:
 <ol>
@@ -132,65 +132,65 @@ case "update": // Update an extension
 </ol>");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Gast- und Mitgliedsmen&uuml;s lassen sich voneinander getrentt ein- und auschalten.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wort &quot;Baustelle&quot; vom Auto-Versand entfernt, da dieser nun klappt.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD reject_url VARCHAR(255) NOT NULL DEFAULT '{!URL!}'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bei Ablehnung der URL wird jetzt endlich eine Standart-URL eingesetzt, die konfigurierbar ist. Fehler beim Laden der Konfiguration gefunden.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD currency VARCHAR(255) NOT NULL DEFAULT '&euro;'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Standart-W&auml;hrung der Geb&uuml;hren f&uuml;r alle Erweiterungen geltend hinzugef&uuml;gt.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Die sonstigen Einstellungen lassen sich nun nur noch &auml;ndern, wenn die Erweiterung <strong>other</strong> auch installiert ist. Anderfalls gibt es einen SQL-Fehler beim Speichern und GROSS_GESCHRIEBENE Worte im Formular.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD mailid_error_redirect ENUM('index','reject') NOT NULL DEFAULT 'index'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bei fehlerhafter Mail w&auml;hrend der Best&auml;tigung kann wahlweise zur Hauptseite weitergeleitet oder auf die eingestellte Ablehnungsseite umgeleitet werden.");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` CHANGE `mailid_error_redirect` `mailid_error_redirect` ENUM('INDEX','REJECT') NOT NULL DEFAULT 'INDEX'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Bei fehlerhafter Mail w&auml;hrend der Best&auml;tigung kann wahlweise zur Hauptseite weitergeleitet oder auf die eingestellte Ablehnungsseite umgeleitet werden.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `min_age` TINYINT(3) UNSIGNED NOT NULL DEFAULT 16");
 
                // Update notes (these will be set as task text!)
@@ -199,10 +199,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 058241cbbaaa4778d969363734c6a38dd87889e2..696fae67fa41bb68c72c0570fc96c23d404f7ba6 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version of this extension
-EXT_SET_VERSION("0.3.8");
+EXT_SET_VERSION('0.3.8');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.1", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9", "0.3.0", "0.3.1", "0.3.2", "0.3.3", "0.3.4", "0.3.5", "0.3.6", "0.3.7", "0.3.8"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_payouts`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_user_payouts` (
@@ -79,7 +79,7 @@ PRIMARY KEY(id)
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES ('main','payout','Auszahlungen','N','N','11')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_payouts`");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_payout_types`");
@@ -87,25 +87,25 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='payout'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='payout' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='payout' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('payouts', NULL, 'Auszahlungsmanagement','Management der Auszahlungsarten.','8')");
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `action`='payouts', `title`='Einstellungen' WHERE `action`='setup' AND `what`='config_payouts' LIMIT 1");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_payout_types` ADD from_account VARCHAR(255) NOT NULL DEFAULT ''");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_payout_types` ADD from_pass VARCHAR(255) NOT NULL DEFAULT ''");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_payout_types` ADD engine_url VARCHAR(255) NOT NULL DEFAULT ''");
@@ -114,136 +114,136 @@ case "update": // Update an extension
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_payout_types` ADD pass_enc ENUM('md5','base64','none') NOT NULL DEFAULT 'md5'");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_payouts` ADD password VARCHAR(255) NOT NULL DEFAULT ''");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_payouts` ADD target_url LONGTEXT NOT NULL");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_payouts` ADD banner_url LONGTEXT NOT NULL");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_payouts` ADD link_text VARCHAR(30) NOT NULL DEFAULT ''");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_payout_types` ADD allow_url ENUM('Y','N') NOT NULL DEFAULT 'N'");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_payout_types` CHANGE pass_enc pass_enc ENUM('md5','base64','xxx') NOT NULL DEFAULT 'xxx'");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Auflistung der Auszahlungen ausgelagert in Template <em>member_payout.tpl</em>.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("5 Nachkommastellen implementiert.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_payouts` CHANGE payout_total payout_total FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 0.00000");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_payout_types` CHANGE rate rate FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 0.00000");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Buttons aus Aufgabenauflisten ausgelagert");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ausgabe der Auszahlungsm&ouml;glichkeiten im Mitgliedsbereich repariert.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("IP-Nummer und Browserbezeichnung wird in Admin-Mails eingesetzt.");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link zum Mitgliedsprofil in Funktion <u>ADMIN_USER_PROFILE_LINK()</u> ausgelagert.");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Work-Arount-L&ouml;sung zu tempor&auml;ren Problemen mit der Task-ID eingebaut.");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Nachricht an Admin bei Auszahlungsanfrage wird endlich versendet.");
                break;
 
-       case "0.3.0": // SQL queries for v0.3.0
+       case '0.3.0': // SQL queries for v0.3.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates und SQL-Anweisungen abgesichert.");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler in Auszahlungsfunktion beseitigt, wenn Umrechnungsrate ungleich 1 eingestellt ist.");
                break;
 
-       case "0.3.2": // SQL queries for v0.3.2
+       case '0.3.2': // SQL queries for v0.3.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.3.3": // SQL queries for v0.3.3
+       case '0.3.3': // SQL queries for v0.3.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Vorbereitung auf die neue Mediendaten v0.0.4.");
                break;
 
-       case "0.3.4": // SQL queries for v0.3.4
+       case '0.3.4': // SQL queries for v0.3.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Anzahl zu &uuml;berweisende {!POINTS!} m&uuml;ssen immer gr&ouml;sser 0 sein, ansonsten bricht das Script mit einer Fehlermeldung an das Mitglied ab.");
                break;
 
-       case "0.3.5": // SQL queries for v0.3.5
+       case '0.3.5': // SQL queries for v0.3.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
 
-       case "0.3.6": // SQL queries for v0.3.6
+       case '0.3.6': // SQL queries for v0.3.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Hash-Erstellung von <strong>md5()</strong> auf bessere Funktion <strong>generateHash()</strong> umgestellt.");
                break;
 
-       case "0.3.7": // SQL queries for v0.3.7
+       case '0.3.7': // SQL queries for v0.3.7
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET title = 'Auszahlungsmanagement' WHERE action = 'payouts' AND (`what`='' OR `what` IS NULL) LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Verwaltung nach Management umgestellt.");
                break;
 
-       case "0.3.8": // SQL queries for v0.3.8
+       case '0.3.8': // SQL queries for v0.3.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index fbc58eb4d9573eed0213274c23504c25832a8366..55e6502c2237e9ffc3527b8cda063d50ec91e1fa 100644 (file)
@@ -38,14 +38,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version of this extension
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_primera`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_user_primera` (
@@ -80,37 +80,37 @@ PRIMARY KEY(id)
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES ('main','primera','Primera-Ein-/Auszahlungen','N','N','11')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_primera`");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `action`='primera'");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='primera'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='primera' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='primera' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 18c70c3f341a68625cfcd4acb8f765146b202eab..b4e84d842f52ae35060f6cd9740e144ea0274344 100644 (file)
@@ -43,87 +43,87 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.9");
+EXT_SET_VERSION('0.0.9');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Benachrichtungsmails werden nur beim t&auml;gichen Reset ausgesendet");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("5 Nachkommastellen implementiert");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Dummy-Release im Intranet??? Hmmm...");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Profilaktualisierungsmails werden nur dann ausgesendet, wenn <u>profile_update</u> und <u>prof_reupdate</u> &gt; 0 sind.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Datumsformat festgelegt auf ausf&uuml;hrlich.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Namenskonflikt gel&ouml;sst mit Erweiterung <strong>update</strong> (kommt noch raus!)");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates und SQL-Anweisungen abgesichert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 0a954d354a45cdd4a793e49875a29e69aa22b045..436c1c330835b6d70cb38158966aa8815fcb1431 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.3.5");
+EXT_SET_VERSION('0.3.5');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9", "0.3.0", "0.3.1", "0.3.2", "0.3.3", "0.3.4", "0.3.5"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_rallye_data`");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_rallye_prices`");
@@ -102,7 +102,7 @@ PRIMARY KEY(id)
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES ('main','rallyes','Ref-Rallyes','Y','Y','9')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // Drop tables
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_rallye_data`");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_rallye_prices`");
@@ -117,108 +117,108 @@ case "remove": // Do stuff when removing extension
        UNREGISTER_FILTER('extra_autopurge', 'RALLYE_EXTRA_AUTOPURGE', true, $dry_run);
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='Y', `locked`='N' WHERE `what`='rallyes' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='rallyes' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='N', `locked`='Y' WHERE `what`='rallyes' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='rallyes' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_rallye_data` ADD expired ENUM('Y','N') NOT NULL DEFAULT 'N'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ablaufen der Rallyes intergriert.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_rallye_users` ADD curr_points FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 0.00000");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Aktueller {!POINTS!}-Stand wird beachtet.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler <em>Unknown column 'd.useid' in 'on clause'</em> behoben.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlende Abfrage im Mitlieder-Modul, on Erweiterung auch aktiviert ist.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler <u>Template nicht gefunden</u> behoben und Admin-Formulare ausgelagert");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist. Und der vorherige Fehler <u>Template nicht gefunden</u> ist endlich beseitigt.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_rallye_users` CHANGE curr_points curr_points FLOAT(23,5) UNSIGNED NOT NULL DEFAULT 0.00000");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("5 Nachkommastellen implementiert.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Anzeigefehler im Gast-/Mitgliedsbereich behoben.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Admin-Mails korregiert.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Aktivierte bzw. abgelaufene Rallyes werden nur ausserhalb des CSS-Modus geladen (wenn also nicht css.php aufgerufen wurde)");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Weitere Templates vom Admin-Bereich ausgelagert und Referal-Anazahl in der Mail zur Rallye-Ank&uuml;ndigung repariert.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Funktion ADMIN_USER_PROFILE_LINK() mit Verlinkung auf Referal-Liste implementiert.");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_rallye_data` ADD min_users BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_rallye_data` ADD min_prices BIGINT(20) UNSIGNED NOT NULL DEFAULT '3'");
 
@@ -235,82 +235,82 @@ Zudem sollten Sie mindestens folgende Templates (in <strong>templates/".GET_LANG
 </ul>");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Links wegen <strong>what=admins_contct</strong> ge&auml;ndert.");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates und SQL-Anweisungen abgesichert.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkt &quot;Rallyes verwalten&quot; repariert.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Automatisches Starten von Referal-Rallyes repariert.");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fatalen Fehler beseitigt.");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                // Update notes (these will be set as task text!)
 
                EXT_SET_UPDATE_NOTES("Vorbereitung auf die neue Mediendaten v0.0.4.");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
 
-       case "0.3.0": // SQL queries for v0.3.0
+       case '0.3.0': // SQL queries for v0.3.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("if-Anweisungen auf Funktion <strong>empty()</strong> umgestellt.");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erweiterung f&uuml;r automatisch generierte Admin-Kontaktlinks ge&auml;ndert.");
                break;
 
-       case "0.3.2": // SQL queries for v0.3.2
+       case '0.3.2': // SQL queries for v0.3.2
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `action`='rals', `sort`='1', `title`='Referal-Rallye' WHERE `what`='rallyes' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mitgliedsmen&uuml; komplett umgebaut.");
                break;
 
-       case "0.3.3": // SQL queries for v0.3.3
+       case '0.3.3': // SQL queries for v0.3.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Rallyes werden nun nur dann automatisch beseitigt, wenn die Erweiterung <strong>autopurge</strong> installiert und aktiviert ist.");
                break;
 
-       case "0.3.4": // SQL queries for v0.3.4
+       case '0.3.4': // SQL queries for v0.3.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
 
-       case "0.3.5": // SQL queries for 0.3.5
+       case '0.3.5': // SQL queries for 0.3.5
                // This update depends on sql_patches
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Register filter
                REGISTER_FILTER('extra_autopurge', 'RALLYE_EXTRA_AUTOPURGE', false, true, $dry_run);
@@ -321,21 +321,21 @@ Zudem sollten Sie mindestens folgende Templates (in <strong>templates/".GET_LANG
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
        // Do stuff only when not in CSS mode
        if (($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1") && ($GLOBALS['cache_mode'] != "init")) {
                // Get total member count
-               $total = GET_TOTAL_DATA("CONFIRMED", "user_data", "userid", "status", true);
+               $total = GET_TOTAL_DATA("CONFIRMED", "user_data", 'userid', "status", true);
 
                // Add more data on higher versions
-               $ADD1 = ""; $ADD2 = ""; $OR = "";
-               if (GET_EXT_VERSION("rallye") >= "0.2.0") {
+               $ADD1 = ''; $ADD2 = ''; $OR = '';
+               if (GET_EXT_VERSION('rallye') >= '0.2.0') {
                        $ADD1 = ", min_users, min_prices";
                        $ADD2 = ", d.min_users, d.min_prices";
                        $OR   = " OR (d.min_users <= ".$total." AND d.min_users > 0)";
@@ -359,7 +359,7 @@ LIMIT 1", __FILE__, __LINE__);
 FROM `{!_MYSQL_PREFIX!}_rallye_data` AS d
 WHERE d.is_active='Y' AND d.notified='Y' AND d.expired='N' AND (d.end_time <= UNIX_TIMESTAMP()".$OR.")
 LIMIT 1", __FILE__, __LINE__);
-               if ((SQL_NUMROWS($result) == 1) && (EXT_IS_ACTIVE("autopurge"))) {
+               if ((SQL_NUMROWS($result) == 1) && (EXT_IS_ACTIVE('autopurge'))) {
                        // End rallye here...
                        RALLYE_EXPIRE_RALLYES($result);
                } // END - if
index d79f2e8d1b3f97b6776256254b6a0866df4a3210..d919dec1b52a3443a592ec494459d30ed2433b17 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.1");
+EXT_SET_VERSION('0.0.1');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0","0.0.1"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0','0.0.1'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_refs`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_user_refs` (
@@ -68,7 +68,7 @@ KEY (`refid`)
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','refback','Ref-Back einstellen',4,'N','N')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_refs`");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='refback'");
@@ -76,20 +76,20 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_refsystem` SET level=level-1");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='refback' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='refback' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD refback_enabled ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD refback_min_perc TINYINT(3) NOT NULL DEFAULT 0");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD refback_max_perc TINYINT(3) NOT NULL DEFAULT 100");
@@ -102,10 +102,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
@@ -114,7 +114,7 @@ default: // Do stuff when extension is loaded
 }
 
 // Shall we include special files?
-if ($EXT_LOAD_MODE == "register") {
+if ($EXT_LOAD_MODE == 'register') {
        // Execute this special file on this update
        ADD_INC_TO_POOL(sprintf("%sinc/gen_refback.php",
                constant('PATH')
index cedbb19a1afc6c521ddd8348242e08235267403b..9b03e5f2410b0e11d7ddc150e9f3a14d26660d8f 100644 (file)
@@ -43,37 +43,37 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.5.2");
+EXT_SET_VERSION('0.5.2');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.1", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9", "0.3.0", "0.3.1", "0.3.2", "0.3.3", "0.3.4", "0.3.5", "0.3.6", "0.3.7", "0.3.8", "0.3.9", "0.4.0", "0.4.1", "0.4.2", "0.4.3", "0.4.4", "0.4.5", "0.4.6", "0.4.7", "0.4.8", "0.4.9", "0.5.0", "0.5.1", "0.5.2"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9', '0.4.0', '0.4.1', '0.4.2', '0.4.3', '0.4.4', '0.4.5', '0.4.6', '0.4.7', '0.4.8', '0.4.9', '0.5.0', '0.5.1', '0.5.2'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_register'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.1": // SQL queries for v0.1
+       case '0.1.0': // SQL queries for v0.1
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_must_register`");
                ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_must_register` (
 id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT,
@@ -97,170 +97,170 @@ PRIMARY KEY(id)
                EXT_SET_UPDATE_NOTES("Einstellbare Pflichtfelder hinzugef&uuml;gt.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_extensions` SET ext_has_css='Y' WHERE ext_name='register' AND ext_has_css='N' LIMIT 1");
 
                // This update depends on sql_patches update!
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("CSS-Datei kann per Admin-Bereich ein- und ausgeschaltet werden.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // This update depends on sql_patches update!
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Standart Referal-ID kann per Admin-Bereich eingestellt werden (war vorher nur in modules.php und index.php direkt eingebbar.)");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wegen des Theme-Supportes hat sich die URL zur CSS-Datei ge&auml;ndert.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Konfiguration der Pflichtangaben ausgelagert in Template");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Pflichtfelder wieder eingebaut (waren irgentwie ausgebaut???)");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("S&auml;mtliche Sperren bei eingeloggten Admin deaktiviert.");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Cookie <u>refid</u> aus Anmeldeformular entfernt.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Design &quot;Solid-Business&quot; eingebaut.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("IP-Nummer und Browserbezeichnung wird in Admin-Mails eingesetzt.");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Referal-ID wird endlich korrekt gesetzt.");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Parse error in <u>what-register.php</u> beseitigt.");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Anrede &quot;Firma&quot; hinzugef&uuml;gt.");
                break;
 
-       case "0.3.0": // SQL queries for v0.3.0
+       case '0.3.0': // SQL queries for v0.3.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Email-Adresse wird vor dem Speichern auf G&uml;tigkeit hin getestet.");
                break;
 
-       case "0.3.2": // SQL queries for v0.3.2
+       case '0.3.2': // SQL queries for v0.3.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Einbindung der Erweiterung <strong>country</strong>, die Sie sich noch optional von <a href=\"{!URL!}/modules.php?module=admin&amp;what=extensions&amp;do=search\">meiner Seite herunterladen</a> m&uuml;ssen.<br />
 <br />
 <strong>Wichtig: Laden Sie noch das Template <strong>guest_register.tpl</strong> mit hoch, welches unter templates/".GET_LANGUAGE()."/html/guest/ zu finden ist!</strong>");
 
                // Depends on 'country'
-               EXT_ADD_UPDATE_DEPENDS("country");
+               EXT_ADD_UPDATE_DEPENDS('country');
                break;
 
-       case "0.3.3": // SQL queries for v0.3.3
+       case '0.3.3': // SQL queries for v0.3.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Es werden dem Mitglied nur aktivierte L&auml;ndercodes zur Auswahl angeboten.");
                break;
 
-       case "0.3.4": // SQL queries for v0.3.4
+       case '0.3.4': // SQL queries for v0.3.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Auf Grund der Integration der neue Erweiterung <strong>country</strong> in die Anmeldephase klappte die Anmeldung nicht. Die dazu n&uuml;tige Verkn&uuml;pfung ist nun eingebaut und die Anmeldung klappt wieder. Vielen Dank nochmals an den Bug-Reporter (Fehlermelder)!");
                break;
 
-       case "0.3.5": // SQL queries for v0.3.5
+       case '0.3.5': // SQL queries for v0.3.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Design wird nach Anmeldung auch endlich im Mitgliedsmen&uuml; &uuml;bernommen.");
                break;
 
-       case "0.3.6": // SQL queries for v0.3.6
+       case '0.3.6': // SQL queries for v0.3.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlermeldung <strong>Fatal error: Call to undefined function: get_theme() in /../../guest/what-register.php on line 190</strong> beseitigt.");
                break;
 
-       case "0.3.7": // SQL queries for v0.3.7
+       case '0.3.7': // SQL queries for v0.3.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlermeldung <strong>Fatal error: Call to undefined function: get_curr_theme<u>e</u>() in /../../guest/what-register.php on line 190</strong> beseitigt.");
                break;
 
-       case "0.3.8": // SQL queries for v0.3.8
+       case '0.3.8': // SQL queries for v0.3.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Weitere SQL-Befehle abgesichert.");
                break;
 
-       case "0.3.9": // SQL queries for v0.3.9
+       case '0.3.9': // SQL queries for v0.3.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.4.0": // SQL queries for v0.4.0
+       case '0.4.0': // SQL queries for v0.4.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.4.1": // SQL queries for v0.4.1
+       case '0.4.1': // SQL queries for v0.4.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Vorbereitung auf die neue Mediendaten v0.0.4.");
                break;
 
-       case "0.4.2": // SQL queries for v0.4.2
+       case '0.4.2': // SQL queries for v0.4.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD register_default ENUM('Y','N') NOT NULL DEFAULT 'N'");
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `what`='config_register2' WHERE `what`='config_reg' LIMIT 1");
 
@@ -268,62 +268,62 @@ PRIMARY KEY(id)
                EXT_SET_UPDATE_NOTES("Bei der Anmeldung kann die Standart-Auswahl zwischen Ja/Nein umgeschaltet werden. Das &Auml;ndern des Templates <strong>templates/".GET_LANGUAGE()."/html/guest/guest_register.tpl</strong> ist nicht mehr n&ouml;tig.");
                break;
 
-       case "0.4.3": // SQL queries for v0.4.3
+       case '0.4.3': // SQL queries for v0.4.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Parser-Error in <strong>inc/modules/guest/what-register.php</strong> beseitigt.");
                break;
 
-       case "0.4.4": // SQL queries for v0.4.4
+       case '0.4.4': // SQL queries for v0.4.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Anmeldefehler (EMail-Adresse war immer ein Ausrufezeichen) beseitigt.");
                break;
 
-       case "0.4.5": // SQL queries for v0.4.5
+       case '0.4.5': // SQL queries for v0.4.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("if-Anweisungen auf Funktion <strong>empty()</strong> umgestellt.");
                break;
 
-       case "0.4.6": // SQL queries for v0.4.6
+       case '0.4.6': // SQL queries for v0.4.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Einstellung nach {!POINTS!}-Einstellungen verlagert.");
                break;
 
-       case "0.4.7": // SQL queries for v0.4.7
+       case '0.4.7': // SQL queries for v0.4.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("<strong>set_session()</strong> mit @-Zeichen gegen ungewollte Ausgaben abgesichert.");
                break;
 
-       case "0.4.8": // SQL queries for v0.4.8
+       case '0.4.8': // SQL queries for v0.4.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Hash-Erstellung von <strong>md5()</strong> auf bessere Funktion <strong>generateHash()</strong> umgestellt.");
                break;
 
-       case "0.4.9": // SQL queries for v0.4.9
+       case '0.4.9': // SQL queries for v0.4.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit nicht anzeigbaren Kategorien in der Anmeldung beseitigt.");
                break;
 
-       case "0.5.0": // SQL queries for v0.5.0
+       case '0.5.0': // SQL queries for v0.5.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlermeldung <em><strong>Fatal error:</strong> Call to undefined function REGISTER_ADD_CATEGORY_TABLE() in <strong>{!PATH!}/inc/modules/guest/what-register.php</strong> on line <strong>434</strong></em> beseitigt.");
                break;
 
-       case "0.5.1": // SQL queries for v0.5.1
+       case '0.5.1': // SQL queries for v0.5.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mail-Template <strong>register-member.tpl</strong> gefixt. Danke an <a href=\"http://forum.mxchange.org/profile-59.html\" target=\"_blank\" title=\"Mitgliedsprofil aufrufen\">wliepe</a> f&uuml;r die Fehlerfindung!");
                break;
 
-       case "0.5.2": // SQL queries for v0.5.2
+       case '0.5.2': // SQL queries for v0.5.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 283a521ddd9586793ef39be606cc9faae85d6d68..44e548f90a3e767e273a754e3d865465385b1347 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.1");
+EXT_SET_VERSION('0.0.1');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `removeip_anon_ip` ENUM('Y','N') NOT NULL DEFAULT 'Y'");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `removeip_anon_host` ENUM('Y','N') NOT NULL DEFAULT 'Y'");
@@ -64,7 +64,7 @@ case "register": // Do stuff when installation is running (modules.php?module=ad
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_removeip','Anonymit&auml;t/Privatsph&auml;hre','Stellen Sie hier ein, ob die IP-Nummer, User-Agent und/oder Referer-Adresse anonymisiert im gesamten Script verwendet werden soll.',15)");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_removeip'");
 
@@ -72,20 +72,20 @@ case "remove": // Do stuff when removing extension
        UNREGISTER_FILTER('post_youhere_line', 'ADD_ANONYMITY_NOTICE', true, $dry_run);
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update depends on sql_patches
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Add filters
                REGISTER_FILTER('post_youhere_line', 'ADD_ANONYMITY_NOTICE', false, true, $dry_run);
@@ -96,10 +96,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 20e2ef1d5ca9d6b3e35fa927125d4cf7f798018e..baf881cac302a599618a2a80985c8fdeaaab0616 100644 (file)
@@ -43,38 +43,38 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.1.5");
+EXT_SET_VERSION('0.1.5');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.1", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`sort`,`descr`) VALUES ('repair', NULL, 'Reperaturen','7','Repariert u.a. die Kategorie-Auswahlen der Mitglieder usw.')");
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`sort`,`descr`) VALUES ('repair','repair_cats','Kategorieauswahlen','1','Repariert die Kategorieauswahlen Ihrer Mitglieder.')");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `action`='repair'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.1": // SQL queries for v0.1
+       case '0.1.0': // SQL queries for v0.1
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`sort`,`descr`) VALUES ('repair','repair_amenu','Admin-Men&uuml;', 2, 'Repariert die Gewichtung des Admin-Men&uuml;-Systems')");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`sort`,`descr`) VALUES ('repair','repair_gmenu','Gast-Men&uuml;', 3, 'Repariert die Gewichtung des G&auml;ste-Men&uuml;-Systems')");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`sort`,`descr`) VALUES ('repair','repair_mmenu','Mitglied-Men&uuml;', 4, 'Repariert die Gewichtung des Mitglieder-Men&uuml;-Systems')");
@@ -83,37 +83,37 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("F&uuml;gt ein Men&uuml;punkt zur Reperatur der Gewichtung des Admin-Men&uuml;s hinzu.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Dummy-Release im Intranet??? Hmmmm....");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ung&uuml;tiges Update nach neuster Konvention (Erweiterung <strong>menu</strong> ist ung&uum;ltig).");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates und SQL-Anweisungen abgesichert.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 3af6cb2f37d41e546e7619e6d3900a593fa073f2..d24d4daf295dc800239c8d1e088e0f7c89e21d4c 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.1.3");
+EXT_SET_VERSION('0.1.3');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // Check if mod_rewrite is loadeded
        if (!IF_APACHE_MODULE_LOADED('mod_rewrite')){
                EXT_SET_REPORTS_FAILURE(true);
@@ -61,12 +61,12 @@ case "register": // Do stuff when installation is running (modules.php?module=ad
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_rewrite'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // Check if mod_rewrite is loadeded
        if (!IF_APACHE_MODULE_LOADED('mod_rewrite')) {
                SQL_QUERY("UPDATE `{!_MYSQL_PREFIX!}_extensions` SET ext_active='N' WHERE ext_name='rewrite' LIMIT 1", __FILE__, __LINE__);
@@ -78,53 +78,53 @@ case "activate": // Do stuff when admin activates this extension
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Folgende Linkvariablen werden nun auch ausgetauscht: bid, mid, url, page, offset");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Folgende Linkvariablen werden nun auch ausgetauscht: type, do=search");
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
-               EXT_SET_UPDATE_NOTES("URLs zu MXChange.org (".SERVER_URL.") sind nun auch wieder g&uuml;ltig.");
+               EXT_SET_UPDATE_NOTES("URLs zu MXChange.org ({!SERVER_URL!}) sind nun auch wieder g&uuml;ltig.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Folgende Linkvariablen werden nun auch ausgetausch: sub, home");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Links im Admin- und Mitgliedsbereich werden nicht mehr umgeschrieben. Entsprechend f&auml;llt die neue .htaccess-Datei kleiner aus. Bitte anpassen!");
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Links im Frametester-Modul werden nicht mehr umgeschrieben.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD rewrite_skip VARCHAR(255) NOT NULL DEFAULT 'login:admin:frametester:mailid'");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_rewrite','Rewrite-Engine','Stellen Sie hier ein, welche Module &uuml;bersprungen werden sollen, in denen also kein Umschreiben des HTML-Codes stattfinden soll.', 8)");
 
@@ -132,21 +132,21 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Zu &uuml;berspringende Module k&ouml;nnen per Admin-Bereich eingestellt werden.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates und SQL-Anweisungen abgesichert.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
-       case "0.1.3":
+       case '0.1.3':
                // Check if mod_rewrite is loadeded
                if (!IF_APACHE_MODULE_LOADED('mod_rewrite')){
                        EXT_SET_REPORTS_FAILURE(true);
@@ -157,10 +157,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 0ae1498f85819b75fdf52957b41cb946cb490165..7b090f1948296d1a4ed206ebca77a5dd6091e8e9 100644 (file)
@@ -44,33 +44,33 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("");
 
                // Update notes (these will be set as task text!)
@@ -79,10 +79,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 7ff4c6dd33828fea88c8c8081e817842ddd4295d..d6d925a6b58caeba1aa4ff44cf60b38ce633218e 100644 (file)
@@ -42,19 +42,19 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        //
        // SQL commands to run
        //
        // Try to make it depend on repair
-       EXT_ADD_UPDATE_DEPENDS("repair");
+       EXT_ADD_UPDATE_DEPENDS('repair');
 
        //
        // Sponsor data
@@ -369,7 +369,7 @@ PRIMARY KEY(id)
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD sponsor_min_points FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 1000.00000");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_sponsor_data`");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_sponsor_orders`");
@@ -388,7 +388,7 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `what`='sponsor'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='Y', `locked`='N' WHERE `action`='sponsor' LIMIT 4");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='sponsor' LIMIT 1");
@@ -396,7 +396,7 @@ case "activate": // Do stuff when admin activates this extension
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_sponsor_registry` SET is_active='Y' WHERE is_active='N'");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='N', `locked`='Y' WHERE `action`='sponsor' LIMIT 4");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='sponsor' LIMIT 1");
@@ -404,10 +404,10 @@ case "deactivate": // Do stuff when admin deactivates this extension
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_sponsor_registry` SET is_active='N' WHERE is_active='Y'");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("");
 
                // Update notes (these will be set as task text!)
@@ -416,10 +416,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index adfdd0f16462339bf7c49bd00061323b36ebef29..06798822b1a9bd869bafacd3c51221c031114554 100644 (file)
@@ -43,19 +43,19 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.6.2");
+EXT_SET_VERSION('0.6.2');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9", "0.3.0", "0.3.1", "0.3.2", "0.3.3", "0.3.4", "0.3.5", "0.3.6", "0.3.7", "0.3.8", "0.3.9", "0.4.0", "0.4.1", "0.4.2", "0.4.3", "0.4.4", "0.4.5", "0.4.6", "0.4.7", "0.4.8", "0.4.9", "0.5.0", "0.5.1", "0.5.2", "0.5.3", "0.5.4", "0.5.5", "0.5.6", "0.5.7", "0.5.8", "0.5.9", "0.6.0", "0.6.1", "0.6.2"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9', '0.4.0', '0.4.1', '0.4.2', '0.4.3', '0.4.4', '0.4.5', '0.4.6', '0.4.7', '0.4.8', '0.4.9', '0.5.0', '0.5.1', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6', '0.5.7', '0.5.8', '0.5.9', '0.6.0', '0.6.1', '0.6.2'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // Drop tables
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_admin_menu_las`");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_admin_menu_las_data`");
@@ -120,20 +120,20 @@ case "remove": // Do stuff when removing extension
        */
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD ext_autopurge ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_extensions','Erweitungsmanagement','Alle Einstellungen am Erweiterungsmanagement.', 10)");
 
@@ -141,28 +141,28 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Es kann nun bestimmt werden, ob vom Server gel&ouml;schte ext-xxx.php erkannt werden sollen und die verkn&uuml;pften Daten auch aus der Datenbank entfernt werden sollen.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` CHANGE auto_purge auto_purge BIGINT(20) UNSIGNED NOT NULL DEFAULT ".(getConfig('one_day')*14)."");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("In der Tabelle <strong>{!_MYSQL_PREFIX!}_config</strong> musste die Spalte <strong>auto_purge</strong> (autom. L&ouml;schen von Best&auml;tigungsmails angepasst werden (war auf dem Testsystem auf TINYINT(4) gesetzt.)");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD points_word VARCHAR(255) NOT NULL DEFAULT 'Punkte'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Das Wort &quot;Punkte&quot; kann nun per Datenbank ge&auml;ndert werden. Damit k&ouml;nnen Sie anstelle des Wortes Punkte auch Klammlose oder &euro; schreiben.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD mails_page BIGINT(20) UNSIGNED NOT NULL DEFAULT 10");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Anzahl Mails pro Seite in <strong>EMail-Details ansehen</strong> und <strong>EMail-Archiv</strong> hinzugef&uuml;gt.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD index_home VARCHAR(255) NOT NULL DEFAULT 'welcome'");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_home','Home-Seite festlegen','Stellen Sie hier ein, welcher Men&uuml;punkt (what-welcome ist Standart) als Einstiegspunkt in das Men&uuml;system genutzt werden soll.', 5)");
 
@@ -170,42 +170,42 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Die what-welcome.php ist derzeit die &quot;Home&quot;-Seite (Eingangsseite). Dies kann nun per Datenbank ge&auml;ndert werden.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_extensions` ADD ext_has_css ENUM('Y','N') NOT NULL DEFAULT 'N'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Es k&ouml;nnen nun SQL-Updates von einander abh&auml;ngig gemacht werden und die CSS-Datei kann per Admin-Bereich (wegen Debuggings) ein- bzw. ausgeschaltet werden.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD verbose_sql ENUM('Y','N') NOT NULL DEFAULT 'Y'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Die SQL-Anweisungen werden bei eingeschalteter Verbose-Funktion detailiert angezeigt.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD menu_blur_spacer VARCHAR(255) NOT NULL DEFAULT '&nbsp;<strong><big>&middot;</big></strong>&nbsp;'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Nette Mouse-Hover-Effekte eingebaut (Anleitung <strong>MENUE_HOVER.txt</strong> zum Patchen der general.css bitte lesen!)");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','list_unconfirmed','Unbest. Mails auflisten','Schauen Sie sich hier unbest&auml;tigte Maillinks an. Bitte diesen Link nur &uuml;ber dem EMail-Archiv oder EMail-Details aufrufen, direkt aufgerufen bekommen Sie eine Fehlermeldung.', 8)");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Unbest&auml;tigte Maillinks k&ouml;nnen unter Email-Management -&gt; Unbest. Mails auflisten aufgelistet werden.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD reg_points_mode ENUM('ref','direct') NOT NULL DEFAULT 'ref'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Soll der einmalige Ref-Bonus &uuml;ber das Referal-System (also alle oberen Refs bekommen auch etwas davon ab) oder direkt dem Werber aufgebucht werden?");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `title`='Home-/Eingangsseite', descr='Stellen Sie hier ein, welcher Men&uuml;punkt (what-welcome ist Standart) als Einstiegspunkt in das Men&uuml;system genutzt werden soll und wie die automatische Weiterleitung in der Eingangsseite funktionieren soll.' WHERE `what`='config_home' LIMIT 1");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD index_delay TINYINT(3) UNSIGNED NOT NULL DEFAULT 0");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD index_cookie BIGINT(20) UNSIGNED NOT NULL DEFAULT ".(getConfig('one_day')*365)."");
@@ -214,7 +214,7 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Sie k&ouml;nnen nun <a href=\"{!URL!}/modules.php?module=admin&amp;`what`=config_home\">hier</a> die Verz&ouml;gerungszeit in der <a href=\"{!URL!}/index.php\">Eingangsseite</a> einstellen.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_refid','Standart-Ref-ID','Stellen Sie hier die User-ID ein, die genommen werden soll, wenn der Gast n icht per Referal-Link Ihren Mailtausch aufgerufen hat.', 7)");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD def_refid BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
 
@@ -222,26 +222,26 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Standart Referal-ID kann per Admin-Bereich eingestellt werden (war vorher nur in modules.php und index.php direkt eingebbar.)");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD refid_target ENUM('register','index') NOT NULL DEFAULT 'register'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Auf welche Seite soll der Ref-Link zeigen? Eingangsseite oder Anmeldeformular?");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ung&uuml;ltiges Update (nach ext-theme.php verschoben!).");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_extensions` DROP ext_has_admin");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Spalte <u>ext_has_admin</u> aus der Tabelle <u>{!_MYSQL_PREFIX!}_extensions</u> entfernt, da sie keinen Sinn mehr macht.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD enable_title_deco ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD title_left VARCHAR(10) NOT NULL DEFAULT '[--'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD title_middle VARCHAR(10) NOT NULL DEFAULT '-'");
@@ -254,22 +254,22 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Dekorationen des Seitentiteles lassen sich ein- und ausschalten und selber definieren; Modul-Titel und Titel der <strong>what</strong>-Dateien kann hinzugef&uuml;gt werden.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("mad_count und last_mad werden nun aus der Datenbank geladen");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_jackpot` CHANGE points points FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 0.00000");
 
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_payments` CHANGE payment payment FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 0.00000");
@@ -279,19 +279,19 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("5 Nachkommastellen implementiert");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD css_php ENUM('DIRECT','FILE') NOT NULL DEFAULT 'FILE'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ausgabe der CSS-Dateien entweder per css.php oder sie sind direkt eingebunden.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erweiterung bleibt wegen integrierten Schalters immer aktiv.");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD guest_menu ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD member_menu ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD youre_here ENUM('Y','N') NOT NULL DEFAULT 'Y'");
@@ -300,7 +300,7 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Gast- und Mitgliedsmen&uuml;s lassen sich getrennt voneinander abschalten.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                $auto_type = "png"; // PNG image is the default
                if ((INCLUDE_READABLE("theme/".GET_CURR_THEME()."/images/code_bg.jpg")) && function_exists('imagecreatefromjpeg')) {
                        // Switch to JPEG format
@@ -312,19 +312,19 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Generierung des Mailbest&auml;tigungscodes h&auml;ngt davon ab, ob die PHP-Funktion <u>imagecreatefromjpeg()</u> und das JPEG-Bild vorhanden sind oder nicht.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Spalten <u>max_mails</u> und <u>receive_mails</u> auf BIGINT(20) gesetzt.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('user','sub_points','{!POINTS!} abziehen','Allen oder einem Mitglied {!POINTS!} abziehen.', 8)");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abzug von {!POINTS!} nun m&ouml;glich.");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD stats_limit BIGINT(20) UNSIGNED NOT NULL DEFAULT 10");
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `what`='config_stats' WHERE `what`='stats' LIMIT 1");
 
@@ -335,12 +335,12 @@ case "update": // Update an extension
 </ol>");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Nicht mehr g&uuml;ltiges Update.");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD mt_word VARCHAR(255) NOT NULL DEFAULT 'Mailtausch'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD mt_word2 VARCHAR(255) NOT NULL DEFAULT 'Mailtausches'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD mt_word3 VARCHAR(255) NOT NULL DEFAULT 'Mailtauscher'");
@@ -349,7 +349,7 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.3.0": // SQL queries for v0.3.0
+       case '0.3.0': // SQL queries for v0.3.0
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `title`='{!POINTS!}/Referal-Ebenen' WHERE `what`='config_points' LIMIT 1");
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `title`='Mailverg&uuml;tungen...' WHERE `what`='payments' LIMIT 1");
 
@@ -357,7 +357,7 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Zwei Men&uuml;punkte umbenannt.");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_extensions` ADD UNIQUE KEY (ext_name)");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_admins` ADD UNIQUE KEY (login)");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_refbanner` ADD INDEX (visible)");
@@ -389,7 +389,7 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Eindeutige Schl&uuml;ssel (UNIQUE KEY) und normale Schl&uuml;ssel (INDEX) gesetzt.");
                break;
 
-       case "0.3.2": // SQL queries for v0.3.2
+       case '0.3.2': // SQL queries for v0.3.2
                // Connection table between the menu system and the "logical area" system
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_admin_menu_las`");
                ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_admin_menu_las` (
@@ -425,7 +425,7 @@ PRIMARY KEY(id)
                EXT_SET_UPDATE_NOTES("Logische Bereiche (Logical Areas = LAs) eingef&uuml;hrt. Dadurch wird das immer st&auml;rker anwachsende Admin-Men&uuml; in grosse Hauptgruppen unterteilt, wodurch ein Auffinden von Men&uuml;punkten verbessert wird.");
                break;
 
-       case "0.3.3": // SQL queries for v0.3.3
+       case '0.3.3': // SQL queries for v0.3.3
                // Switch of the "intelligent menu sorter" when you want to have a fixed menu structure...
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD admin_menu_sorter ENUM('Y','N') NOT NULL DEFAULT 'Y'");
 
@@ -444,12 +444,12 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Admin-abh&auml;ngig werden nun Klicks im Admin-Men&uuml; gez&auml;hlt, die zur automatischen Anpassung des Men&uuml;s in den logischen Bereichen diennen. Dieses &quot;intelligente Unbauen&quot; k&ouml;nnen Sie auch ganz abschalten.");
                break;
 
-       case "0.3.4": // SQL queries for v0.3.4
+       case '0.3.4': // SQL queries for v0.3.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Veraltetes Update (what=list_user&amp;mode=noref)");
                break;
 
-       case "0.3.5": // SQL queries for v0.3.5
+       case '0.3.5': // SQL queries for v0.3.5
                // List accounts with no referal
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('stats',NULL,'Statistiken',4,'Y','N')");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('stats','stats2','Framekiller-Mails',2,'Y','N')");
@@ -463,7 +463,7 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Mitgliedsmen&uuml; komplett umgebaut.");
                break;
 
-       case "0.3.6": // SQL queries for v0.3.6
+       case '0.3.6': // SQL queries for v0.3.6
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD salt_length TINYINT(3) UNSIGNED NOT NULL DEFAULT '9'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD pass_scramble VARCHAR(255) NOT NULL DEFAULT ''");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_admins` MODIFY password VARCHAR(255) NOT NULL DEFAULT ''");
@@ -478,11 +478,11 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Passwort-System mit Zufallshash erweitert (Schutzt gegen Dictionary-Attacks!)");
                break;
 
-       case "0.3.7": // SQL queries for v0.3.7
+       case '0.3.7': // SQL queries for v0.3.7
                EXT_SET_UPDATE_NOTES("Problem w&auml;hrend des Installationsvorganges behoben.");
                break;
 
-       case "0.3.8": // SQL queries for v0.3.8
+       case '0.3.8': // SQL queries for v0.3.8
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_admin_menu` CHANGE descr descr MEDIUMTEXT NULL");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_pool` CHANGE `text` `text` LONGTEXT NOT NULL");
 
@@ -490,7 +490,7 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Beschreibungstexte f&uuml;r Admin-Men&uuml;s k&ouml;nnen l&auml;nger sein. Diverse Fixes.");
                break;
 
-       case "0.3.9": // SQL queries for v0.3.9
+       case '0.3.9': // SQL queries for v0.3.9
                ADD_EXT_SQL("UPDATE  `{!_MYSQL_PREFIX!}_admin_menu` SET title = REPLACE(title, '--POINTS--','!POINTS!') WHERE title LIKE '%--POINTS--%'");
                ADD_EXT_SQL("UPDATE  `{!_MYSQL_PREFIX!}_admin_menu` SET descr = REPLACE(descr, '--POINTS--','!POINTS!') WHERE descr LIKE '%--POINTS--%'");
                ADD_EXT_SQL("UPDATE  `{!_MYSQL_PREFIX!}_guest_menu` SET title = REPLACE(title, '--POINTS--','!POINTS!') WHERE title LIKE '%--POINTS--%'");
@@ -500,26 +500,26 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Beschreibungstexte f&uuml;r Admin-Men&uuml;s k&ouml;nnen l&auml;nger sein. Diverse Fixes.");
                break;
 
-       case "0.4.0": // SQL queries for v0.4.0
+       case '0.4.0': // SQL queries for v0.4.0
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET title = 'Email-Management' WHERE action = 'email' AND (`what`='' OR `what` IS NULL) LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Email-Verwaltung nach Email-Management umbenannt.");
                break;
 
-       case "0.4.1": // SQL queries for v0.4.1
+       case '0.4.1': // SQL queries for v0.4.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `show_timings` ENUM ('Y','N') NOT NULL DEFAULT 'Y'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Tabellen-Schl&uuml;ssel neu gesetzt und Parsing-Zeit im Footer eingeblendet.");
                break;
 
-       case "0.4.2": // SQL queries for v0.4.2
+       case '0.4.2': // SQL queries for v0.4.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Nicht mehr g&uuml;ltiges Update.");
                break;
 
-       case "0.4.3": // SQL queries for v0.4.3
+       case '0.4.3': // SQL queries for v0.4.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `proxy_host` VARCHAR(255) NOT NULL DEFAULT ''");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `proxy_port` INT(5) UNSIGNED NOT NULL DEFAULT 0");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `proxy_username` VARCHAR(255) NOT NULL DEFAULT ''");
@@ -530,7 +530,7 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Proxy-Einstellungen hinzugef&uuml;gt.");
                break;
 
-       case "0.4.4": // SQL queries for v0.4.4
+       case '0.4.4': // SQL queries for v0.4.4
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_admin_menu` CHANGE `what` `what` VARCHAR(255) NULL DEFAULT NULL");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_guest_menu` CHANGE `what` `what` VARCHAR(255) NULL DEFAULT NULL");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_member_menu` CHANGE `what` `what` VARCHAR(255) NULL DEFAULT NULL");
@@ -549,7 +549,7 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Schl&uuml;ssel in Admin-, Gast- und Mitgliedsmen&uuml; verbessert.");
                break;
 
-       case "0.4.5": // SQL queries for v0.4.5
+       case '0.4.5': // SQL queries for v0.4.5
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD last_month CHAR(2) NOT NULL DEFAULT '00'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD last_week CHAR(2) NOT NULL DEFAULT '00'");
 
@@ -557,29 +557,29 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("T&auml;glichen/w&ouml;chentlichen/monatlichen Reset verbessert.");
                break;
 
-       case "0.4.6": // SQL queries for v0.4.6
+       case '0.4.6': // SQL queries for v0.4.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Nicht mehr g&uuml;ltiges Update.");
                break;
 
-       case "0.4.7": // SQL queries for v0.4.7
+       case '0.4.7': // SQL queries for v0.4.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Veraltetes Update.");
                break;
 
-       case "0.4.8": // SQL queries for v0.4.8
+       case '0.4.8': // SQL queries for v0.4.8
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_task_system` ADD INDEX (subject)");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Index f&uuml;r Betreff eingef&uuml;gt.");
                break;
 
-       case "0.4.9": // SQL queries for v0.4.9
+       case '0.4.9': // SQL queries for v0.4.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Nicht mehr g&uuml;ltiges Update.");
                break;
 
-       case "0.5.0": // SQL queries for v0.5.0
+       case '0.5.0': // SQL queries for v0.5.0
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_refsystem` DROP INDEX `level`");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_refsystem` DROP INDEX `userid`");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_refsystem` ADD UNIQUE `userid_level` (`userid`,`level`)");
@@ -588,21 +588,21 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Referal-System unterst&uuml;tzt nun detailierte Referal-&Uuml;bersicht und vieles mehr.");
                break;
 
-       case "0.5.1": // SQL queries for v0.5.1
+       case '0.5.1': // SQL queries for v0.5.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_member_menu` DROP `descr`");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Beschreibungsspalte von Mitgliedsmen&uuml; entfernt, welche ohnehin nicht genutzt wird.");
                break;
 
-       case "0.5.2": // SQL queries for v0.5.2
+       case '0.5.2': // SQL queries for v0.5.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_refdepths` CHANGE `percents` `percents` FLOAT(8,5) UNSIGNED NOT NULL DEFAULT 0.00000");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Prozents&aum;tze k&ouml;nnen nun f&uuml;nf Stelle hinter dem Komma sein.");
                break;
 
-       case "0.5.3": // SQL queries for v0.5.3
+       case '0.5.3': // SQL queries for v0.5.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD session_save_path VARCHAR(255) NOT NULL DEFAULT ''");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_session','Session-Einstellungen','&Auml;ndern Sie hier den Speicherpfad f&uuml;r Sessiondateien (Sitzungsdateien) ab, falls die Standart-Einstellung bei Ihrem Hoster zu Problem f&uuml;hren sollte.', 16)");
 
@@ -610,43 +610,43 @@ PRIMARY KEY (id)
                EXT_SET_UPDATE_NOTES("Session-Speicherpfad konfigurierbar. Beispielsweise ist dies bei all-inkl.com n&ouml;tig.");
                break;
 
-       case "0.5.4": // SQL queries for v0.5.4
+       case '0.5.4': // SQL queries for v0.5.4
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','reflist','Ref-&Uuml;bersicht',5,'Y','N')");
 
                // Depends on refback extension
-               EXT_ADD_UPDATE_DEPENDS("refback");
+               EXT_ADD_UPDATE_DEPENDS('refback');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ref-&Uuml;bersicht eingebaut. Diese h&auml;ngt von der Erweiterung <strong>refback</strong> ab.");
                break;
 
-       case "0.5.5": // SQL queries for v0.5.5
+       case '0.5.5': // SQL queries for v0.5.5
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD show_points_unconfirmed ENUM('Y','N') NOT NULL DEFAULT 'Y'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Anzeige der {!POINTS!} unter den unbest&auml;tigten Mails kann nun optional abgeschaltet werden.");
                break;
 
-       case "0.5.6": // SQL queries for v0.5.6
+       case '0.5.6': // SQL queries for v0.5.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Nicht mehr g&uuml;ltiges Update.");
                break;
 
-       case "0.5.7": // SQL queries for v0.5.7
+       case '0.5.7': // SQL queries for v0.5.7
                ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='list_norefs' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Auflistung der Mitglieder ohne Werber nach what=list_user&amp;mode=norefs verschoben.");
                break;
 
-       case "0.5.8": // SQL queries for v0.5.8
+       case '0.5.8': // SQL queries for v0.5.8
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_extensions` DROP `ext_lang_file`");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sprachdateinamen werden nicht mehr in der Datenbank behalten.");
                break;
 
-       case "0.5.9": // SQL queries for v0.5.9
+       case '0.5.9': // SQL queries for v0.5.9
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_filters`");
                ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_filters` (
 `filter_id` BIGINT(20) UNSIGNED AUTO_INCREMENT,
@@ -662,21 +662,21 @@ PRIMARY KEY (`filter_id`)
                EXT_SET_UPDATE_NOTES("Tabellen f&uuml;r Filter-System hinzugef&uuml;gt.");
                break;
 
-       case "0.6.0": // SQL queries for v0.6.0
+       case '0.6.0': // SQL queries for v0.6.0
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `update_filter_usage` ENUM('N','Y') NOT NULL DEFAULT 'N'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Benutzungsstatistik eingebaut. Das Z&auml;hlen der Filterverwendungen sollte <strong>ausschliesslich</strong> zu Debugging-Zwecken eingesetzt werden.");
                break;
 
-       case "0.6.1": // SQL queries for v0.6.1
+       case '0.6.1': // SQL queries for v0.6.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Nicht mehr g&uuml;ltiges Update.");
                break;
 
-       case "0.6.2": // SQL queries for v0.6.2
+       case '0.6.2': // SQL queries for v0.6.2
                // Depends on refback extension
-               EXT_ADD_UPDATE_DEPENDS("user");
+               EXT_ADD_UPDATE_DEPENDS('user');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abh&auml;ngigkeit von <u>ext-user</u> gesetzt.");
@@ -684,17 +684,17 @@ PRIMARY KEY (`filter_id`)
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
        // When the sql_patches is not installed we cannot load it's configuration... *sigh*
-       if (GET_EXT_VERSION("sql_patches") != '') {
+       if (GET_EXT_VERSION('sql_patches') != '') {
                // Init key
-               setConfigEntry('secret_key', "");
+               setConfigEntry('secret_key', '');
 
                // Read key from secret file
                if ((getConfig('file_hash') == "") || (getConfig('master_salt') == "") || (getConfig('pass_scramble') == "")) {
@@ -703,7 +703,7 @@ default: // Do stuff when extension is loaded
                        LOAD_INC_ONCE("inc/gen_sql_patches.php");
 
                        // @TODO Rewrite this to a filter!
-                       if ((GET_EXT_VERSION("cache") >= "0.1.2") && (isCacheInstanceValid())) {
+                       if ((GET_EXT_VERSION('cache') >= '0.1.2') && (isCacheInstanceValid())) {
                                // Remove extensions and mod_reg cache file
                                LOAD_INC_ONCE("inc/libs/cache_functions.php");
                                require(sprintf("%sinc/extensions/ext-cache.php", constant('PATH')));
@@ -721,7 +721,7 @@ default: // Do stuff when extension is loaded
                                setConfigEntry('secret_key', READ_FILE($hashFile));
                        } else {
                                // Remove it from database
-                               UPDATE_CONFIG("file_hash", "");
+                               UPDATE_CONFIG("file_hash", '');
 
                                // Cannot read secret file!
                                app_die(__FILE__, __LINE__, "Cannot read secret file! Please try to reload");
index 093c2cfc212bb409853507b947cab57310c9becf..3788b0fe102b2443be53a6dc80ead3d01a98ed24 100644 (file)
@@ -43,97 +43,97 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.1.2");
+EXT_SET_VERSION('0.1.2');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlende Abfrage im Mitlieder-Modul, on Erweiterung auch aktiviert ist.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("IP-Nummer und Browserbezeichnung wird in Admin-Mails eingesetzt.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Dateiamenskonflikt zwischen den Erweiterungen <strong>support</strong> und <strong>order</strong> behoben.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate vom 27.08.2005.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern der Support-Anfrage repariert und Mail wird an Mitglied wieder versendet.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index d9a4535db450eda58d038c52016d3731f80819cc..25da0e013f8d37b6d0130ba9d98feda64fa17d7b 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run (surfbar URLs)
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_surfbar_urls`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_surfbar_urls` (
@@ -193,7 +193,7 @@ UNIQUE KEY `status_action` (`status`,`action`)
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('surfbar','list_surfbar_actions','Mitgliederaktionen','Listet alle Mitgliederaktionen auf.',6)");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_surfbar_actions`");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_surfbar_locks`");
@@ -204,21 +204,21 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `action`='surfbar'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `action`='surfbar' LIMIT 5");
-       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', hidden='N', admin_only='N', mem_only='Y' WHERE `module`='surfbar' LIMIT 1");
+       ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', `hidden`='N', `admin_only`='N', `mem_only`='Y' WHERE `module`='surfbar' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `action` = 'surfbar' LIMIT 5");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='Y' WHERE `module`='surfbar' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER) {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("");
 
                // Update notes (these will be set as task text!)
@@ -227,10 +227,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 72eff411242e2c33d7aa281b2e94e46c735e7ef9..8581cf6a53effaaedcae99c7fbb0321a77fbfa84 100644 (file)
@@ -43,114 +43,114 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.3.2");
+EXT_SET_VERSION('0.3.2');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9", "0.3.0", "0.3.1", "0.3.2"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`sort`,`descr`) VALUES ('task', NULL, 'Aufgaben-Management','1','Erweitertes Aufgaben-Management zur leichten verwaltung der vom System erzeugten Aufgaben.')");
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`sort`,`descr`) VALUES ('task','list_task','Aufgaben auflisten','1','Alle Ihnen zugewiesenen Aufgaben auflisten (keine Updates).')");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_task_system` SET `status`='SOLVED' WHERE `status`='CLOSED'");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `action`='task'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_extensions` SET ext_has_css='Y' WHERE ext_name='task' AND ext_has_css='N' LIMIT 1");
 
                // This update depends on sql_patches update!
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("CSS-Datei kann per Admin-Bereich ein- und ausgeschaltet werden.");
                break;
 
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Unn&ouml;tige Script-Teile aus what-list_tasks.php herausgel&ouml;scht; beim Anzeigen einer Extension-Update, oder -Register Aufgabe werden bei eingeschaltetem Verbose-Modus alle SQL-Anweisungen aufgelistet.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler <div class=\"admin_failed\">Warning: Missing argument 2 for create_timestamp_from_selections() in {!PATH!}inc/libs/pro_functions.php on line 227</div> behoben.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("&amp;admin= in &amp;amp;admin= umgewandelt.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wegen des Theme-Supportes hat sich die URL zur CSS-Datei ge&auml;ndert.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erstellung der Extra-&Uuml;bersichten verbessert.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler bei Abfrage der payout-Erweiterung beseitigt.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Task-Liste ausgelagert als Template");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Design &quot;Solid-Business&quot; eingebaut.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link zum Mitgliedsprofil in Funktion <u>ADMIN_USER_PROFILE_LINK()</u> ausgelagert.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Links wegen <strong>what=admins_contct</strong> ge&auml;ndert.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Weitere Direkt-Links eingebaut:<br />
 <ul>
@@ -162,84 +162,84 @@ case "update": // Update an extension
 </ul>");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Direkt Links zum Sponsorenbereich vorbereitend eingebaut.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Es werden alle installierten und aktivierten Themes angezeigt und verlinkt.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("CSS-Datei in general.css verschmolzen (Patch 435!)");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Alle Administratoren, Referal-Banner und aktivierte Referal-Banner werden nun eingeblendet.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit &uuml;berlanger Textbreite beseitigt.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link zum Freischalten von Sponoren-Accounts korregiert.");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sortierungsreihenfolge grundlegend ge&auml;ndert: Es wird jetzt nach Mitglieder-ID, Aufgabenbereich, Infos und nach dem Erstellunsdatum sortiert.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("<strong>Nur mit bonus v0.6.9 oder h&ouml;her:</strong> Zuschaltbare Bonis werden auch bei der Ermittlung Anzahl teilnehmender Mitglieder mit ber&uumk;cksichtigt.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Teilnehmer der Bettel-Rallye werden angezeigt.");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link zum direkten Aufheben einer Urlaubsschaltung eines Mitgliedes korregiert.");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("if-Anweisungen auf Funktion <strong>empty()</strong> umgestellt. Update-Aufgaben werden nach &quot;Bearbeitung&quot; nicht mehr als <strong>Erledigt</strong> gesetzt. Dies hatte sonst den Anschein, die Update-Aufgaben m&uuml;ssten erledigt werden, um die Erweiterungs-Updates einzuspielen, was aber automatisch geschieht.");
                break;
 
-       case "0.3.0": // SQL queries for v0.3.0
+       case '0.3.0': // SQL queries for v0.3.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Export-Accounts werden in Task-&Uuml;bersicht aufgelistet.");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Diverse Fixes an den Templates (Notice-Hinweise vom PHP-Interpreter entfernt).");
                break;
 
-       case "0.3.2": // SQL queries for v0.3.2
+       case '0.3.2': // SQL queries for v0.3.2
                // This update depends on user update
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("H&auml;ngt nun von <u>ext-user</u> ab.");
@@ -247,10 +247,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 21c0b0c08cf0d42e1702e6e42de379a16616dbf4..9ba001ca64c815935f23ff99bab898d04370dfdc 100644 (file)
@@ -43,18 +43,18 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0.8");
+EXT_SET_VERSION('0.0.8');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // Drop theme table
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_themes`");
 
@@ -68,55 +68,55 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE `action`='themes' OR `what`='themes'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code f&uuml;r ein Zeilen-Template ausgelagert.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Im Men&uuml;punkt &quot;Pr&uuml;fen&quot; wurden die bereits installierten und auch aktuellen Themes nicht ausgeblendet.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("<strong>set_session()</strong> mit @-Zeichen gegen ungewollte Ausgaben abgesichert.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Variablen-Handling skriptglobal ge&auml;ndert.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ung&uuml;ltiges Update.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Theme table
                ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_themes`");
                ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_themes` (
@@ -154,10 +154,10 @@ INDEX (`theme_active`)
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index c64c944dd883d535e45e24b1580cf55c80714a42..5874c1e8e54a3f2cbe61aa6e4679f2d4f1d8e8f4 100644 (file)
@@ -43,105 +43,105 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.1.2");
+EXT_SET_VERSION('0.1.2');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_guest_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES ('main','top10','TOP-10','Y','Y', 7)");
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_top10','TOP-10 Listen','Stellen Sie hier ein, wie lang die TOP-Listen sein sollen, also wie viele Pl&auml;tze angezeigt werden sollen.', 8)");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD top10_max TINYINT(3) UNSIGNED NOT NULL DEFAULT 10");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_guest_menu` WHERE `what`='top10'");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='config_top10'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='Y', `locked`='N' WHERE `what`='top10' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='N', `locked`='Y' WHERE `what`='top10' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler <em>Column: 'userid' in group statement is ambiguous</em> im Gastbereich beseitigt.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wegen des Theme-Supportes hat sich die URL zur CSS-Datei ge&auml;ndert.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Im Gastbereich konnte als Nicht-Admin die Seite nicht ge&ouml;ffnet werden.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Design &quot;Solid-Business&quot; eingebaut.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Rechtschreibefehler beseitigt.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates und SQL-Anweisungen abgesichert.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index c0dacf5590ea3849458ae9ac0747e21ed64df060..0633931c085f3b1e3f415b5d20d243c0d6104828 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.2.9");
+EXT_SET_VERSION('0.2.9');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4", "0.0.5", "0.0.6", "0.0.7", "0.0.8", "0.0.9", "0.1.0", "0.1.1", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running
+case 'register': // Do stuff when installation is running
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_transfers_in`");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_transfers_out`");
@@ -103,7 +103,7 @@ PRIMARY KEY(id)
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD opt_in ENUM('Y','N') NOT NULL DEFAULT 'N'");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_transfers_in`");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_transfers_out`");
@@ -112,180 +112,180 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` DROP `opt_in`");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='transfer' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='transfer' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler <div class=\"admin_failed\">Warning: Missing argument 2 for create_timestamp_from_selections() in {!PATH!}inc/libs/pro_functions.php on line 227</div> behoben.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("&Uuml;berfl&uuml;ssige unset()-Anweisungen aus der what-config_transfer.php entfernt. Dies wird bereits von der eigenen Funktion ADMIN_SAVE_SETTINGS() erledigt.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlende Abfrage im Mitlieder-Modul, on Erweiterung auch aktiviert ist.");
                break;
 
-       case "0.0.5": // SQL queries for v0.0.5
+       case '0.0.5': // SQL queries for v0.0.5
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD ap_transfer ENUM('Y','N') NOT NULL DEFAULT 'Y'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link <em>Auflisten</em> im Admin-Bereich hatte das eingeloggte Mitglied und nicht den eingeloggten Admin abgefragt. Automatisches L&ouml;schen von veraltete Eintr&auml;gen kann unabh&auml;ngig von der autopurge-Erweiterung de-/aktiviert werden. Bitte aktualisieren Sie auch die beiden Admin-Templates!");
                break;
 
-       case "0.0.6": // SQL queries for v0.0.6
+       case '0.0.6': // SQL queries for v0.0.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wegen des Theme-Supportes hat sich die URL zur CSS-Datei ge&auml;ndert.");
                break;
 
-       case "0.0.7": // SQL queries for v0.0.7
+       case '0.0.7': // SQL queries for v0.0.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.0.8": // SQL queries for v0.0.8
+       case '0.0.8': // SQL queries for v0.0.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit E in Transaktionsnummer beseitigt.");
                break;
 
-       case "0.0.9": // SQL queries for v0.0.9
+       case '0.0.9': // SQL queries for v0.0.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Problem mit Speicherung der Einstellungen beseitigt.");
                break;
 
-       case "0.1.0": // SQL queries for v0.2.1
+       case '0.1.0': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Men&uuml;punkte im Gast-/Mitgliedsbereich k&ouml;nnen nicht mehr aufgerufen werden, wenn die Erweiterung deaktiviert ist.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Design &quot;Solid-Business&quot; eingebaut.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("IP-Nummer und Browserbezeichnung wird in Admin-Mails eingesetzt.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link zum Mitgliedsprofil in Funktion <u>ADMIN_USER_PROFILE_LINK()</u> ausgelagert.");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Template <u>admin_config_transfer_pro.tpl</u> ist &uuml;berfl&uuml;ssig geworden. Bitte l&ouml;schen Sie dies!");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Wort <strong>Punkte</strong> dynamisiert.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("HTML-Code ausgelagert in Templates und SQL-Anweisungen abgesichert.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Parser-Error im Mitgliedsbereich beseitigt.");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Durchf&uuml;hrung des Transfers korregiert.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu_las` (la_id, la_action, la_what) VALUES ('member', '', 'list_transfer')");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu_las` (la_id, la_action, la_what) VALUES ('member', '', 'del_transfer')");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu_las` (la_id, la_action, la_what) VALUES ('config', '', 'config_transfer')");
 
                // Depends on sql_patches (or you have to execute these both SQL statements by phpMyAdmin
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erweiterung in's neue Men&uuml;system integriert.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("<strong>Touring-Code wiederholen</strong> nach <strong>Touring-Code eingeben</strong> hin ge&auml;ndert.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `action`='extras', `sort`='5' WHERE `what`='transfer' LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mitgliedsmen&uuml; komplett ge&auml;ndert.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Hash-Erstellung von <strong>md5()</strong> auf bessere Funktion <strong>generateHash()</strong> umgestellt.");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Die {!POINTS!} k&ouml;nnen nun wieder wie gewohnt transferiert werden. Der Grund f&uuml;r <em>{--TRANSFER_INVALID_PASSWORD--}</em> war, dass der Cookie-Hash ein anderer ist, als der in der Datenbank... :-/");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlermeldung <em>Notice: Undefined index: to_uid in {!PATH!}/inc/modules/member/what-transfer.php on line 301</em> gefixt. Danke an <a href=\"http://forum.mxchange.org/profile-8.html\" target=\"_blank\" title=\"Forumprofil von Piter01\">Piter01</a>.");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehlerhinweis bei deaktivierter Erweiterung verbessert.");
                break;
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
-       if ((isResetModeEnabled()) && (getConfig('ap_transfer') == "Y")) {
+       if ((isResetModeEnabled()) && (getConfig('ap_transfer') == 'Y')) {
                // Automatically remove outdated or not displayed transactions
                TRANSFER_AUTPPURGE(getConfig('transfer_max'), getConfig('transfer_age'));
        }
index d65a3f2029bbd9bbb59a18daead2b44048f79cbf..6867111ea5d96e8d402cf36d1208025ca9f760f7 100644 (file)
@@ -8,7 +8,7 @@
  * -------------------------------------------------------------------- *
  * Short description : Helper extension for usage directory             *
  * -------------------------------------------------------------------- *
- * Kurzbeschreibung  : Helfer-Erweiterung fuer das "usage" Verzeichnis  *
+ * Kurzbeschreibung  : Helfer-Erweiterung fuer das 'usage' Verzeichnis  *
  * -------------------------------------------------------------------- *
  * $Revision::                                                        $ *
  * $Date::                                                            $ *
@@ -43,36 +43,36 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('stats','usage','Aufrufstatistik','Erkennt automatisch Ihre Aufrufstatisiken und bindet diese in das Admin-Interface ein. (Derzeit nur Webalizer!)',9)");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `usage_base` VARCHAR(255) NOT NULL DEFAULT 'usage'");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what`='usage'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("");
 
                // Update notes (these will be set as task text!)
@@ -81,10 +81,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index ba552a65969e7ff7f5d99a1851998d19e09e210a..f2d8ab6f60c0cf04b9860ac8bb5f50a01bb963e0 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.3.5");
+EXT_SET_VERSION('0.3.5');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.1", "0.1.1", "0.1.2", "0.1.2", "0.1.3", "0.1.4", "0.1.5", "0.1.6", "0.1.7", "0.1.8", "0.1.9", "0.2.0", "0.2.1", "0.2.2", "0.2.3", "0.2.4", "0.2.5", "0.2.6", "0.2.7", "0.2.8", "0.2.9", "0.3.0", "0.3.1", "0.3.2", "0.3.3", "0.3.4", "0.3.5"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.1.0', '0.1.1', '0.1.2', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_cats`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_user_cats` (
   `id` BIGINT(22) NOT NULL AUTO_INCREMENT,
@@ -170,7 +170,7 @@ INDEX (`stats_type`)
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('user','list_cats','Kategorien anzeigen','Listet die ausgew&auml;hlten Kategorien eines Mitgliedes auf.',9)");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what` IN('config_user','user_contct','list_user_del') OR `action`='user'");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_del`");
@@ -182,84 +182,84 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_stats_data`");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.1": // SQL queries for v0.1
+       case '0.1.0': // SQL queries for v0.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `user_limit` INT(7) UNSIGNED NOT NULL DEFAULT 20");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seitenweises Anzeigen der User-Liste ist nun m&ouml;glich.");
                break;
 
-       case "0.1.1": // SQL queries for v0.1.1
+       case '0.1.1': // SQL queries for v0.1.1
                // This update depends on sql_patches update!
-               EXT_ADD_UPDATE_DEPENDS("sql_patches");
+               EXT_ADD_UPDATE_DEPENDS('sql_patches');
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Ung&uuml;ltiges Update.");
                break;
 
-       case "0.1.2": // SQL queries for v0.1.2
+       case '0.1.2': // SQL queries for v0.1.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD `mails_confirmed` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Dem Mitglied wird nun angezeigt, wie viele Mails er best&auml;tigt hat. Alle vor dieser Version best. Mails werden leider nicht mehr ber&uuml;cksichtigt! Bitte teilen Sie dies Ihren Mitgliedern mit.");
                break;
 
-       case "0.1.3": // SQL queries for v0.1.3
+       case '0.1.3': // SQL queries for v0.1.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Den Pfad <em>Sie sind hier</em> im Men&uuml;punkt <u>Online-Liste</u> erweitert.");
                break;
 
-       case "0.1.4": // SQL queries for v0.1.4
+       case '0.1.4': // SQL queries for v0.1.4
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD `emails_received` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Anzahl empfangener Mails wird angezeigt. <big>Diese Anzeige kann fehlerhaft sein, wenn Sie bereits Mitglieder in Ihrem {!MT_WORD!} haben sollen!</big>");
                break;
 
-       case "0.1.5": // SQL queries for v0.1.5
+       case '0.1.5': // SQL queries for v0.1.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.6": // SQL queries for v0.1.6
+       case '0.1.6': // SQL queries for v0.1.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
                break;
 
-       case "0.1.7": // SQL queries for v0.1.7
+       case '0.1.7': // SQL queries for v0.1.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Erweiterung bleibt wegen integrierten Schalters immer aktiv.");
                break;
 
-       case "0.1.8": // SQL queries for v0.1.8
+       case '0.1.8': // SQL queries for v0.1.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Seit <a href=\"#\">Patch 340</a> &uuml;berfl&uuml;ssige HTML-Tags entfernt.");
                break;
 
-       case "0.1.9": // SQL queries for v0.1.9
+       case '0.1.9': // SQL queries for v0.1.9
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Link zum Mitgliedsprofil in Funktion <u>ADMIN_USER_PROFILE_LINK()</u> ausgelagert.");
                break;
 
-       case "0.2.0": // SQL queries for v0.2.0
+       case '0.2.0': // SQL queries for v0.2.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("User-Liste ausgelagert in Templates und &uuml;berbreite Zeile in 2er-Zeile umgewandelt.");
                break;
 
-       case "0.2.1": // SQL queries for v0.2.1
+       case '0.2.1': // SQL queries for v0.2.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `user_alpha` TINYINT(3) UNSIGNED NOT NULL DEFAULT 10");
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_user','Mitgliederliste','Anzahl Mitglieder pro Seite, Anzahl Buchstaben pro Zeile usw.', 8)");
 
@@ -267,73 +267,73 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("User-Liste ist konfigurierbar: Anzahl Mitglieder pro Seite und Anzahl Buchstaben pro Zeile; Template-Fehler beseitigt.");
                break;
 
-       case "0.2.2": // SQL queries for v0.2.2
+       case '0.2.2': // SQL queries for v0.2.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` CHANGE `gender` `gender` ENUM('M','F','C') NOT NULL DEFAULT 'M'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Anrede &quot;Firma&quot; hinzugef&uuml;gt.");
                break;
 
-       case "0.2.3": // SQL queries for v0.2.3
+       case '0.2.3': // SQL queries for v0.2.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Datumsformat festgelegt auf ausf&uuml;hrlich.");
                break;
 
-       case "0.2.4": // SQL queries for v0.2.4
+       case '0.2.4': // SQL queries for v0.2.4
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("W&ouml;rter <strong>Mailtausch</strong>, <strong>Mailtausches</strong> und <strong>Mailtauscher</strong> sind austauschbar.");
                break;
 
-       case "0.2.5": // SQL queries for v0.2.5
+       case '0.2.5': // SQL queries for v0.2.5
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("SQL-Anweisungen abgesichert.");
                break;
 
-       case "0.2.6": // SQL queries for v0.2.6
+       case '0.2.6': // SQL queries for v0.2.6
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Abspeichern von Einstellungen repariert.");
                break;
 
-       case "0.2.7": // SQL queries for v0.2.7
+       case '0.2.7': // SQL queries for v0.2.7
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Sicherheitsupdate f&uuml;r die Include-Befehle.");
                break;
 
-       case "0.2.8": // SQL queries for v0.2.8
+       case '0.2.8': // SQL queries for v0.2.8
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("if-Anweisungen auf Funktion <strong>empty()</strong> umgestellt.");
                break;
 
-       case "0.2.9": // SQL queries for v0.2.9
+       case '0.2.9': // SQL queries for v0.2.9
                ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('user','user_contct','Mitglied kontaktieren','Kontaktieren Sie hier Ihre Mitglieder ganz direkt &uuml;ber ein Webformular. Sie brauchen somit kein EMail-Programm mehr starten!', 8)");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Admin-Kontaktformular hinzugef&uuml;gt.");
                break;
 
-       case "0.3.0": // SQL queries for v0.3.0
+       case '0.3.0': // SQL queries for v0.3.0
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Hash-Erstellung von <strong>md5()</strong> auf bessere Funktion <strong>generateHash()</strong> umgestellt.<br />Diverse Fixes f&uuml;r <em>0.2.1-Beta1</em> Release.");
                break;
 
-       case "0.3.1": // SQL queries for v0.3.1
+       case '0.3.1': // SQL queries for v0.3.1
                ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `title` = 'Mitglieder-Management' WHERE `action`='user' AND (`what`='' OR `what` IS NULL) LIMIT 1");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Verwaltung auf Management umgestellt");
                break;
 
-       case "0.3.2": // SQL queries for v0.3.2
+       case '0.3.2': // SQL queries for v0.3.2
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("PHP-Hinweis in Userauflistung gefixt (trat bei fehlender nickname-Erweiterung auf) und Darstellungsfehler von <strong>0.00000</strong> unbest&auml;tigten Mails gefixt.");
                break;
 
-       case "0.3.3": // SQL queries for v0.3.3
+       case '0.3.3': // SQL queries for v0.3.3
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Mitglieder sind nun per Formular kontaktierbar (es wird eine EMail versendet), gesperrte und best&auml;tigte Mitglieder-Accounts sind seperat oder gemeinsam auflistbar (seperat nur mit der Erweiterung <em>task</em>!)");
                break;
 
-       case "0.3.4": // SQL queries for v0.3.4
+       case '0.3.4': // SQL queries for v0.3.4
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `select_user_zero_refid` ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `user_min_confirmed` SMALLINT(5) UNSIGNED NOT NULL DEFAULT 10");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD `rand_confirmed` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
@@ -342,7 +342,7 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Mitglieder werden per Zufall als Referal-ID ausgew&auml;hlt, die eine Mindestanzahl an best&auml;tigten Mails haben, wenn die Ref-Id 0 ist.");
                break;
 
-       case "0.3.5": // SQL queries for v0.3.5
+       case '0.3.5': // SQL queries for v0.3.5
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD `lock_reason` TINYTEXT");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` ADD `lock_timestamp` TIMESTAMP NOT NULL DEFAULT '0000-00-00 00:00'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `user_delete_purge` BIGINT(20) UNSIGNED NOT NULL DEFAULT ".(getConfig('one_day') * 30)."");
@@ -368,10 +368,10 @@ PRIMARY KEY(`id`)
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index a87848c046cdc962a27ef3f595616e18e3fc8e9e..7fdd4b9ce82f3f0b701df4cf5d5b87662cdad579 100644 (file)
@@ -38,14 +38,14 @@ if (!defined('__SECURITY')) {
 }
 
 // Version of this extension
-EXT_SET_VERSION("0.0.4");
+EXT_SET_VERSION('0.0.4');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0", "0.0.1", "0.0.2", "0.0.3", "0.0.4"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4'));
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_wernis`");
        ADD_EXT_SQL("CREATE TABLE `{!_MYSQL_PREFIX!}_user_wernis` (
@@ -83,7 +83,7 @@ PRIMARY KEY(id)
        ADD_EXT_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_guest_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES ('main','wernis_portal','WDS66-News','N','N', 7)");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_user_wernis`");
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `action`='wernis'");
@@ -91,22 +91,22 @@ case "remove": // Do stuff when removing extension
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_guest_menu` WHERE `what`='wernis_portal'");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='Y', `locked`='N' WHERE `what`='wernis_portal' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='wernis' LIMIT 1");
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='N', `locked`='Y' WHERE `what`='wernis_portal' LIMIT 1");
        ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='N', `locked`='Y' WHERE `what`='wernis' LIMIT 1");
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD wernis_payout_active ENUM ('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD wernis_withdraw_active ENUM ('Y','N') NOT NULL DEFAULT 'Y'");
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD wernis_payout_factor FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 1.00000");
@@ -120,21 +120,21 @@ case "update": // Update an extension
                EXT_SET_UPDATE_NOTES("Ein-/Auszahlungsfunktion getrennt ein- und ausschaltbar, sowie mit Umrechungsfaktoren {!POINTS!}-&gt;Wernis versehen. Prozentualer Abzug als &quot;Betreibergeb&uuml;hr hinzugef&uuml;gt, was z.B. f&uuml;r Wechselstuben interessant ist.");
                break;
 
-       case "0.0.2": // SQL queries for v0.0.2
+       case '0.0.2': // SQL queries for v0.0.2
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD wernis_pass_md5 VARCHAR(32) NOT NULL DEFAULT ''");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Auszahlunsfunktion an die neue API 0.2-BETA angepasst. Demnach muss Ihr Wernis-Passwort beim Auszahlen benutzt werden und in Ihrem {!MT_WORD!} als MD5-Hash gespeichert werden.");
                break;
 
-       case "0.0.3": // SQL queries for v0.0.3
+       case '0.0.3': // SQL queries for v0.0.3
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` CHANGE `wernis_refid` `wernis_refid` INT(5) UNSIGNED ZEROFILL NOT NULL DEFAULT '00000'");
 
                // Update notes (these will be set as task text!)
                EXT_SET_UPDATE_NOTES("Spaltentyp von VARCHAR(6) auf BIGINT(5) ge&auml;ndert.");
                break;
 
-       case "0.0.4": // SQL queries for v0.0.4
+       case '0.0.4': // SQL queries for v0.0.4
                ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `wernis_refid` INT(5) UNSIGNED ZEROFILL NOT NULL DEFAULT '00000'");
 
                // Update notes (these will be set as task text!)
@@ -143,10 +143,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index 3dccf5fae5029695d2072440d8e0578a29984fcb..e2f6d71616fd23da636e200125b26e96d39b9c54 100644 (file)
@@ -44,17 +44,17 @@ if (!defined('__SECURITY')) {
 }
 
 // Version number
-EXT_SET_VERSION("0.0");
+EXT_SET_VERSION('0.0');
 
-// Version history array (add more with , "0.1" and so on)
-EXT_SET_VER_HISTORY(array("0.0"));
+// Version history array (add more with , '0.1.0' and so on)
+EXT_SET_VER_HISTORY(array('0.0'));
 
 // This extension is deprecated!
 // Only since 'network' is ready! EXT_SET_DEPRECATED("Y");
 
 switch ($EXT_LOAD_MODE)
 {
-case "register": // Do stuff when installation is running (modules.php?module=admin&action=login is called)
+case 'register': // Do stuff when installation is running (modules.php?module=admin&action=login is called)
        // SQL commands to run
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `yoomedia_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
        ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_config` ADD `yoomedia_sid` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
@@ -84,24 +84,24 @@ UNIQUE `y_type` (`type`,`y_id`)
 ) TYPE={!_TABLE_TYPE!} COMMENT='Reload lock reminder for Yoo!Media campaigns'");
        break;
 
-case "remove": // Do stuff when removing extension
+case 'remove': // Do stuff when removing extension
        // SQL commands to run
        ADD_EXT_SQL("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE `what` IN('config_yoomedia','list_yoomedia_tm')");
        ADD_EXT_SQL("DROP TABLE IF EXISTS `{!_MYSQL_PREFIX!}_yoomedia_reload`");
        break;
 
-case "activate": // Do stuff when admin activates this extension
+case 'activate': // Do stuff when admin activates this extension
        // SQL commands to run
        break;
 
-case "deactivate": // Do stuff when admin deactivates this extension
+case 'deactivate': // Do stuff when admin deactivates this extension
        // SQL commands to run
        break;
 
-case "update": // Update an extension
+case 'update': // Update an extension
        switch ($EXT_VER)
        {
-       case "0.0.1": // SQL queries for v0.0.1
+       case '0.0.1': // SQL queries for v0.0.1
                ADD_EXT_SQL("");
 
                // Update notes (these will be set as task text!)
@@ -110,10 +110,10 @@ case "update": // Update an extension
        }
        break;
 
-case "modify": // When the extension got modified
+case 'modify': // When the extension got modified
        break;
 
-case "test": // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
+case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
        break;
 
 default: // Do stuff when extension is loaded
index f1f1ee7001299bccb74f02555bee6e1d010e5390..88f5c509a5c3112e65ac8f3823f8a69a25f76485 100644 (file)
@@ -47,10 +47,10 @@ if (getTotalFatalErrors() > 0) {
        LOAD_TEMPLATE("fatal_header");
 
        // Set unset variable
-       if (empty($check)) $check = "";
+       if (empty($check)) $check = '';
        if ((isInstalling()) || (!isInstalled())) {
                // While we are installing ouput other header than while it is installed... :-)
-               $OUT = "";
+               $OUT = '';
                foreach (getFatalArray() as $key => $value) {
                        // Prepare content for the template
                        $content = array(
@@ -66,7 +66,7 @@ if (getTotalFatalErrors() > 0) {
                LOAD_TEMPLATE("install_fatal_table", false, $OUT);
        } elseif (isInstalled()) {
                // Display all runtime fatal errors
-               $OUT = "";
+               $OUT = '';
                foreach (getFatalArray() as $key => $value) {
                        // Prepare content for the template
                        $content = array(
index 80e45043c371f3cf75eb6e0a291d9d11a58ba38a..b98a265a72c202bb21470e0eecd13b8e81c26367 100644 (file)
@@ -66,10 +66,10 @@ function INIT_FILTER_SYSTEM () {
        $GLOBALS['filters']['counter'] = array();
 
        // Load all saved filers if sql_patches is updated
-       if (GET_EXT_VERSION("sql_patches") >= "0.5.9") {
+       if (GET_EXT_VERSION('sql_patches') >= '0.5.9') {
                // Init add
-               $add = "";
-               if (GET_EXT_VERSION("sql_patches") >= "0.6.0") $add = ", `filter_counter`";
+               $add = '';
+               if (GET_EXT_VERSION('sql_patches') >= '0.6.0') $add = ", `filter_counter`";
 
                // Load all active filers
                $result = SQL_QUERY("SELECT `filter_name`,`filter_function`,`filter_active`".$add."
@@ -213,7 +213,7 @@ function runFilterChain ($filterName, $data = null, $silentAbort = true) {
                //* DEBUG: */ echo __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>): name={$filterName},func={$filterFunction},active={$active}<br />\n";
 
                // Is the filter active?
-               if ($active == "Y") {
+               if ($active == 'Y') {
                        // Is this filter there?
                        if (!function_exists($filterFunction)) {
                                // Unregister it
@@ -258,7 +258,7 @@ function FILTER_FLUSH_FILTERS () {
        } // END - if
 
        // Is the extension sql_patches updated?
-       if (EXT_VERSION_IS_OLDER("sql_patches", "0.5.9")) {
+       if (EXT_VERSION_IS_OLDER('sql_patches', '0.5.9')) {
                // Abort silently here
                return false;
        } // END - if
@@ -306,7 +306,7 @@ function FILTER_FLUSH_FILTERS () {
        } // END - if
 
        // Shall we update usage counters (ONLY FOR DEBUGGING!)
-       if (getConfig('update_filter_usage') == "Y") {
+       if (getConfig('update_filter_usage') == 'Y') {
                // Update all counters
                foreach ($GLOBALS['filters']['counter'] as $filterName => $filterArray) {
                        // Walk through all filters
@@ -332,7 +332,7 @@ function FILTER_CALL_HANDLER_LOGIN_FAILTURES ($data) {
 
        // Handle failed logins here if not in guest
        //* DEBUG: */ print __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>):type={$data['type']},action={$GLOBALS['action']},what={$GLOBALS['what']},lvl={$data['access_level']}<br />\n";
-       if ((($data['type'] == "what") || ($data['type'] == "action") && ((!isset($GLOBALS['what'])) || ($GLOBALS['what'] == "overview") || ($GLOBALS['what'] == getConfig('index_home')))) && ($data['access_level'] != "guest") && ((GET_EXT_VERSION("sql_patches") >= "0.4.7") || (GET_EXT_VERSION("admins") >= "0.7.0"))) {
+       if ((($data['type'] == "what") || ($data['type'] == "action") && ((!isset($GLOBALS['what'])) || ($GLOBALS['what'] == "overview") || ($GLOBALS['what'] == getConfig('index_home')))) && ($data['access_level'] != 'guest') && ((GET_EXT_VERSION('sql_patches') >= '0.4.7') || (GET_EXT_VERSION('admins') >= '0.7.0'))) {
                // Handle failure
                $content['content'] .= HANDLE_LOGIN_FAILTURES($data['access_level']);
        } // END - if
@@ -359,7 +359,7 @@ function FILTER_REDIRECT_TO_LOGOUT_SQL_PATCHES () {
 // Filter for auto-activation of a extension
 function FILTER_AUTO_ACTIVATE_EXTENSION ($data) {
        // Is this extension always activated?
-       if (EXT_GET_ALWAYS_ACTIVE() == "Y") {
+       if (EXT_GET_ALWAYS_ACTIVE() == 'Y') {
                // Then activate the extension
                //* DEBUG: */ echo __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>): ext_name={$data['ext_name']}<br />\n";
                ACTIVATE_EXTENSION($data['ext_name']);
@@ -502,12 +502,12 @@ function FILTER_CHECK_ADMIN_ACL () {
        $ret = true;
 
        // Ok, Cookie-Update done
-       if (GET_EXT_VERSION("admins") >= "0.3") {
+       if (GET_EXT_VERSION('admins') >= '0.3.0') {
                // Check if action GET variable was set
                $action = SQL_ESCAPE($GLOBALS['action']);
                if (!empty($GLOBALS['what'])) {
                        // Get action value by what-value
-                       $action = GET_ACTION("admin", $GLOBALS['what']);
+                       $action = GET_ACTION('admin', $GLOBALS['what']);
                } // END - if
 
                // Check for access control line of current menu entry
index 3e945565b563eb051675d2279940429084c61120..1fbee0b05f92c1b8f486d2a4f4f4be91018b93a2 100644 (file)
@@ -65,7 +65,7 @@ if ((((!isset($GLOBALS['footer_sent'])) || (($GLOBALS['footer_sent'] != "1") &&
        } // END - if
 
        // Shall we display the parsing time and number of queries?
-       if ((GET_EXT_VERSION("sql_patches") >= "0.4.1") && (getConfig('show_timings') == "Y") && (!REQUEST_ISSET_GET(('frame'))) && ($GLOBALS['header_sent'] == "2")) {
+       if ((GET_EXT_VERSION('sql_patches') >= '0.4.1') && (getConfig('show_timings') == 'Y') && (!REQUEST_ISSET_GET(('frame'))) && ($GLOBALS['header_sent'] == "2")) {
                // Then display it here
                DISPLAY_PARSING_TIME_FOOTER();
        } // END - if
index 178dfb30eb0acc64556cafe05851e5ba03d3b7dc..e5a3be66f846d15ca8b2c5668c048ead30873d70 100644 (file)
@@ -70,7 +70,7 @@ function OUTPUT_HTML ($HTML, $newLine = true) {
 
                case "direct":
                        // If we are switching from render to direct output rendered code
-                       if ((!empty($OUTPUT)) && (constant('_OB_CACHING') != "on")) { OUTPUT_RAW($OUTPUT); $OUTPUT = ""; }
+                       if ((!empty($OUTPUT)) && (constant('_OB_CACHING') != "on")) { OUTPUT_RAW($OUTPUT); $OUTPUT = ''; }
 
                        // The same as above... ^
                        OUTPUT_RAW($HTML);
@@ -114,15 +114,15 @@ function OUTPUT_HTML ($HTML, $newLine = true) {
                header("Pragma: no-cache"); // HTTP/1.0
                header("Connection: Close");
 
-               // Extension "rewrite" installed?
-               if ((EXT_IS_ACTIVE("rewrite")) && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
+               // Extension 'rewrite' installed?
+               if ((EXT_IS_ACTIVE('rewrite')) && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
                        $OUTPUT = REWRITE_LINKS($OUTPUT);
                } // END - if
 
                // Compile and run finished rendered HTML code
                while (strpos($OUTPUT, '{!') > 0) {
                        // Prepare the content and eval() it...
-                       $newContent = "";
+                       $newContent = '';
                        $eval = "\$newContent = \"".COMPILE_CODE(smartAddSlashes($OUTPUT))."\";";
                        eval($eval);
 
@@ -138,7 +138,7 @@ function OUTPUT_HTML ($HTML, $newLine = true) {
                OUTPUT_RAW($OUTPUT);
        } elseif ((constant('OUTPUT_MODE') == "render") && (!empty($OUTPUT))) {
                // Rewrite links when rewrite extension is active
-               if ((EXT_IS_ACTIVE("rewrite")) && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
+               if ((EXT_IS_ACTIVE('rewrite')) && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
                        $OUTPUT = REWRITE_LINKS($OUTPUT);
                } // END - if
 
@@ -176,7 +176,7 @@ function getFatalArray () {
 }
 
 // Add a fatal error message to the queue array
-function addFatalMessage ($F, $L, $message, $extra="") {
+function addFatalMessage ($F, $L, $message, $extra='') {
        debug_report_bug($message);
        if (is_array($extra)) {
                // Multiple extras for a message with masks
@@ -228,7 +228,7 @@ function LOAD_TEMPLATE ($template, $return=false, $content=array()) {
        $HTTP_USER_AGENT = GET_USER_AGENT();
 
        // Init some data
-       $ret = "";
+       $ret = '';
        if (empty($GLOBALS['refid'])) $GLOBALS['refid'] = 0;
 
        // @DEPRECATED Try to rewrite the if() condition
@@ -264,7 +264,7 @@ function LOAD_TEMPLATE ($template, $return=false, $content=array()) {
 
        // Base directory
        $BASE = sprintf("%stemplates/%s/html/", constant('PATH'), GET_LANGUAGE());
-       $MODE = "";
+       $MODE = '';
 
        // Check for admin/guest/member templates
        if (strpos($template, "admin_") > -1) {
@@ -330,7 +330,7 @@ function LOAD_TEMPLATE ($template, $return=false, $content=array()) {
                while (strpos($tmpl_file, "'") !== false) { $tmpl_file = str_replace("'", '{QUOT}', $tmpl_file); }
 
                // Do we have to compile the code?
-               $ret = "";
+               $ret = '';
                if ((strpos($tmpl_file, "\$") !== false) || (strpos($tmpl_file, '{--') !== false) || (strpos($tmpl_file, '--}') > 0)) {
                        // Okay, compile it!
                        $tmpl_file = "\$ret=\"".COMPILE_CODE(smartAddSlashes($tmpl_file))."\";";
@@ -449,13 +449,13 @@ To      : ".$toEmail."
 Subject : ".$subject."
 Message : ".$message."
 </pre>\n");
-       } elseif (($HTML == "Y") && (EXT_IS_ACTIVE("html_mail"))) {
+       } elseif (($HTML == 'Y') && (EXT_IS_ACTIVE('html_mail'))) {
                // Send mail as HTML away
                SEND_HTML_EMAIL($toEmail, $subject, $message, $mailHeader);
        } elseif (!empty($toEmail)) {
                // Send Mail away
                SEND_RAW_EMAIL($toEmail, $subject, $message, $mailHeader);
-       } elseif ($HTML == "N") {
+       } elseif ($HTML == 'N') {
                // Problem found!
                SEND_RAW_EMAIL(constant('WEBMASTER'), "[PROBLEM:]".$subject, $message, $mailHeader);
        }
@@ -495,7 +495,7 @@ function SEND_RAW_EMAIL ($toEmail, $subject, $msg, $from) {
                }
                $mail->FromName   = constant('MAIN_TITLE');
                $mail->Subject    = $subject;
-               if ((EXT_IS_ACTIVE("html_mail")) && (strip_tags($msg) != $msg)) {
+               if ((EXT_IS_ACTIVE('html_mail')) && (strip_tags($msg) != $msg)) {
                        $mail->Body       = $msg;
                        $mail->AltBody    = "Your mail program required HTML support to read this mail!";
                        $mail->WordWrap   = 70;
@@ -503,7 +503,7 @@ function SEND_RAW_EMAIL ($toEmail, $subject, $msg, $from) {
                } else {
                        $mail->Body       = decodeEntities($msg);
                }
-               $mail->AddAddress($toEmail, "");
+               $mail->AddAddress($toEmail, '');
                $mail->AddReplyTo(constant('WEBMASTER'), constant('MAIN_TITLE'));
                $mail->AddCustomHeader("Errors-To:".constant('WEBMASTER'));
                $mail->AddCustomHeader("X-Loop:".constant('WEBMASTER'));
@@ -524,7 +524,7 @@ function GEN_PASS ($LEN = 0) {
        $ABC = explode(",", "a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z,0,1,2,3,4,5,6,7,8,9,-,+,_,/");
 
        // Start creating password
-       $PASS = "";
+       $PASS = '';
        for ($i = 0; $i < $LEN; $i++) {
                $PASS .= $ABC[mt_rand(0, count($ABC) -1)];
        } // END - for
@@ -701,7 +701,7 @@ function GET_LANGUAGE() {
        $ret = constant('DEFAULT_LANG');
 
        // Init variable
-       $lang = "";
+       $lang = '';
 
        // Is the variable set
        if (REQUEST_ISSET_GET(('mx_lang'))) {
@@ -745,7 +745,7 @@ function LOAD_EMAIL_TEMPLATE($template, $content=array(), $UID="0") {
        // Make sure all template names are lowercase!
        $template = strtolower($template);
 
-       // Default "nickname" if extension is not installed
+       // Default 'nickname' if extension is not installed
        $nick = "---";
 
        // Prepare IP number and User Agent
@@ -786,7 +786,7 @@ function LOAD_EMAIL_TEMPLATE($template, $content=array(), $UID="0") {
        //* DEBUG: */ print __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>):UID={$UID},template={$template},content[]=".gettype($content)."<br />\n";
        if (($UID > 0) && (is_array($content))) {
                // If nickname extension is installed, fetch nickname as well
-               if (EXT_IS_ACTIVE("nickname")) {
+               if (EXT_IS_ACTIVE('nickname')) {
                        //* DEBUG: */ print __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>):NICKNAME!<br />\n";
                        // Load nickname
                        $result = SQL_QUERY_ESC("SELECT surname, family, gender, email, nickname FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
@@ -848,7 +848,7 @@ function LOAD_EMAIL_TEMPLATE($template, $content=array(), $UID="0") {
        } // END - if
 
        // Now does the final template exists?
-       $newContent = "";
+       $newContent = '';
        if (FILE_READABLE($FQFN)) {
                // The local file does exists so we load it. :)
                $tmpl_file = READ_FILE($FQFN);
@@ -938,9 +938,9 @@ function LOAD_URL ($URL, $addUrlData=true) {
                header ("Location: ".str_replace("&amp;", "&", $URL));
        } else {
                // Output error message
-               LOAD_INC("inc/header.php");
+               LOAD_INC('inc/header.php');
                LOAD_TEMPLATE("redirect_url", false, str_replace("&amp;", "&", $URL));
-               LOAD_INC("inc/footer.php");
+               LOAD_INC('inc/footer.php');
        }
 
        // Shut the mailer down here
@@ -1099,7 +1099,7 @@ function array_pk_sort (&$array, $a_sort, $primary_key = 0, $order = -1, $nums =
 
 //
 function ADD_SELECTION ($type, $DEFAULT, $prefix="", $id="0") {
-       $OUT = "";
+       $OUT = '';
 
        if ($type == "yn") {
                // This is a yes/no selection only!
@@ -1135,7 +1135,7 @@ function ADD_SELECTION ($type, $DEFAULT, $prefix="", $id="0") {
                $YEAR = date('Y', time());
 
                // Use configured min age or fixed?
-               if (GET_EXT_VERSION("other") >= "0.2.1") {
+               if (GET_EXT_VERSION('other') >= '0.2.1') {
                        // Configured
                        $startYear = $YEAR - getConfig('min_age');
                } else {
@@ -1163,7 +1163,7 @@ function ADD_SELECTION ($type, $DEFAULT, $prefix="", $id="0") {
                        // Get current year and subtract the configured minimum age
                        $OUT .= "<option value=\"".($minYear - 1)."\">&lt;".$minYear."</option>\n";
                        // Calculate earliest year depending on extension version
-                       if (GET_EXT_VERSION("other") >= "0.2.1") {
+                       if (GET_EXT_VERSION('other') >= '0.2.1') {
                                // Use configured minimum age
                                $YEAR = date('Y', time()) - getConfig('min_age');
                        } else {
@@ -1201,9 +1201,9 @@ function ADD_SELECTION ($type, $DEFAULT, $prefix="", $id="0") {
 
        case "yn":
                $OUT .= "<option value=\"Y\"";
-               if ($DEFAULT == "Y") $OUT .= " selected=\"selected\"";
+               if ($DEFAULT == 'Y') $OUT .= " selected=\"selected\"";
                $OUT .= ">{--YES--}</option>\n<option value=\"N\"";
-               if ($DEFAULT == "N") $OUT .= " selected=\"selected\"";
+               if ($DEFAULT == 'N') $OUT .= " selected=\"selected\"";
                $OUT .= ">{--NO--}</option>\n";
                break;
        }
@@ -1216,8 +1216,8 @@ function TRANSLATE_YESNO ($yn) {
        // Default
        $translated = "??? (".$yn.")";
        switch ($yn) {
-               case "Y": $translated = getMessage('YES'); break;
-               case "N": $translated = getMessage('NO'); break;
+               case 'Y': $translated = getMessage('YES'); break;
+               case 'N': $translated = getMessage('NO'); break;
                default:
                        // Log unknown value
                        DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("Unknown value %s. Expected Y/N!", $yn));
@@ -1280,7 +1280,7 @@ function generateRandomCodde ($length, $code, $uid, $DATA="") {
        if ($len == 0) $len = 10;
 
        // Cut off requested counts of number
-       $return = substr(str_replace('.', "", $rcode), 0, $len);
+       $return = substr(str_replace('.', '', $rcode), 0, $len);
 
        // Done building code
        return $return;
@@ -1289,7 +1289,7 @@ function generateRandomCodde ($length, $code, $uid, $DATA="") {
 // Does only allow numbers
 function bigintval ($num, $castValue = true) {
        // Filter all numbers out
-       $ret = preg_replace("/[^0123456789]/", "", $num);
+       $ret = preg_replace("/[^0123456789]/", '', $num);
 
        // Shall we cast?
        if ($castValue) $ret = (double)$ret;
@@ -1610,7 +1610,7 @@ function SEND_ADMIN_EMAILS_PRO ($subj, $template, $content, $UID) {
                // "implode" IDs and query string
                $aid = implode(",", $adminIds);
                if ($aid == "-1") {
-                       if (EXT_IS_ACTIVE("events")) {
+                       if (EXT_IS_ACTIVE('events')) {
                                // Add line to user events
                                EVENTS_ADD_LINE($subj, $msg, $UID);
                        } else {
@@ -1644,8 +1644,8 @@ function SEND_ADMIN_EMAILS_PRO ($subj, $template, $content, $UID) {
 //
 function CREATE_FANCY_TIME ($stamp) {
        // Get data array with years/months/weeks/days/...
-       $data = CREATE_TIME_SELECTIONS($stamp, "", "", "", true);
-       $ret = "";
+       $data = CREATE_TIME_SELECTIONS($stamp, '', '', '', true);
+       $ret = '';
        foreach($data as $k => $v) {
                if ($v > 0) {
                        // Value is greater than 0 "eval" data to return string
@@ -1670,13 +1670,13 @@ function CREATE_FANCY_TIME ($stamp) {
 
 //
 function ADD_EMAIL_NAV ($PAGES, $offset, $show_form, $colspan, $return=false) {
-       $SEP = ""; $TOP = "";
+       $SEP = ''; $TOP = '';
        if (!$show_form) {
                $TOP = " top2";
                $SEP = "<tr><td colspan=\"".$colspan."\" class=\"seperator\">&nbsp;</td></tr>";
        }
 
-       $NAV = "";
+       $NAV = '';
        for ($page = 1; $page <= $PAGES; $page++) {
                // Is the page currently selected or shall we generate a link to it?
                if (($page == REQUEST_GET('page')) || ((!REQUEST_ISSET_GET(('page'))) && ($page == "1"))) {
@@ -1687,7 +1687,7 @@ function ADD_EMAIL_NAV ($PAGES, $offset, $show_form, $colspan, $return=false) {
                        $NAV .= "<a href=\"{!URL!}/modules.php?module=admin&amp;what=".$GLOBALS['what']."&amp;page=".$page."&amp;offset=".$offset;
 
                        // Add userid when we shall show all mails from a single member
-                       if ((REQUEST_ISSET_GET(('uid'))) && (bigintval(REQUEST_GET('uid')) > 0)) $NAV .= "&amp;uid=".bigintval(REQUEST_GET('uid'));
+                       if ((REQUEST_ISSET_GET('uid')) && (bigintval(REQUEST_GET('uid')) > 0)) $NAV .= "&amp;uid=".bigintval(REQUEST_GET('uid'));
 
                        // Close open anchor tag
                        $NAV .= "\">";
@@ -1740,7 +1740,7 @@ function EXTRACT_HOST (&$script) {
        } // END - if
 
        // Extract host name
-       $host = str_replace("http://", "", $url);
+       $host = str_replace("http://", '', $url);
        if (ereg("/", $host)) $host = substr($host, 0, strpos($host, "/"));
 
        // Generate relative URL
@@ -1794,7 +1794,7 @@ function POST_URL ($script, $postData) {
        if (!is_array($postData)) {
                // Abort here
                DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("postData is not an array. Type: %s", gettype($postData)));
-               return array("", "", "");
+               return array("", '', '');
        } // END - if
 
        // Compile the script name
@@ -1827,7 +1827,7 @@ function POST_URL ($script, $postData) {
 // Sends a raw request to another host
 function SEND_RAW_REQUEST ($host, $request) {
        // Initialize array
-       $response = array("", "", "");
+       $response = array("", '', '');
 
        // Default is not to use proxy
        $useProxy = false;
@@ -1926,7 +1926,7 @@ function SEND_RAW_REQUEST ($host, $request) {
        // Was the request successfull?
        if ((!eregi("200 OK", $response[0])) || (empty($response[0]))) {
                // Not found / access forbidden
-               $response = array("", "", "");
+               $response = array("", '', '');
        } // END - if
 
        // Return response
@@ -2010,18 +2010,18 @@ function MEMBER_ACTION_LINKS ($uid, $status = "") {
 }
 
 // Generate an email link
-function CREATE_EMAIL_LINK ($email, $table = "admins") {
+function CREATE_EMAIL_LINK ($email, $table = 'admins') {
        // Default email link (INSECURE! Spammer can read this by harvester programs)
        $EMAIL = "mailto:".$email;
 
        // Check for several extensions
-       if ((EXT_IS_ACTIVE("admins")) && ($table == "admins")) {
+       if ((EXT_IS_ACTIVE('admins')) && ($table == 'admins')) {
                // Create email link for contacting admin in guest area
                $EMAIL = ADMINS_CREATE_EMAIL_LINK($email);
-       } elseif ((EXT_IS_ACTIVE("user")) && (GET_EXT_VERSION("user") >= "0.3.3") && ($table == "user_data")) {
+               } elseif ((EXT_IS_ACTIVE('user')) && (GET_EXT_VERSION('user') >= '0.3.3') && ($table == "user_data")) {
                // Create email link for contacting a member within admin area (or later in other areas, too?)
                $EMAIL = USER_CREATE_EMAIL_LINK($email);
-       } elseif ((EXT_IS_ACTIVE("sponsor")) && ($table == "sponsor_data")) {
+       } elseif ((EXT_IS_ACTIVE('sponsor')) && ($table == "sponsor_data")) {
                // Create email link to contact sponsor within admin area (or like the link above?)
                $EMAIL = SPONSOR_CREATE_EMAIL_LINK($email);
        }
@@ -2035,8 +2035,8 @@ function CREATE_EMAIL_LINK ($email, $table = "admins") {
 
 // Generate a hash for extra-security for all passwords
 function generateHash ($plainText, $salt = "") {
-       // Is the required extension "sql_patches" there and a salt is not given?
-       if (((EXT_VERSION_IS_OLDER("sql_patches", "0.3.6")) || (!EXT_IS_ACTIVE("sql_patches"))) && (empty($salt))) {
+       // Is the required extension 'sql_patches' there and a salt is not given?
+       if (((EXT_VERSION_IS_OLDER('sql_patches', '0.3.6')) || (!EXT_IS_ACTIVE('sql_patches'))) && (empty($salt))) {
                // Extension sql_patches is missing/outdated so we hash the plain text with MD5
                return md5($plainText);
        } // END - if
@@ -2085,7 +2085,7 @@ function generateHash ($plainText, $salt = "") {
 // Scramble a string
 function scrambleString($str) {
        // Init
-       $scrambled = "";
+       $scrambled = '';
 
        // Final check, in case of failture it will return unscrambled string
        if (strlen($str) > 40) {
@@ -2166,7 +2166,7 @@ function genScrambleString ($len) {
 // normally be stored in cookies
 function ADD_URL_DATA ($URL) {
        // Init add
-       $add = "";
+       $add = '';
 
        // Determine URL binder
        $BIND = "?";
@@ -2177,7 +2177,7 @@ function ADD_URL_DATA ($URL) {
                if ((REQUEST_ISSET_GET(('refid'))) && (strpos($URL, "refid=") == 0)) {
                        // Cookie found in URL
                        $add .= $BIND."refid=".bigintval(REQUEST_GET('refid'));
-               } elseif ((GET_EXT_VERSION("sql_patches") != '') && (getConfig('def_refid') > 0)) {
+               } elseif ((GET_EXT_VERSION('sql_patches') != '') && (getConfig('def_refid') > 0)) {
                        // Not found! So let's set default here
                        $add .= $BIND."refid=".getConfig('def_refid');
                }
@@ -2195,7 +2195,7 @@ function generatePassString ($passHash) {
        // Is a secret key and master salt already initialized?
        if ((getConfig('secret_key') != "") && (getConfig('master_salt') != "")) {
                // Only calculate when the secret key is generated
-               $newHash = ""; $start = 9;
+               $newHash = ''; $start = 9;
                for ($idx = 0; $idx < 10; $idx++) {
                        $part1 = hexdec(substr($passHash, $start, 4));
                        $part2 = hexdec(substr(getConfig('secret_key'), $start, 4));
@@ -2234,7 +2234,7 @@ function FIX_DELETED_COOKIES ($cookies) {
                foreach ($cookies as $cookieName) {
                        // Is the cookie set to "deleted"?
                        if (get_session($cookieName) == "deleted") {
-                               set_session($cookieName, "");
+                               set_session($cookieName, '');
                        }
                } // END - foreach
        } // END - if
@@ -2243,16 +2243,16 @@ function FIX_DELETED_COOKIES ($cookies) {
 // Output error messages in a fasioned way and die...
 function app_die ($F, $L, $msg) {
        // Load header
-       LOAD_INC_ONCE("inc/header.php");
+       LOAD_INC_ONCE('inc/header.php');
 
        // Prepare message for output
        $msg = sprintf(getMessage('MXCHANGE_HAS_DIED'), basename($F), $L, $msg);
 
        // Load the message template
-       LOAD_TEMPLATE("admin_settings_saved", false, $msg);
+       LOAD_TEMPLATE('admin_settings_saved', false, $msg);
 
        // Load footer
-       LOAD_INC_ONCE("inc/footer.php");
+       LOAD_INC_ONCE('inc/footer.php');
 
        // Exit explicitly
        shutdown();
@@ -2358,7 +2358,7 @@ function GET_CURR_THEME() {
        if (!isSessionVariableSet('mxchange_theme')) {
                // Set default theme
                set_session('mxchange_theme', $ret);
-       } elseif ((isSessionVariableSet('mxchange_theme')) && (GET_EXT_VERSION("sql_patches") >= "0.1.4")) {
+       } elseif ((isSessionVariableSet('mxchange_theme')) && (GET_EXT_VERSION('sql_patches') >= '0.1.4')) {
                //die("<pre>".print_r($GLOBALS['cache_array']['themes'], true)."</pre>");
                // Get theme from cookie
                $ret = get_session('mxchange_theme');
@@ -2400,8 +2400,8 @@ function GET_CURR_THEME() {
 
 // Get id from theme
 function THEME_GET_ID ($name) {
-       // Is the extension "theme" installed?
-       if (!EXT_IS_ACTIVE("theme")) {
+       // Is the extension 'theme' installed?
+       if (!EXT_IS_ACTIVE('theme')) {
                // Then abort here
                return 0;
        } // END - if
@@ -2416,7 +2416,7 @@ function THEME_GET_ID ($name) {
 
                // Count up
                incrementConfigEntry('cache_hits');
-       } elseif (GET_EXT_VERSION("cache") != "0.1.8") {
+       } elseif (GET_EXT_VERSION('cache') != '0.1.8') {
                // Check if current theme is already imported or not
                $result = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_themes` WHERE theme_path='%s' LIMIT 1",
                        array($name), __FUNCTION__, __LINE__);
@@ -2449,7 +2449,7 @@ function READ_FILE ($FQFN, $sqlPrepare = false) {
        // Prepare SQL queries?
        if ($sqlPrepare === true) {
                // Remove some unwanted chars
-               $content = str_replace("\r", "", $content);
+               $content = str_replace("\r", '', $content);
                $content = str_replace("\n\n", "\n", $content);
        } // END - if
 
@@ -2526,7 +2526,7 @@ function searchDirsRecursive ($dir, &$last_changed) {
        // Does it match what we are looking for? (We skip a lot files already!)
     // RegexPattern to exclude  ., .., .revision,  .svn, debug.log or .cache in the filenames
        $excludePattern = '@(\.|\.\.|\.revision|\.svn|debug\.log|\.cache|config\.php)$@';
-       $ds = GET_DIR_AS_ARRAY($dir, "", true, false, $excludePattern);
+       $ds = GET_DIR_AS_ARRAY($dir, '', true, false, $excludePattern);
        //* DEBUG: */ print __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>):ds[]=".count($ds)."<br />\n";
 
        // Walk through all entries
@@ -2561,12 +2561,12 @@ function getActualVersion ($type = 'Revision') {
        // By default nothing is new... ;-)
        $new = false;
 
-       if (EXT_IS_ACTIVE("cache")) {
-               // Check if $_GET['check_revision_data'] is setted (switch for manually rewrite the .revision-File)
-               if (isset($_GET['check_revision_data']) && $_GET['check_revision_data'] == 'yes') $new = true;
+       if (EXT_IS_ACTIVE('cache')) {
+               // Check if REQUEST_GET('check_revision_data') is setted (switch for manually rewrite the .revision-File)
+               if (REQUEST_ISSET_GET('check_revision_data') && REQUEST_GET('check_revision_data') == 'yes') $new = true;
                if (!isset($GLOBALS['cache_array']['revision'][$type])
                        || count($GLOBALS['cache_array']['revision']) < 3
-                       || !$GLOBALS['cache_instance']->loadCacheFile("revision")) $new = true;
+                       || !$GLOBALS['cache_instance']->loadCacheFile('revision')) $new = true;
 
                // Is the cache file outdated/invalid?
                if ($new === true){
@@ -2576,7 +2576,7 @@ function getActualVersion ($type = 'Revision') {
                        unset($GLOBALS['cache_array']['revision']);
 
                        // Reload load_cach-revison.php
-                       LOAD_INC("inc/loader/load_cache-revision.php");
+                       LOAD_INC('inc/loader/load_cache-revision.php');
                } // END - if
 
                // Return found value
@@ -2588,8 +2588,8 @@ function getActualVersion ($type = 'Revision') {
                // FQFN of revision file
                $FQFN = sprintf("%sinc/cache/.revision", constant('PATH'));
 
-               // Check if $_GET['check_revision_data'] is setted (switch for manually rewrite the .revision-File)
-               if ((isset($_GET['check_revision_data'])) && ($_GET['check_revision_data'] == 'yes')) {
+               // Check if REQUEST_GET('check_revision_data') is setted (switch for manually rewrite the .revision-File)
+               if ((REQUEST_ISSET_GET('check_revision_data')) && (REQUEST_GET('check_revision_data') == 'yes')) {
                        // Has changed!
                        $new = true;
                } else {
@@ -2635,7 +2635,7 @@ function getSearchFor () {
 
 function getAkt_vers () {
        // Init variables
-       $next_dir = ""; // Directory to start with search
+       $next_dir = ''; // Directory to start with search
        $last_changed = array(
                'path_name' => "",
                'time'      => 0
@@ -2654,7 +2654,7 @@ function getAkt_vers () {
 
        // This foreach loops the $searchFor-Tags (array('Revision', 'Date', 'Tag', 'Author') --> could easaly extended in the future)
        foreach ($searchFor as $search) {
-               //Searches for "$search-tag:VALUE$" or "$search-tag::VALUE$"(the stylish keywordversion ;-)) in the lates modified file
+               // Searches for "$search-tag:VALUE$" or "$search-tag::VALUE$"(the stylish keywordversion ;-)) in the lates modified file
                $res += preg_match('@\$'.$search.'(:|::) (.*) \$@U', $last_file, $t);
                // This trimms the search-result and puts it in the $akt_vers-return array
                if (isset($t[2])) $akt_vers[$search] = trim($t[2]);
@@ -2748,7 +2748,7 @@ function debug_get_printable_backtrace () {
 // Output a debug backtrace to the user
 function debug_report_bug ($message = "") {
        // Init message
-       $debug = "";
+       $debug = '';
        // Is the optional message set?
        if (!empty($message)) {
                // Use and log it
@@ -2779,7 +2779,7 @@ function generateSeed () {
 
 // Converts a message code to a human-readable message
 function convertCodeToMessage ($code) {
-       $msg = "";
+       $msg = '';
        switch ($code) {
                case getCode('LOGOUT_DONE')      : $msg = getMessage('LOGOUT_DONE'); break;
                case getCode('LOGOUT_FAILED')    : $msg = "<span class=\"guest_failed\">{--LOGOUT_FAILED--}</span>"; break;
@@ -2794,7 +2794,7 @@ function convertCodeToMessage ($code) {
                        if (EXT_IS_ACTIVE($ext, true)) {
                                $msg = getMessage('ERROR_CONFIRMING_MAIL');
                        } else {
-                               $msg = sprintf(getMessage('EXTENSION_PROBLEM_NOT_INSTALLED'), "mailid");
+                               $msg = sprintf(getMessage('EXTENSION_PROBLEM_NOT_INSTALLED'), 'mailid');
                        }
                        break;
 
@@ -2830,7 +2830,7 @@ function REDIRCT_ON_UNINSTALLED_EXTENSION ($ext_name) {
        // Is the extension uninstalled/inactive?
        if (!EXT_IS_ACTIVE($ext_name)) {
                // Redirect to index
-               LOAD_URL("modules.php?module=index&amp;msg=".getCode('EXTENSION_PROBLEM')."&amp;ext=".$ext_name);
+               LOAD_URL('modules.php?module=index&amp;msg=' . getCode('EXTENSION_PROBLEM') . '&amp;ext=' . $ext_name);
        } // END - if
 }
 
@@ -2847,12 +2847,12 @@ function GENERATE_AID_LINK ($aid) {
                // Is the login valid?
                if ($login != "***") {
                        // Is the extension there?
-                       if (EXT_IS_ACTIVE("admins")) {
+                       if (EXT_IS_ACTIVE('admins')) {
                                // Admin found
                                $admin = "<a href=\"".ADMINS_CREATE_EMAIL_LINK(GET_ADMIN_EMAIL($aid))."\">".$login."</a>";
                        } else {
                                // Extension not found
-                               $admin = sprintf(getMessage('EXTENSION_PROBLEM_NOT_INSTALLED'), "admins");
+                               $admin = sprintf(getMessage('EXTENSION_PROBLEM_NOT_INSTALLED'), 'admins');
                        }
                } else {
                        // Maybe deleted?
@@ -2912,7 +2912,7 @@ function compileUriCode ($code, $simple=true) {
 // Function taken from user comments on www.php.net / function eregi()
 function isUrlValid ($url) {
        // Prepare URL
-       $url = strip_tags(str_replace("\\", "", compileUriCode(urldecode($url))));
+       $url = strip_tags(str_replace("\\", '', compileUriCode(urldecode($url))));
 
        // Allows http and https
        $http      = "(http|https)+(:\/\/)";
@@ -2978,7 +2978,7 @@ function isUrlValid ($url) {
 
 // Smartly adds slashes
 function smartAddSlashes ($unquoted) {
-       $unquoted = str_replace("\\", "", $unquoted);
+       $unquoted = str_replace("\\", '', $unquoted);
        return addslashes($unquoted);
 }
 
@@ -3064,7 +3064,7 @@ function changeDataInFile ($FQFN, $comment, $prefix, $suffix, $DATA, $seek=0) {
 }
 // Send notification to admin
 function SEND_ADMIN_NOTIFICATION ($subject, $templateName, $content=array(), $uid="0") {
-       if (GET_EXT_VERSION("admins") >= "0.4.1") {
+       if (GET_EXT_VERSION('admins') >= '0.4.1') {
                // Send new way
                SEND_ADMIN_EMAILS_PRO($subject, $templateName, $content, $uid);
        } else {
@@ -3099,7 +3099,7 @@ function DEBUG_LOG ($funcFile, $line, $message, $force=true) {
        // Is debug mode enabled?
        if ((isDebugModeEnabled()) || ($force === true)) {
                // Remove CRLF
-               $message = str_replace("\r", "", str_replace("\n", "", $message));
+               $message = str_replace("\r", '', str_replace("\n", '', $message));
 
                // Log this message away
                $fp = fopen(constant('PATH')."inc/cache/debug.log", 'a') or app_die(__FUNCTION__, __LINE__, "Cannot write logfile debug.log!");
@@ -3111,7 +3111,7 @@ function DEBUG_LOG ($funcFile, $line, $message, $force=true) {
 // Load more reset scripts
 function runResetIncludes () {
        // Is the reset set or old sql_patches?
-       if ((!isResetModeEnabled()) || (EXT_VERSION_IS_OLDER("sql_patches", "0.4.5"))) {
+       if ((!isResetModeEnabled()) || (EXT_VERSION_IS_OLDER('sql_patches', '0.4.5'))) {
                // Then abort here
                DEBUG_LOG(__FUNCTION__, __LINE__, "Cannot run reset! Please report this bug. Thanks");
        } // END - if
@@ -3123,7 +3123,7 @@ function runResetIncludes () {
        if (!defined('DEBUG_RESET')) UPDATE_CONFIG("last_update", time());
 
        // Is the config entry set?
-       if (GET_EXT_VERSION("sql_patches") >= "0.4.2") {
+       if (GET_EXT_VERSION('sql_patches') >= '0.4.2') {
                // Create current week mark
                $currWeek = date("W", time());
 
@@ -3195,7 +3195,7 @@ function FILE_READABLE ($FQFN) {
 // Converts timestamp selections into a timestamp
 function CONVERT_SELECTIONS_TO_TIMESTAMP (&$POST, &$DATA, &$id, &$skip) {
        // Init test variable
-       $test2 = "";
+       $test2 = '';
 
        // Get last three chars
        $test = substr($id, -3);
@@ -3220,7 +3220,7 @@ function CONVERT_SELECTIONS_TO_TIMESTAMP (&$POST, &$DATA, &$id, &$skip) {
        } else {
                // Process this entry
                $skip = false;
-               $test2 = "";
+               $test2 = '';
        }
 }
 
@@ -3233,7 +3233,7 @@ function REVERT_COMMA ($str) {
        switch (GET_LANGUAGE()) {
                case "de": // German language
                        // Remove german thousand dots first
-                       $str = str_replace(".", "", $str);
+                       $str = str_replace(".", '', $str);
 
                        // Replace german commata with decimal dot and cast it
                        $float = (float)str_replace(",", ".", $str);
@@ -3241,7 +3241,7 @@ function REVERT_COMMA ($str) {
 
                default: // US and so on
                        // Remove thousand dots first and cast
-                       $float = (float)str_replace(",", "", $str);
+                       $float = (float)str_replace(",", '', $str);
                        break;
        }
 
@@ -3252,7 +3252,7 @@ function REVERT_COMMA ($str) {
 // Handle menu-depending failed logins and return the rendered content
 function HANDLE_LOGIN_FAILTURES ($accessLevel) {
        // Default output is empty ;-)
-       $OUT = "";
+       $OUT = '';
 
        // Is the session data set?
        if ((isSessionVariableSet('mxchange_'.$accessLevel.'_failures')) && (isSessionVariableSet('mxchange_'.$accessLevel.'_last_fail'))) {
@@ -3270,8 +3270,8 @@ function HANDLE_LOGIN_FAILTURES ($accessLevel) {
                } // END - if
 
                // Reset session data
-               set_session('mxchange_'.$accessLevel.'_failures', "");
-               set_session('mxchange_'.$accessLevel.'_last_fail', "");
+               set_session('mxchange_'.$accessLevel.'_failures', '');
+               set_session('mxchange_'.$accessLevel.'_last_fail', '');
        } // END - if
 
        // Return rendered content
@@ -3281,7 +3281,7 @@ function HANDLE_LOGIN_FAILTURES ($accessLevel) {
 // Rebuild cache
 function rebuildCacheFiles ($cache, $inc="") {
        // Shall I remove the cache file?
-       if ((EXT_IS_ACTIVE("cache")) && (isCacheInstanceValid())) {
+       if ((EXT_IS_ACTIVE('cache')) && (isCacheInstanceValid())) {
                // Rebuild cache
                if ($GLOBALS['cache_instance']->loadCacheFile($cache)) {
                        // Destroy it
@@ -3309,7 +3309,7 @@ function rebuildCacheFiles ($cache, $inc="") {
 // Purge admin menu cache
 function CACHE_PURGE_ADMIN_MENU ($id=0, $action="", $what="", $str="") {
        // Is the cache extension enabled or no cache instance or admin menu cache disabled?
-       if (!EXT_IS_ACTIVE("cache")) {
+       if (!EXT_IS_ACTIVE('cache')) {
                // Cache extension not active
                return false;
        } elseif (!isCacheInstanceValid()) {
@@ -3373,7 +3373,7 @@ function GET_REMOTE_ADDR () {
        $remoteAddr = determineRealRemoteAddress();
 
        // Is removeip installed?
-       if (EXT_IS_ACTIVE("removeip")) {
+       if (EXT_IS_ACTIVE('removeip')) {
                // Then anonymize it
                $remoteAddr = GET_ANONYMOUS_REMOTE_ADDR($remoteAddr);
        } // END - if
@@ -3388,7 +3388,7 @@ function GET_REMOTE_HOST () {
        $remoteHost = getenv('REMOTE_HOST');
 
        // Is removeip installed?
-       if (EXT_IS_ACTIVE("removeip")) {
+       if (EXT_IS_ACTIVE('removeip')) {
                // Then anonymize it
                $remoteHost = GET_ANONYMOUS_REMOTE_HOST($remoteHost);
        } // END - if
@@ -3403,7 +3403,7 @@ function GET_USER_AGENT () {
        $userAgent = getenv('HTTP_USER_AGENT');
 
        // Is removeip installed?
-       if (EXT_IS_ACTIVE("removeip")) {
+       if (EXT_IS_ACTIVE('removeip')) {
                // Then anonymize it
                $userAgent = GET_ANONYMOUS_USER_AGENT($userAgent);
        } // END - if
@@ -3418,7 +3418,7 @@ function GET_REFERER () {
        $referer = getenv('HTTP_REFERER');
 
        // Is removeip installed?
-       if (EXT_IS_ACTIVE("removeip")) {
+       if (EXT_IS_ACTIVE('removeip')) {
                // Then anonymize it
                $referer = GET_ANONYMOUS_REFERER($referer);
        } // END - if
@@ -3452,10 +3452,10 @@ function ADD_NEW_BONUS_MAIL ($data, $mode="", $output=true) {
                );
 
                // Mail inserted into bonus pool
-               if ($output) LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_BONUS_SEND'));
+               if ($output) LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_BONUS_SEND'));
        } elseif ($output) {
                // More entered than can be reached!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_MORE_SELECTED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_MORE_SELECTED'));
        } else {
                // Debug log
                DEBUG_LOG(__FUNCTION__, __LINE__, " cat={$data['cat']},receiver={$data['receiver']},data=".base64_encode(serialize($data))." More selected, than available!");
@@ -3480,10 +3480,10 @@ function DETERMINE_REFID () {
        } elseif ((isSessionVariableSet('refid')) && (get_session('refid') != 0)) {
                // Set session refid als global
                $GLOBALS['refid'] = bigintval(get_session('refid'));
-       } elseif ((GET_EXT_VERSION("sql_patches") != "") && (getConfig('def_refid') > 0)) {
+       } elseif ((GET_EXT_VERSION('sql_patches') != "") && (getConfig('def_refid') > 0)) {
                // Set default refid as refid in URL
                $GLOBALS['refid'] = getConfig(('def_refid'));
-       } elseif ((GET_EXT_VERSION("user") >= "0.3.4") && (getConfig('select_user_zero_refid')) == "Y") {
+       } elseif ((GET_EXT_VERSION('user') >= '0.3.4') && (getConfig('select_user_zero_refid')) == 'Y') {
                // Select a random user which has confirmed enougth mails
                $GLOBALS['refid'] = SELECT_RANDOM_REFID();
        } else {
index 1f69a9a698d097e66cf74fb6c54bf35a74516bc3..73a8bce909615b50ceed9fe0ba87d75e326340ce 100644 (file)
@@ -38,7 +38,7 @@
 
 // Some security stuff...
 if (!defined('__SECURITY')) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
 }
 
@@ -46,8 +46,8 @@ if (!defined('__SECURITY')) {
 $bsent = 0; $bclicks = 0; $bcount = 0;
 
 // Check for normal mails
-$result_media = SQL_QUERY("SELECT SUM(max_rec) AS max_rec, SUM(clicks) AS clicks
-FROM `{!_MYSQL_PREFIX!}_user_stats`", __FILE__, __LINE__);
+$result_media = SQL_QUERY('SELECT SUM(max_rec) AS max_rec, SUM(clicks) AS clicks
+FROM `{!_MYSQL_PREFIX!}_user_stats`', __FILE__, __LINE__);
 list($nsent, $nclicks) = SQL_FETCHROW($result_media);
 if (empty($nsent))   $nsent   = 0;
 if (empty($nclicks)) $nclicks = 0;
@@ -56,48 +56,48 @@ if (empty($nclicks)) $nclicks = 0;
 SQL_FREERESULT($result_media);
 
 // Count mail orders
-$result_media = SQL_QUERY("SELECT COUNT(id) FROM `{!_MYSQL_PREFIX!}_user_stats`", __FILE__, __LINE__);
+$result_media = SQL_QUERY('SELECT COUNT(id) FROM `{!_MYSQL_PREFIX!}_user_stats`', __FILE__, __LINE__);
 list($ncount) = SQL_FETCHROW($result_media);
 SQL_FREERESULT($result_media);
 
 // Check for bonus extension
-if (EXT_IS_ACTIVE("bonus")) {
+if (EXT_IS_ACTIVE('bonus')) {
        // Count bonus mails
-       $result_media = SQL_QUERY("SELECT COUNT(id) FROM `{!_MYSQL_PREFIX!}_bonus`", __FILE__, __LINE__);
+       $result_media = SQL_QUERY('SELECT COUNT(id) FROM `{!_MYSQL_PREFIX!}_bonus`', __FILE__, __LINE__);
        list($bcount) = SQL_FETCHROW($result_media);
        SQL_FREERESULT($result_media);
 
        // Check for bonus mails
-       $result_media = SQL_QUERY("SELECT SUM(mails_sent) AS bonus_sent, SUM(clicks) AS bonus_clicks
-FROM `{!_MYSQL_PREFIX!}_bonus`", __FILE__, __LINE__);
+       $result_media = SQL_QUERY('SELECT SUM(mails_sent) AS bonus_sent, SUM(clicks) AS bonus_clicks
+FROM `{!_MYSQL_PREFIX!}_bonus`', __FILE__, __LINE__);
        list($bsent, $bclicks) = SQL_FETCHROW($result_media);
        if (empty($bsent))   $bsent   = 0;
        if (empty($bclicks)) $bclicks = 0;
 } // END - if
 
 // Load (maybe) missing file
-LOAD_INC_ONCE("inc/libs/mediadata_functions.php");
+LOAD_INC_ONCE('inc/libs/mediadata_functions.php');
 
 // Insert info to database
-MEDIA_UPDATE_ENTRY(array("total_send"  , "normal_send")  , "init", $nsent);
-MEDIA_UPDATE_ENTRY(array("total_clicks", "normal_clicks"), "init", $nclicks);
-MEDIA_UPDATE_ENTRY(array("total_orders", "normal_orders"), "init", $ncount);
-MEDIA_UPDATE_ENTRY(array("total_send"  , "bonus_send" )  , "init", $bsent);
-MEDIA_UPDATE_ENTRY(array("total_clicks", "bonus_clicks") , "init", $bclicks);
-MEDIA_UPDATE_ENTRY(array("total_orders", "bonus_orders") , "init", $bcount);
+MEDIA_UPDATE_ENTRY(array('total_send'  , 'normal_send')  , 'init', $nsent);
+MEDIA_UPDATE_ENTRY(array('total_clicks', 'normal_clicks'), 'init', $nclicks);
+MEDIA_UPDATE_ENTRY(array('total_orders', 'normal_orders'), 'init', $ncount);
+MEDIA_UPDATE_ENTRY(array('total_send'  , 'bonus_send' )  , 'init', $bsent);
+MEDIA_UPDATE_ENTRY(array('total_clicks', 'bonus_clicks') , 'init', $bclicks);
+MEDIA_UPDATE_ENTRY(array('total_orders', 'bonus_orders') , 'init', $bcount);
 
 // Aquire total used points
-$result = SQL_QUERY("SELECT SUM(used_points) AS used_points FROM `{!_MYSQL_PREFIX!}_user_data`", __FILE__, __LINE__);
+$result = SQL_QUERY('SELECT SUM(used_points) AS used_points FROM `{!_MYSQL_PREFIX!}_user_data`', __FILE__, __LINE__);
 list($used) = SQL_FETCHROW($result);
 SQL_FREERESULT($result);
 
 // ... and total points
-$result = SQL_QUERY("SELECT SUM(points) AS points FROM `{!_MYSQL_PREFIX!}_user_points`", __FILE__, __LINE__);
+$result = SQL_QUERY('SELECT SUM(points) AS points FROM `{!_MYSQL_PREFIX!}_user_points`', __FILE__, __LINE__);
 list($points) = SQL_FETCHROW($result);
 SQL_FREERESULT($result);
 
 // Update database
-MEDIA_UPDATE_ENTRY(array("total_points"), "init", ($points - $used));
+MEDIA_UPDATE_ENTRY(array('total_points'), 'init', ($points - $used));
 
 //
 ?>
index 81c0e2345ec945a0c85cbdfc4adf4b1a3d13cd69..e4b1fd45bc0f9cd816f0adfc5e66256915dbe8f0 100644 (file)
@@ -58,24 +58,24 @@ if (SQL_NUMROWS($result) > 0) {
        SQL_ALTER_TABLE("ALTER TABLE `{!_MYSQL_PREFIX!}_refsystem` ADD UNIQUE `userid_level` ( `userid`,`level` )", __FILE__, __LINE__);
 
        // Rebuild cache
-       rebuildCacheFiles("refsystem", "refsystem");
+       rebuildCacheFiles('refsystem', 'refsystem');
 } // END - if
 
 // Free result
 SQL_FREERESULT($result);
 
 // Reset the table
-SQL_QUERY("TRUNCATE TABLE `{!_MYSQL_PREFIX!}_user_refs`", __FILE__, __LINE__);
+SQL_QUERY('TRUNCATE TABLE `{!_MYSQL_PREFIX!}_user_refs`', __FILE__, __LINE__);
 
 // Begin with all users in level one
-$result_direct = SQL_QUERY("SELECT u.userid
+$result_direct = SQL_QUERY('SELECT u.userid
 FROM `{!_MYSQL_PREFIX!}_user_data` AS u
 WHERE u.refid=0
-ORDER BY u.userid ASC", __FILE__, __LINE__);
+ORDER BY u.userid ASC', __FILE__, __LINE__);
 
 // Do we have entries?
 if (SQL_NUMROWS($result_direct) > 0) {
-       // When "walk" through all users
+       // When 'walk' through all users
        while ($content = SQL_FETCHARRAY($result_direct)) {
                // Init level
                $GLOBALS['cache_array']['back_level'] = 1;
index b6e3ec33e16785524ea0390fc1bc4f3352d4890b..ffbd0713a7f93ff5e6608f2d05ee4fbb0e70fb37 100644 (file)
@@ -43,7 +43,7 @@ if (ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) {
 }
 
 // Check for version of sql_patches
-if (GET_EXT_VERSION("sql_patches") < "0.3.6") return false;
+if (GET_EXT_VERSION('sql_patches') < '0.3.6') return false;
 
 // Check if there is no scrambling string
 if (getConfig('pass_scramble') == "") {
@@ -95,7 +95,7 @@ if (getConfig('file_hash') == "") {
        if (FILE_READABLE($FQFN)) {
                //* DEBUG: */ unlink($FQFN);
                //* DEBUG: */ $test = hexdec(get_session('u_hash')) / hexdec($secretKey);
-               //* DEBUG: */ $test = generateHash(str_replace('.', "", $test));
+               //* DEBUG: */ $test = generateHash(str_replace('.', '', $test));
                //* DEBUG: */ die("Secret-Key: ".$secretKey."<br />Cookie: ".get_session('u_hash')."<br />Test: ".$test);
 
                // Write $fileHash to database
index 7bba6be8918fbeb5d3870c4038a72e9563735c62..b9ab89405562ee58f9962f5921c31ec1e9586aaa 100644 (file)
@@ -56,7 +56,7 @@ function __errorHandler ($errno, $errstr, $errfile, $errline) {
        DEBUG_LOG(__FUNCTION__, __LINE__, "".$msg, true);
 
        // Output message to user and die
-       if (EXT_IS_ACTIVE("debug")) {
+       if (EXT_IS_ACTIVE('debug')) {
                // Debug extension found! So Output a small message
                app_die(__FUNCTION__, __LINE__, "Error message written to debug.log. Please try to call <a href=\"{!URL!}\">the main page</a> to continue.");
        } else {
index f6897807644b0d10747afaeb403b23897234d489..45b1caa4d6963b699d8dad1468a2443a3cac7fe9 100644 (file)
@@ -49,14 +49,14 @@ if (($GLOBALS['header_sent'] != "1") && ($GLOBALS['header_sent'] != "2")) {
        // If not in CSS mode generate the header
        if (($GLOBALS['output_mode'] != "1")) {
                // Generate header
-               $TITLE = "";
+               $TITLE = '';
 
                // Add title decorations? (left)
                if (!defined('__PAGE_TITLE')) {
                        // Config and database connection valid?
                        if ((isConfigLoaded()) && (SQL_IS_LINK_UP())) {
                                // Title decoration enabled?
-                               if ((getConfig('enable_title_deco') == "Y") && (getConfig('title_left') != "")) $TITLE .= trim(getConfig('title_left'))." ";
+                               if ((getConfig('enable_title_deco') == 'Y') && (getConfig('title_left') != "")) $TITLE .= trim(getConfig('title_left'))." ";
 
                                // Do we have some extra title?
                                if (!empty($EXTRA_TITLE)) {
@@ -68,16 +68,16 @@ if (($GLOBALS['header_sent'] != "1") && ($GLOBALS['header_sent'] != "2")) {
                                $TITLE .= constant('MAIN_TITLE');
 
                                // Add title of module? (middle decoration will also be added!)
-                               if ((getConfig('enable_mod_title') == "Y") || ((empty($GLOBALS['what'])) && (empty($GLOBALS['action']))) || ($GLOBALS['module'] == "admin")) $TITLE .= " ".trim(getConfig('title_middle'))." ".ADD_MODULE_TITLE($GLOBALS['module']);
+                               if ((getConfig('enable_mod_title') == 'Y') || ((empty($GLOBALS['what'])) && (empty($GLOBALS['action']))) || ($GLOBALS['module'] == 'admin')) $TITLE .= " ".trim(getConfig('title_middle'))." ".ADD_MODULE_TITLE($GLOBALS['module']);
 
                                // Add title from what file
-                               $MODE = "";
-                               if ($GLOBALS['module'] == "login") $MODE = "member";
-                                elseif ($GLOBALS['module'] == "index") $MODE = "guest";
-                               if ((!empty($MODE)) && (getConfig('enable_what_title') == "Y")) $TITLE .= " ".trim(getConfig('title_middle'))." ".GET_MOD_DESCR($MODE, $GLOBALS['what']);
+                               $MODE = '';
+                               if ($GLOBALS['module'] == "login") $MODE = 'member';
+                                elseif ($GLOBALS['module'] == 'index') $MODE = 'guest';
+                               if ((!empty($MODE)) && (getConfig('enable_what_title') == 'Y')) $TITLE .= " ".trim(getConfig('title_middle'))." ".GET_MOD_DESCR($MODE, $GLOBALS['what']);
 
                                // Add title decorations? (right)
-                               if ((getConfig('enable_title_deco') == "Y") && (getConfig('title_right') != "")) $TITLE .= " ".trim(getConfig('title_right'));
+                               if ((getConfig('enable_title_deco') == 'Y') && (getConfig('title_right') != "")) $TITLE .= " ".trim(getConfig('title_right'));
 
                                // Remember title in constant for the template
                                define('__PAGE_TITLE', $TITLE);
@@ -99,8 +99,8 @@ if (($GLOBALS['header_sent'] != "1") && ($GLOBALS['header_sent'] != "2")) {
                // Output page header code
                LOAD_TEMPLATE("page_header");
 
-               // Include meta data in "guest" module
-               if ($GLOBALS['module'] == "index") {
+               // Include meta data in 'guest' module
+               if ($GLOBALS['module'] == 'index') {
                        // Load meta data template
                        LOAD_TEMPLATE("metadata");
 
index 7312a401f0d158b32cc1d9f13280d854d08b9738..eea54299728eeef13f7aa9e3fdd7a1dd21463fc4 100644 (file)
@@ -348,12 +348,12 @@ if ((!isInstalled()) || (!isAdminRegistered()))
                        } // END - if
 
                        if (getTotalFatalErrors() > 0) {
-                               $OUT = "";
+                               $OUT = '';
                                foreach (getFatalArray() as $value) {
                                        $OUT .= "    <li>".$value."</li>\n";
                                } // END foreach
                                define('__FATAL_ERROR_LI', $OUT);
-                               $OUT = "";
+                               $OUT = '';
                                foreach ($mysql as $key => $value) {
                                        $OUT .= "    <input type=\"hidden\" name=\"mysql[".$key."]\" value=\"".$value."\">\n";
                                } // END foreach
@@ -366,18 +366,18 @@ if ((!isInstalled()) || (!isAdminRegistered()))
                                define('__SMTP_PASS'    , REQUEST_POST('smtp_pass1'));
 
                                // Load template
-                               LOAD_TEMPLATE("install_fatal_errors");
+                               LOAD_TEMPLATE('install_fatal_errors');
                        } else {
                                // Installation is done!
-                               LOAD_URL("install.php?page=finalize");
+                               LOAD_URL('install.php?page=finalize');
                        }
                } elseif (isInstalled()) {
                        // Redirection after writing data... :-)
-                       LOAD_TEMPLATE("install_finished");
+                       LOAD_TEMPLATE('install_finished');
                } else {
                        // Something goes wrong during installation! :-(
                        addFatalMessage(__FILE__, __LINE__, getMessage('INSTALL_FINALIZER_FAILED'));
-                       LOAD_INC("inc/fatal_errors.php");
+                       LOAD_INC('inc/fatal_errors.php');
                }
                break;
 
index 3239912168adcbe1c2b13d0c78f77e215ff5b07b..3e43e41c4cd72caf480ec8657bb0fbf8470d7e89 100644 (file)
@@ -68,7 +68,7 @@ LOAD_INC_ONCE($INC);
 // Check for installation mode
 if ((isInstalling()) || (!isInstalled()) || (!isAdminRegistered())) {
        // Load matching language file
-       LOAD_INC("inc/language/install_".$mx_lang.".php");
+       LOAD_INC('inc/language/install_' . $mx_lang . '.php');
 }
 
 // Remove no more needed variables
index e690da7f8175096d77efe606c805a3ef247dbe01..51503bd6be802bcd674a640cd56cd1dc713bdf16 100644 (file)
@@ -45,11 +45,11 @@ if (!defined('__SECURITY')) {
 // Filter for adding link to "active list"
 function FILTER_ADD_LINK_ACTIVE_LIST () {
        // Are the extensions online and active there?
-       if ((EXT_IS_ACTIVE("active")) && (EXT_IS_ACTIVE("online"))) {
+       if ((EXT_IS_ACTIVE('active')) && (EXT_IS_ACTIVE('online'))) {
                // Init content
                $content = array(
                        'menu' => "<a class=\"menu_blur\" href=\"{!URL!}/modules.php?module=index&amp;what=active\">".getConfig('menu_blur_spacer').GUEST_ACTIVE_LINK."</a>",
-                       'what' => "active"
+                       'what' => 'active'
                );
 
                // Add link to "we were active today" page
index a981f8d148a093f49707dd8e42513f138a9b2ca7..66f918e0505186a995bdbdb8a2048b95bc2b3853 100644 (file)
@@ -60,10 +60,10 @@ function ADMINS_CHECK_ACL($act, $wht) {
        if (!empty($wht)) {
                // Check for parent menu:
                // First get it's action value
-               $parent_action = GET_ACTION("admin", $wht);
+               $parent_action = GET_ACTION('admin', $wht);
 
                // Check with this function...
-               $parent = ADMINS_CHECK_ACL($parent_action, "");
+               $parent = ADMINS_CHECK_ACL($parent_action, '');
        } else {
                // Anything else is true!
                $parent = false;
@@ -71,7 +71,7 @@ function ADMINS_CHECK_ACL($act, $wht) {
 
        // Shall I test for a main or sub menu? (action or what?)
        $acl_mode = "failed";
-       if ((GET_EXT_VERSION("cache") >= "0.1.2") && (count($GLOBALS['cache_array']['admin_acls']) > 0)) {
+       if ((GET_EXT_VERSION('cache') >= '0.1.2') && (count($GLOBALS['cache_array']['admin_acls']) > 0)) {
                // Lookup in cache
                if ((!empty($act)) && (isset($GLOBALS['cache_array']['admin_acls']['action_menu'][$aid])) & ($GLOBALS['cache_array']['admin_acls']['action_menu'][$aid] == $act)) {
                        // Main menu line found
@@ -86,7 +86,7 @@ function ADMINS_CHECK_ACL($act, $wht) {
                        // Count cache hits
                        incrementConfigEntry('cache_hits');
                }
-       } elseif (!EXT_IS_ACTIVE("cache")) {
+       } elseif (!EXT_IS_ACTIVE('cache')) {
                // Old version, so load it from database
                if (!empty($act)) {
                        // Main menu
@@ -120,7 +120,7 @@ function ADMINS_CHECK_ACL($act, $wht) {
 }
 
 // Create email link to admins's account
-function ADMINS_CREATE_EMAIL_LINK ($email, $mod="admin") {
+function ADMINS_CREATE_EMAIL_LINK ($email, $mod='admin') {
        // Is it an email?
        if (strpos($email, "@") !== false) {
                // Create email link
@@ -160,7 +160,7 @@ function ADMINS_CHANGE_ADMIN_ACCOUNT($POST) {
                // When both passwords match update admin account
                if ($POST['pass1'][$id] == $POST['pass2'][$id]) {
                        // Save only when both passwords are the same (also when they are empty)
-                       $add = ""; $cache_update = "1";
+                       $add = ''; $cache_update = "1";
 
                        // Generate hash
                        $hash = generateHash($POST['pass1'][$id]);
@@ -235,7 +235,7 @@ WHERE id=%s LIMIT 1",
 
                // Display message
                if (!empty($message)) {
-                       LOAD_TEMPLATE("admin_settings_saved", false, $message);
+                       LOAD_TEMPLATE('admin_settings_saved', false, $message);
                }
        }
 
@@ -249,7 +249,7 @@ function ADMINS_EDIT_ADMIN_ACCOUNTS ($POST) {
        $currMode = GET_ADMIN_DEFAULT_ACL(GET_CURRENT_ADMIN_ID());
 
        // Begin the edit loop
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach ($POST['sel'] as $id => $selected) {
                // Secure ID number
                $id = bigintval($id);
@@ -295,7 +295,7 @@ function ADMINS_DELETE_ADMIN_ACCOUNTS ($POST) {
        SQL_FREERESULT($result_main);
        if ($accounts > 1) {
                // Delete accounts
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                foreach ($POST['sel'] as $id => $selected) {
                        // Secure ID number
                        $id = bigintval($id);
@@ -325,7 +325,7 @@ function ADMINS_DELETE_ADMIN_ACCOUNTS ($POST) {
                LOAD_TEMPLATE("admin_del_admins");
        } else {
                // Cannot delete last account!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_ADMINS_CANNOT_DELETE_LAST'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_ADMINS_CANNOT_DELETE_LAST'));
        }
 }
 
@@ -361,7 +361,7 @@ function ADMINS_REMOVE_ADMIN_ACCOUNTS ($POST) {
 function ADMINS_LIST_ADMIN_ACCOUNTS() {
        // Select all admin accounts
        $result = SQL_QUERY("SELECT id, login, email, default_acl AS mode, la_mode FROM `{!_MYSQL_PREFIX!}_admins` ORDER BY login ASC", __FUNCTION__, __LINE__);
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Compile some variables
                $content['mode'] = constant('ADMINS_'.strtoupper($content['mode']).'_MODE');
@@ -387,9 +387,9 @@ function ADMINS_LIST_ADMIN_ACCOUNTS() {
 // Filter for adding extra data to the query
 function FILTER_ADD_EXTRA_SQL_DATA ($add = "") {
        // Is the admins extension updated? (should be!)
-       if (GET_EXT_VERSION("admins") >= "0.3")   $add .= ", default_acl AS def_acl";
-       if (GET_EXT_VERSION("admins") >= "0.6.7") $add .= ", la_mode";
-       if (GET_EXT_VERSION("admins") >= "0.7.2") $add .= ", login_failures, UNIX_TIMESTAMP(last_failure) AS last_failure";
+       if (GET_EXT_VERSION('admins') >= '0.3.0')   $add .= ", default_acl AS def_acl";
+       if (GET_EXT_VERSION('admins') >= '0.6.7') $add .= ", la_mode";
+       if (GET_EXT_VERSION('admins') >= '0.7.2') $add .= ", login_failures, UNIX_TIMESTAMP(last_failure) AS last_failure";
 
        // Return it
        return $add;
index 7dc6255aa7b2ec2a0ddd5af53379a8b0709c0e6b..7ce6fd555f5f4bc8a58becfa0a6dcea022ae72f7 100644 (file)
@@ -69,9 +69,9 @@ function AUTOPURGE_ADD_POINTS($uid, $points) {
                        array($target, $target, $points, bigintval($uid)), __FUNCTION__, __LINE__);
 
                // Update mediadata as well
-               if ((GET_EXT_VERSION("mediadata") >= "0.0.4") && ($target == "points")) {
+               if ((GET_EXT_VERSION('mediadata') >= '0.0.4') && ($target == "points")) {
                        // Update database
-                       MEDIA_UPDATE_ENTRY(array("total_points"), "add", $points);
+                       MEDIA_UPDATE_ENTRY(array('total_points'), 'add', $points);
                }
 
                // Send out mail to user
index a193cfad6789dc45207536e6313d8b6efe62638a..316d9e962929f65911a49ff78d320aff89ba6542 100644 (file)
@@ -49,14 +49,14 @@ function BEG_ADD_POINTS ($uid, $points) {
        if ((getConfig('ref_payout') > 0) && (getConfig('allow_direct_pay') != "Y")) $locked = true;
 
        // Is begging rallye active?
-       if (getConfig('beg_rallye') == "Y") {
+       if (getConfig('beg_rallye') == 'Y') {
                // Add points to rallye account
                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET beg_points=beg_points+%s WHERE userid=%s LIMIT 1",
                        array($points, $uid), __FUNCTION__, __LINE__);
        } else {
                // Add points to account
                unset($GLOBALS['ref_level']);
-               ADD_POINTS_REFSYSTEM("beg", $uid, $points, false, "0", $locked, strtolower(getConfig('beg_mode')));
+               ADD_POINTS_REFSYSTEM('beg', $uid, $points, false, "0", $locked, strtolower(getConfig('beg_mode')));
        }
 
        // Subtract begged points from member account if the admin has selected one
index 20b488369ab28a33c3ff8dae9fc64e6e1746bbd8..ff52fbfbe1fd0cca4722954f0ad30c561ed69b81 100644 (file)
@@ -48,18 +48,18 @@ function BONUS_ADD_TURBO_POINTS ($mid, $uid, $type) {
        if (getConfig('bonus_active') != "Y") return false;
 
        // Init variables
-       $sql = ""; $bonys = 0; $mail = 0; $column = "";
+       $sql = ''; $bonys = 0; $mail = 0; $column = '';
 
        // Select SQL command
        switch ($type)
        {
-       case "bonusid":
-               $column = "bonus_id";
+       case 'bonusid':
+               $column = 'bonus_id';
                $bonus = $mid;
                break;
 
-       case "mailid" :
-               $column = "mail_id";
+       case 'mailid' :
+               $column = 'mail_id';
                $mail = $mid;
                break;
 
@@ -93,7 +93,7 @@ function BONUS_ADD_TURBO_POINTS ($mid, $uid, $type) {
                $points = getConfig('turbo_bonus');
        } else {
                // Anything else so let's explode all entered rank points
-               $test = explode(";", getConfig('turbo_rates'));
+               $test = explode(';', getConfig('turbo_rates'));
                if (!empty($test[$rank - 2])) {
                        // Level found
                        $points = $test[$rank - 2];
@@ -111,14 +111,14 @@ function BONUS_ADD_TURBO_POINTS ($mid, $uid, $type) {
        SQL_QUERY_ESC("INSERT INTO `{!_MYSQL_PREFIX!}_bonus_turbo` (userid, mail_id, bonus_id, level, points, timemark) VALUES ('%s', '%s', '%s', '%s', '%s', UNIX_TIMESTAMP())",
                array(bigintval($uid), bigintval($mail), bigintval($bonus), $rank, $points), __FUNCTION__, __LINE__);
 
-       if ((GET_EXT_VERSION("bonus") >= "0.3.5") && (getConfig('bonus_mode') != "ADD") && ($points > 0)) BONUS_POINTS_HANDLER($points);
+       if ((GET_EXT_VERSION('bonus') >= '0.3.5') && (getConfig('bonus_mode') != "ADD") && ($points > 0)) BONUS_POINTS_HANDLER($points);
 }
 //
 function BONUS_MAKE_RANK_ROWS ($data, $type, $uid) {
-       $self = false; $OUT = "";
+       $self = false; $OUT = '';
 
        // How many ranks do we have?
-       $ranks = count(explode(";", getConfig('turbo_rates'))) + 1;
+       $ranks = count(explode(';', getConfig('turbo_rates'))) + 1;
 
        // Load current user's data
        $result = SQL_QUERY_ESC("SELECT level, points, timemark FROM `{!_MYSQL_PREFIX!}_bonus_turbo` WHERE %s=%s AND userid=%s LIMIT 1",
@@ -184,7 +184,7 @@ function BONUS_MAKE_RANK_ROWS ($data, $type, $uid) {
     <div class=\"guest_failed\">".sprintf(getMessage('BONUS_NO_RANKS'), $data)."</div>
   </td>
 </tr>\n";
-               define('__YOUR_RANKING_LINE', "");
+               define('__YOUR_RANKING_LINE', '');
        }
        return $OUT;
 }
@@ -241,7 +241,7 @@ function BONUS_PURGE_EXPIRED_TURBO_BONUS() {
        $result = SQL_QUERY("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_bonus_turbo` WHERE timemark < (UNIX_TIMESTAMP() - ".getConfig('bonus_timeout').")", __FUNCTION__, __LINE__);
        if (SQL_AFFECTEDROWS() > 0) {
                // Send out email to admin
-               SEND_ADMIN_NOTIFICATION(AUTOPURGE_ADMIN_TURBO_SUBJECT, "admin_autopurge_turbo", SQL_AFFECTEDROWS(), "");
+               SEND_ADMIN_NOTIFICATION(AUTOPURGE_ADMIN_TURBO_SUBJECT, "admin_autopurge_turbo", SQL_AFFECTEDROWS(), '');
        }
 }
 //
index 04a237d2f52a984b9c33d723b5727bf4f3bf50ca..fc7167a107f89e800935bc6cd5ca48ba0057323d 100644 (file)
@@ -46,7 +46,7 @@ if (!defined('__SECURITY')) {
 // Add a record entry ("mode" can be add/sub!)
 function ADD_BOOKING_RECORD ($subject, $uid, $points, $mode) {
        // Is the sql_patches updated?
-       if (EXT_VERSION_IS_OLDER("sql_patches", "0.5.7")) {
+       if (EXT_VERSION_IS_OLDER('sql_patches', '0.5.7')) {
                // Abort here
                return;
        } // END - if
index afae515b3e16625c145946b9e7b1c266575102a1..f6bcdfcb5dc0d4ce6551f1454350f3f74481267b 100644 (file)
@@ -45,47 +45,54 @@ if (!defined('__SECURITY')) {
 // Caching class
 class CacheSystem {
        // Define variables
-       var $ret = "init";
-       var $path = "";
-       var $inc = "";
-       var $fqfn = "";
+       var $ret = 'init';
+       var $path = '';
+       var $inc = '';
+       var $fqfn = '';
        var $pointer = false;
        var $data = array();
        var $version = array();
-       var $name = "";
+       var $name = '';
        var $rebuilt = array();
+       var $extension = '.cache';
+       var $statusDone = 'done';
 
        // Constructor
        function CacheSystem ($interval, $path, $tested) {
                // Failed is the default
-               $this->ret = "failed";
+               $this->ret = 'failed';
 
                // Remeber path
                $this->path = $path;
 
                // Check if path exists
                if ((isDirectory($path)) && (!$tested)) {
+                       // Make FQFN for dummy file
+                       $fqfn = $path . 'dummy.tmp';
+
                        // Check if we can create a file inside the path
-                       touch($path."dummy.tmp", 'w');
-                       if (FILE_READABLE($path."dummy.tmp")) {
+                       touch($fqfn, 'w');
+
+                       // Is the file there?
+                       if (FILE_READABLE($fqfn)) {
                                // Yes, we can do. So let's remove it
-                               unlink($path."dummy.tmp");
+                               unlink($fqfn);
 
                                // Is there a .htaccess file?
-                               if (FILE_READABLE($path.".htaccess")) {
+                               if (FILE_READABLE($path . '.htaccess')) {
                                        // Update database that we have tested it
-                                       UPDATE_CONFIG("cache_tested", 1);
+                                       UPDATE_CONFIG('cache_tested', 1);
 
                                        // All done!
-                                       $this->ret = "done";
+                                       $this->ret = $this->statusDone;
                                } else {
                                        // Stop! Set a .htaccess file first
-                                       $this->ret = "htaccess";
+                                       $this->ret = 'htaccess';
                                }
                        }
                } elseif ($tested) {
                        // System already tested
-                       $this->ret = "done";
+                       $this->ret = $this->statusDone;
                }
        }
 
@@ -95,13 +102,13 @@ class CacheSystem {
                $this->name = $cacheName;
 
                // Construct include filename for LOAD_INC_ONCE() call
-               $this->inc = $this->path . $cacheName . ".cache";
+               $this->inc = $this->path . $cacheName . $this->extension;
 
                // Construct FQFN (full qualified file name)
                $this->fqfn = constant('PATH') . $this->inc;
 
                // Check if file exists and if version matches
-               $status = ($this->isCacheReadable() && (is_writeable($this->fqfn)) && ($this->extensionVersionMatches("cache")));
+               $status = ($this->isCacheReadable() && (is_writeable($this->fqfn)) && ($this->extensionVersionMatches('cache')));
 
                // Return status
                return $status;
@@ -110,7 +117,7 @@ class CacheSystem {
        // Initializes the cache file
        function init () {
                // This will destory an existing cache file!
-               if ($this->ret == "done") {
+               if ($this->ret == $this->statusDone) {
                        // Create file
                        if ($this->isCacheReadable()) chmod($this->fqfn, 0666);
                        $this->pointer = fopen($this->fqfn, 'w') or app_die(__METHOD__, __LINE__, "Cannot write to cache ".$this->fqfn." !");
@@ -119,7 +126,7 @@ class CacheSystem {
                        fwrite($this->pointer, "<?php\n");
 
                        // Add default depency
-                       $this->storeExtensionVersion("cache");
+                       $this->storeExtensionVersion('cache');
                } else {
                        // Cannot create file
                        addFatalMessage(__METHOD__, __LINE__, "(<font color=\"#0000aa\">".__LINE__."</font>): ".getMessage('CACHE_PROBLEMS_DETECTED'));
@@ -132,13 +139,13 @@ class CacheSystem {
                        // Write every array element to cache file
                        foreach ($data as $k => $v) {
                                // Write global cache array for immediate access
-                               if ((substr($k, 0, 4) == "ext_") && (isset($data['ext_name'])) && (isset($data['ext_id']))) {
-                                       if ($k != "ext_name") {
+                               if ((substr($k, 0, 4) == 'ext_') && (isset($data['ext_name'])) && (isset($data['ext_id']))) {
+                                       if ($k != 'ext_name') {
                                                $GLOBALS['cache_array']['extensions'][$k][$data['ext_name']] = $v;
                                        } else {
                                                $GLOBALS['cache_array']['extensions'][$k][$data['ext_id']] = $v;
                                        }
-                                       if (($k == "ext_keep") && ($v == "Y")) {
+                                       if (($k == 'ext_keep') && ($v == 'Y')) {
                                                $GLOBALS['cache_array']['active_extensions'][$data['ext_name']] = $v;
                                        } // END - if
                                } elseif (is_array($v)) {
@@ -278,7 +285,7 @@ class CacheSystem {
                        foreach ($array as $k => $v) {
                                if (is_array($v)) {
                                        // Multi line(s) found
-                                       $LINE = "";
+                                       $LINE = '';
                                        foreach($v as $k2 => $v2) {
                                                // Put every array element in a row...
                                                $LINE .= $this->rewriteEntry($k, $v2);
@@ -377,7 +384,7 @@ class CacheSystem {
        // @TODO Add support for more types which break in last else-block
        function rewriteEntry ($key, $value) {
                // Init line
-               $line = "";
+               $line = '';
 
                // String or non-string? ;-)
                if (is_string($value)) {
@@ -422,9 +429,9 @@ function FILTER_CACHE_DESTROY_ON_EXT_CHANGE ($data) {
        if (!isCacheInstanceValid()) return $data;
 
        // Remove cache
-       if ($GLOBALS['cache_instance']->loadCacheFile("config"))     $GLOBALS['cache_instance']->destroyCacheFile();
-       if ($GLOBALS['cache_instance']->loadCacheFile("extensions")) $GLOBALS['cache_instance']->destroyCacheFile();
-       if ($GLOBALS['cache_instance']->loadCacheFile("modreg"))     $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('config'))     $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('extensions')) $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('modreg'))     $GLOBALS['cache_instance']->destroyCacheFile();
 
        // Return it
        return $data;
@@ -436,7 +443,7 @@ function FILTER_CACHE_DESTROY_ON_ADMIN_CHANGE () {
        if (!isCacheInstanceValid()) return false;
 
        // Remove cache
-       if ($GLOBALS['cache_instance']->loadCacheFile("admins")) $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('admins')) $GLOBALS['cache_instance']->destroyCacheFile();
 }
 
 // Destroy all cache files
@@ -445,15 +452,15 @@ function FILTER_CACHE_DESTROY_ALL () {
        if (!isCacheInstanceValid()) return false;
 
        // Remove cache files
-       if ($GLOBALS['cache_instance']->loadCacheFile("admins"))      $GLOBALS['cache_instance']->destroyCacheFile();
-       if ($GLOBALS['cache_instance']->loadCacheFile("admins_acls")) $GLOBALS['cache_instance']->destroyCacheFile();
-       if ($GLOBALS['cache_instance']->loadCacheFile("config"))      $GLOBALS['cache_instance']->destroyCacheFile();
-       if ($GLOBALS['cache_instance']->loadCacheFile("extensions"))  $GLOBALS['cache_instance']->destroyCacheFile();
-       if ($GLOBALS['cache_instance']->loadCacheFile("modreg"))      $GLOBALS['cache_instance']->destroyCacheFile();
-       if ($GLOBALS['cache_instance']->loadCacheFile("refdepths"))   $GLOBALS['cache_instance']->destroyCacheFile();
-       if ($GLOBALS['cache_instance']->loadCacheFile("refsystem"))   $GLOBALS['cache_instance']->destroyCacheFile();
-       if ($GLOBALS['cache_instance']->loadCacheFile("themes"))      $GLOBALS['cache_instance']->destroyCacheFile();
-       if ($GLOBALS['cache_instance']->loadCacheFile("revision"))    $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('admins'))      $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('admins_acls')) $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('config'))      $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('extensions'))  $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('modreg'))      $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('refdepths'))   $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('refsystem'))   $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('themes'))      $GLOBALS['cache_instance']->destroyCacheFile();
+       if ($GLOBALS['cache_instance']->loadCacheFile('revision'))    $GLOBALS['cache_instance']->destroyCacheFile();
 }
 
 // Filter for purging entire admin menu cache
index a6b0d5159428682c49d90fb0d6340fda4ae84594..f906b9798a811cef776f794f63a133fec1641910 100644 (file)
@@ -46,19 +46,19 @@ if (!defined('__SECURITY')) {
 // @TODO Lame description
 function DOUBLER_GENERATE_TABLE ($uid="0", $done='N', $ref='N', $sort="ASC") {
        if (empty($cnt)) $cnt = 0;
-       $add = ""; $DT_MODE = 0;
+       $add = ''; $DT_MODE = 0;
        if ($uid > 0) {
                // Load entries only from a single user
                $add = " AND userid='".bigintval($uid)."'";
-               $MODE = "member"; $COLS = "4"; $DT_MODE = "2";
+               $MODE = 'member'; $COLS = "4"; $DT_MODE = "2";
                $NOT_FOUND = getMessage('DOUBLER_MEMBER_NO_ENTRIES_FOUND');
        } else {
                // Guest mode!
-               $MODE = "guest"; $COLS = "3"; $DT_MODE = "3";
+               $MODE = 'guest'; $COLS = "3"; $DT_MODE = "3";
                $NOT_FOUND = getMessage('DOUBLER_GUEST_NO_ENTRIES_FOUND');
        }
 
-       if (($done == "Y") && ($sort == "ASC")) {
+       if (($done == 'Y') && ($sort == "ASC")) {
                // Already payed out points (latest payouts first)
                $limit = getConfig('doubler_display_old');
        } elseif ($sort == "ASC") {
@@ -78,7 +78,7 @@ LIMIT ".$limit, __FUNCTION__, __LINE__);
 
        if (SQL_NUMROWS($result) > 0) {
                // List entries
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Rewrite userid/refid only if admin is in
                        if (IS_ADMIN()) {
@@ -107,7 +107,7 @@ LIMIT ".$limit, __FUNCTION__, __LINE__);
                // List no entries
                $OUT = "<tr>
   <td colspan=\"".$COLS."\" align=\"center\" class=\"doubler_big_row bottom2\">
-    ".LOAD_TEMPLATE("admin_settings_saved", true, $NOT_FOUND)."
+    ".LOAD_TEMPLATE('admin_settings_saved', true, $NOT_FOUND)."
   </td>
 </tr>\n";
        }
@@ -121,12 +121,12 @@ function DOUBLER_GET_TOTAL_POINTS_LEFT() {
        // Initialize variables
        $points = 0;
 
-       if (getConfig('doubler_own') == "Y") {
+       if (getConfig('doubler_own') == 'Y') {
                // Take points from doubler's own account
                $points += getConfig('doubler_points') - getConfig('doubler_used');
        }
 
-       if (getConfig('doubler_jackpot') == "Y") {
+       if (getConfig('doubler_jackpot') == 'Y') {
                // Load jackpot
                $result = SQL_QUERY("SELECT points FROM `{!_MYSQL_PREFIX!}_jackpot` WHERE ok='ok' LIMIT 1", __FUNCTION__, __LINE__);
                list($jackpot) = SQL_FETCHROW($result);
index 2f2ccaca3044186aeabff04a93aa85f764eb38e2..8ad8cd0dbad0df711979e9fcd0552d67dcb58640 100644 (file)
@@ -51,7 +51,7 @@ WHERE holiday_end <= UNIX_TIMESTAMP()
 ORDER BY userid", __FUNCTION__, __LINE__);
        if (SQL_NUMROWS($result_stop) > 0) {
                // We foud at least one
-               $admin = "";
+               $admin = '';
                // Init SQLs
                INIT_SQLS();
 
index d7273b06278f6f79ff695a1a15beccdad64e2c44..25c4a0102f4eda0dbe1fc16eab678e5df40ab125 100644 (file)
@@ -44,7 +44,7 @@ if (!defined('__SECURITY')) {
 
 //
 function HTML_ADD_VALID_TAGS() {
-       $OUT = "";
+       $OUT = '';
        if (!is_array($GLOBALS['html_tags'])) return "";
        foreach ($GLOBALS['html_tags'] as $tag) {
                $OUT .= ", ".strtoupper($tag);
@@ -57,7 +57,7 @@ function HTML_CHECK_TAGS ($html) {
        $test = stripslashes($html);
        while (ereg("<", $test) && ereg(">", $test)) {
                $check = strtolower(substr($test, strpos($test, "<") + 1, strpos($test, ">") - strpos($test, "<") - 1));
-               $check = str_replace("/", "", $check);
+               $check = str_replace("/", '', $check);
                if (!in_array($check, $GLOBALS['html_tags'])) {
                        // Invalid tag found!
                        return "";
@@ -142,7 +142,7 @@ function HTML_INSERT_URLS ($text) {
        }
 
        // Now put all parts together
-       $text = ""; $PARTS[] = $test;
+       $text = ''; $PARTS[] = $test;
        foreach ($PARTS as $part) {
                $text .= $part;
        }
@@ -153,7 +153,7 @@ function HTML_INSERT_URLS ($text) {
 
 //
 function SEND_HTML_EMAIL($to, $subject, $message, $FROM) {
-       if (EXT_IS_ACTIVE("html_mail")) {
+       if (EXT_IS_ACTIVE('html_mail')) {
                // Send mail away as HTML
                $FROM = "Content-Type: text/html\n".$FROM;
                SEND_EMAIL($to, $subject, $message, 'N', $FROM);
index b85c9d33deaa11f229f472e285c08e8aadf21dd2..1b66dcee84c0e0a78e64550b1223baa0f4f63fc2 100644 (file)
@@ -64,8 +64,8 @@ WHERE media_key = '%s' LIMIT 1", array($key), __FUNCTION__, __LINE__);
                                // Update entry
                                switch ($mode)
                                {
-                                       case "add": $mode = "+"; break;
-                                       case "sub": $mode = "-"; break;
+                                       case 'add': $mode = "+"; break;
+                                       case 'sub': $mode = "-"; break;
                                }
                                if ($mode == "init")
                                {
@@ -87,7 +87,7 @@ WHERE media_key = '%s' LIMIT 1", array($key), __FUNCTION__, __LINE__);
 function MEDIA_GET_ENTRY($key)
 {
        // Return nothing by default
-       $value = "";
+       $value = '';
 
        // Check for entry
        $result = SQL_QUERY_ESC("SELECT media_value FROM `{!_MYSQL_PREFIX!}_mediadata` WHERE media_key='%s' LIMIT 1",
index ba15c4c4c25d1d9483176bc2101aea4d31829cb9..1d249d29d49641c49e4770469d85c8da7f10c56b 100644 (file)
@@ -44,7 +44,7 @@ if (!defined('__SECURITY')) {
 
 //
 function NL_ADD_VALID_TAGS () {
-       $OUT = "";
+       $OUT = '';
        if (!is_array($GLOBALS['html_tags'])) return "";
        foreach ($GLOBALS['html_tags'] as $tag) {
                $OUT .= ", ".strtoupper($tag);
@@ -58,7 +58,7 @@ function NL_CHECK_TAGS ($html) {
        $test = stripslashes($html);
        while (ereg("<", $test) && ereg(">", $test)) {
                $check = strtolower(substr($test, strpos($test, "<") + 1, strpos($test, ">") - strpos($test, "<") - 1));
-               $check = str_replace("/", "", $check);
+               $check = str_replace("/", '', $check);
                if (!in_array($check, $GLOBALS['html_tags'])) {
                        // Invalid tag found!
                        return "";
@@ -143,7 +143,7 @@ function NL_INSERT_URLS ($text) {
        }
 
        // Now put all parts together
-       $text = ""; $PARTS[] = $test;
+       $text = ''; $PARTS[] = $test;
        foreach ($PARTS as $part) {
                $text .= $part;
        }
@@ -155,9 +155,9 @@ function NL_INSERT_URLS ($text) {
 //
 function SEND_NEWSLETTER ($to, $subject, $message, $MODE) {
        // Send mail away as HTML
-       if (REQUEST_POST('auto_urls') == "Y") {
+       if (REQUEST_POST('auto_urls') == 'Y') {
                // Automatically insert URLs into newsletter
-               if ((EXT_IS_ACTIVE("html")) && ($MODE == "html")) {
+               if ((EXT_IS_ACTIVE('html_mail')) && ($MODE == 'html')) {
                        // Send HTML mail
                        SEND_EMAIL($to, $subject, HTML_INSERT_URLS($message), "Y");
                } else {
@@ -166,7 +166,7 @@ function SEND_NEWSLETTER ($to, $subject, $message, $MODE) {
                }
        } else {
                // Regular send-out
-               if ((EXT_IS_ACTIVE("html")) && ($MODE == "html")) {
+               if ((EXT_IS_ACTIVE('html_mail')) && ($MODE == 'html')) {
                        SEND_EMAIL($to, $subject, $message, "Y");
                } else {
                        SEND_EMAIL($to, $subject, $message, "N");
index a569199d573cccd28e9ae30c07f3768c422d944c..be934a382beacf557abed0290f5d3cd3b0a0b690 100644 (file)
@@ -77,7 +77,7 @@ function NICKNAME_IS_ACTIVE ($uidNick) {
 //
 function NICKNAME_GET_NICK ($userid) {
        // If not found...
-       $ret = "";
+       $ret = '';
 
        // Found in cache?
        if (isset($GLOBALS['cache_array']['nicknames'][$userid])) {
index c65a4953f7a17208a4138f5a839734495cbe7e83..c84d4bf66addb2897128229914b7dad33260158b 100644 (file)
@@ -45,7 +45,7 @@ if (!defined('__SECURITY')) {
 // Filter for updates/extends on the online list
 function FILTER_UPDATE_ONLINE_LIST () {
        // Do not update online list when extension is deactivated
-       if (!EXT_IS_ACTIVE("online", true)) return;
+       if (!EXT_IS_ACTIVE('online', true)) return;
 
        // Empty session?
        if (session_id() == "") {
index 5b6181940a99d7809b67fe7615f09fdf6edec117..d36639a046c7f5312f989759a3742315b5488b90 100644 (file)
@@ -44,10 +44,10 @@ if (!defined('__SECURITY')) {
 
 function ORDER_SELECT_OPTION_LIST($default) {
        // Currenty the list is hardcoded...
-       $LIST = array("userid", "zip", "country", "email", "birth_year", "last_online", "ref_clicks", "total_logins", "mail_orders");
-       $OUT = "";
+       $LIST = array('userid', "zip", 'country', 'email', "birth_year", "last_online", "ref_clicks", "total_logins", "mail_orders");
+       $OUT = '';
        foreach ($LIST as $item) {
-               $selected = "";
+               $selected = '';
                if ($item == $default) $selected = " selected=\"selected\"";
                $OUT .= "<option value=\"".$item."\"".$selected.">{--ORDER_SELECT_COLUMN_".strtoupper($item)."--}</option>\n";
        }
index b96b4d2f9c402eaebb03ba6742a0f89aca7665cf..e52aa4941a54576c8bb66be602137b7e0306dca1 100644 (file)
@@ -74,14 +74,14 @@ ORDER BY type", array($points), __FUNCTION__, __LINE__);
                        OUTPUT_HTML("</ul></div>");
                } else {
                        // No payout types setup so far
-                       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"guest_failed\">{--PAYOUT_NO_PAYOUT_TYPES--}</div");
+                       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"guest_failed\">{--PAYOUT_NO_PAYOUT_TYPES--}</div");
                }
 
                // Free memory
                SQL_FREERESULT($result);
        } else {
                // Points is empty
-               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"guest_failed\">{--PAYOUT_NO_POINTS_ENTERED--}</div");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"guest_failed\">{--PAYOUT_NO_POINTS_ENTERED--}</div");
        }
 }
 
index 0ca43bcfecf08d0937f1c4b793186238612b8f4b..1d2cee613bca845bb3e6af4cd61c65bb43465076 100644 (file)
@@ -220,7 +220,7 @@ class PrimeraApi {
 
                $this->data = $postReturn;
                if ($postReturn["status"] == self::PI_GET_PRIMERA_DONE) {
-                       $primera = $postReturn["primera"];
+                       $primera = $postReturn['primera'];
                }
                return $primera;
        }
@@ -244,7 +244,7 @@ function PRIMERA_TEST_API () {
 // Execute the withdraw of a sponsor only!
 function PRIMERA_EXECUTE_WITHDRAW ($primusNick, $userMd5, $amount) {
        // Is the sponsor extension installed?
-       if (!EXT_IS_ACTIVE("sponsor")) {
+       if (!EXT_IS_ACTIVE('sponsor')) {
                // No, abort here
                return false;
        } elseif (!IS_SPONSOR()) {
index 5f83e14adb02a01323a6592f662192fd766041c9..9b466ebb962bd859d42a3764b69c6fc3e4967dfc 100644 (file)
@@ -112,7 +112,7 @@ VALUES ('%s','%s','%s','%s')",
                $DATA['refs']  = $cnt;
 
                // Shall I notify this member?
-               if (($notify == "Y") && ($un)) {
+               if (($notify == 'Y') && ($un)) {
                        // Load email template and send it to the user
                        $msg = LOAD_EMAIL_TEMPLATE("member_rallye_notify", array('prices' => $prices), $content['userid']);
                        SEND_EMAIL($content['userid'], sprintf(getMessage('RALLYE_MEMBER_NOTIFY'), $title), $msg);
@@ -121,7 +121,7 @@ VALUES ('%s','%s','%s','%s')",
 
        // Choose the right admin template
        $templ = "admin_rallye_no_notify";
-       if ($notify == "Y") $templ = "admin_rallye_notify";
+       if ($notify == 'Y') $templ = "admin_rallye_notify";
 
        // Send email to admin
        SEND_ADMIN_NOTIFICATION(sprintf(getMessage('RALLYE_ADMIN_NOTIFY'), $title), $templ, $prices, "0");
@@ -130,11 +130,11 @@ VALUES ('%s','%s','%s','%s')",
        SQL_FREERESULT($result_user);
 }
 //
-function RALLYE_ADD_PRICES ($rallye, $mode="email") {
+function RALLYE_ADD_PRICES ($rallye, $mode='email') {
        // Output mode
        switch($mode) {
-               case "email": $mode = "\n";     break;
-               case "html" : $mode = "<br />\n"; break;
+               case 'email': $mode = "\n";     break;
+               case 'html' : $mode = "<br />\n"; break;
        }
 
        // Load prices
@@ -142,7 +142,7 @@ function RALLYE_ADD_PRICES ($rallye, $mode="email") {
        if (SQL_NUMROWS($result_prices) > 0) {
                // Load prices
                if ($mode == "\n") $prices = "{--RALLYE_MEMBER_PRICES_ADDED--}:".$mode."------------------------------".$mode;
-               $prices = "";
+               $prices = '';
                while ($content = SQL_FETCHARRAY($result_prices)) {
                        $prices .= $content['price_level'].getMessage('RALLYE_PRICE').": ";
                        if (!empty($content['info'])) {
@@ -208,7 +208,7 @@ LIMIT 1", array(bigintval($content['userid']), getConfig('ref_payout')), __FUNCT
                $_uid = "---";
                // List only users with at least one ref!
                //* DEBUG: */ echo "*".$cnt."/".$content['userid']."/".$content['curr_points']."/".$refpoints."*<br />\n";
-               if (($cnt > 0) && ($refpoints > $content['curr_points'])) { $_uid = $content['userid']; } else { $cnt = ""; }
+               if (($cnt > 0) && ($refpoints > $content['curr_points'])) { $_uid = $content['userid']; } else { $cnt = ''; }
 
                // Save values to array
                $DATA['uid'][]     = $_uid;
@@ -254,10 +254,10 @@ LIMIT 1", array(bigintval($content['userid']), getConfig('ref_payout')), __FUNCT
 // Run this function only when a new member has confirmed his email address!
 function RALLYE_AUTOADD_USER ($uid) {
        global $DATA;
-       $add = "";
+       $add = '';
 
        // Updated extension?
-       if (GET_EXT_VERSION("rallye") >= "0.2.0") {
+       if (GET_EXT_VERSION('rallye') >= '0.2.0') {
                $add .= ", min_users, min_prices";
        } // END - if
 
@@ -267,7 +267,7 @@ function RALLYE_AUTOADD_USER ($uid) {
                // Init variables
                $min_users = 0; $min_prices = 0;
                // Load data
-               if (GET_EXT_VERSION("rallye") >= "0.2.0") {
+               if (GET_EXT_VERSION('rallye') >= '0.2.0') {
                        list($id, $title, $start, $end, $notify, $min_users, $min_prices) = SQL_FETCHROW($result);
                } else {
                        list($id, $title, $start, $end, $notify) = SQL_FETCHROW($result);
@@ -291,7 +291,7 @@ VALUES ('%s','%s','0')",
                        SQL_FREERESULT($result);
                }
 
-               if ($notify == "Y") {
+               if ($notify == 'Y') {
                        // Transfer all neccessary data to the global $DATA array
                        $DATA['start'] = MAKE_DATETIME($start, "2");
                        $DATA['end']   = MAKE_DATETIME($end  , "2");
@@ -299,7 +299,7 @@ VALUES ('%s','%s','0')",
                        $DATA['title'] = $title;
                        $DATA['id']    = $id;  // ID for the rallye details link
                        $DATA['ref']   = 0;
-                       $DATA['refs']  = GET_TOTAL_DATA($uid, "user_data", "userid", "refid", true);
+                       $DATA['refs']  = GET_TOTAL_DATA($uid, "user_data", 'userid', "refid", true);
 
                        // Load prices
                        $prices = RALLYE_ADD_PRICES($id);
@@ -376,7 +376,7 @@ LIMIT 1", array(bigintval($uid)), __FUNCTION__, __LINE__);
                        $DATA['ref']    = $prices['ref'][$key];
 
                        // Default is other
-                       $winnerLevel = "other";
+                       $winnerLevel = 'other';
 
                        // Determine winner level
                        if ($DATA['level'] == 1) {
@@ -395,7 +395,7 @@ LIMIT 1", array(bigintval($uid)), __FUNCTION__, __LINE__);
                                ADD_POINTS_REFSYSTEM("rallye_winner" . $winnerLevel, $uid, $DATA['points'], false, "0", false, "direct");
                        } // END - if
 
-                       if ($notify == "Y") {
+                       if ($notify == 'Y') {
                                // Prepare infos for the mail template
                                if (!empty($DATA['info'])) {
                                        // Take direct infos
@@ -421,7 +421,7 @@ LIMIT 1", array(bigintval($uid)), __FUNCTION__, __LINE__);
        } // END - foreach
 
        // Select template depending on notfication is switch on / off
-       if ($notify == "Y") {
+       if ($notify == 'Y') {
                $templ = "admin_rallye_expired";
        } elseif (is_array($users['uid'])) {
                $templ = "admin_rallye_expired_no";
@@ -445,7 +445,7 @@ function RALLYE_LOAD_USER_DATA ($uids_array) {
        $uid_string = implode(",", $uids_array['uid']);
 
        // Init result string
-       $ret = "";
+       $ret = '';
 
        // Load users
        $result = SQL_QUERY_ESC("SELECT userid, gender, surname, family, email FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid IN(%s) AND `status`='CONFIRMED' ORDER BY userid LIMIT %s",
@@ -594,7 +594,7 @@ function RALLYE_LIST_WINNERS ($rallye, $default=0) {
                }
 
                // Add row
-               $add = "";
+               $add = '';
                $OUT .= "<tr>
   <td class=\"switch_sw".$SW." bottom2".$add."\">&nbsp;&nbsp;".($idx+1).".</td>
   <td align=\"center\" class=\"switch_sw".$SW." bottom2".$add."\">";
@@ -647,7 +647,7 @@ WHERE end_time <= (UNIX_TIMESTAMP() - %s) AND expired='Y'",
                        $DATA['now_t']  = MAKE_DATETIME(time(), "1");
 
                        // Send mail to admin
-                       SEND_ADMIN_NOTIFICATION(sprintf(getMessage('RALLYE_ADMIN_PURGED_SUBJ'), $content['title']), "admin_rallye_purged", "", 0);
+                       SEND_ADMIN_NOTIFICATION(sprintf(getMessage('RALLYE_ADMIN_PURGED_SUBJ'), $content['title']), "admin_rallye_purged", '', 0);
 
                        // Purge whole rallye
                        ADD_SQL(SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_rallye_data` WHERE id=%s LIMIT 1",
@@ -675,7 +675,7 @@ VALUES ('NEW','RALLYE_PURGED','{--RALLYE_ADMIN_PURGED--}: %s','{--RALLYE_ADMIN_P
 //
 function RALLYE_TEMPLATE_SELECTION ($name="template", $default="") {
        // Check templates directory
-       $OUT = ""; $ral = array();
+       $OUT = ''; $ral = array();
        $BASE = sprintf("%stemplates/%s/html/rallye/", constant('PATH'), GET_LANGUAGE());
        $dir = opendir($BASE);
        while ($read = readdir($dir)) {
@@ -716,7 +716,7 @@ function RALLYE_TEMPLATE_SELECTION ($name="template", $default="") {
 //
 function RALLYE_GET_REFCOUNT ($uid, $old=0) {
        // Check current refs
-       if (GET_EXT_VERSION("cache") >= "0.1.2") {
+       if (GET_EXT_VERSION('cache') >= '0.1.2') {
                // Get refs from cache
                $cnt = 0;
                foreach ($GLOBALS['cache_array']['refsystem']['userid'] as $id => $uid) {
index 6aa46577df27142130d9def478c116f5e022c3e9..28df7297a50ba35799de704bf11012ffbf0a571a 100644 (file)
@@ -249,10 +249,10 @@ function UPDATE_REFBACK_TABLE ($uid) {
        } // END - if
 
        // When he has a referal...
-       if ((($GLOBALS['cache_array']['up_refid'][$GLOBALS['cache_array']['back_level']] == $uid) || ($GLOBALS['cache_array']['up_refid'][$GLOBALS['cache_array']['back_level']] == 0)) && (GET_EXT_VERSION("cache") >= "0.1.2") && (!isset($GLOBALS['cache_array']['back_cached']))) {
+       if ((($GLOBALS['cache_array']['up_refid'][$GLOBALS['cache_array']['back_level']] == $uid) || ($GLOBALS['cache_array']['up_refid'][$GLOBALS['cache_array']['back_level']] == 0)) && (GET_EXT_VERSION('cache') >= '0.1.2') && (!isset($GLOBALS['cache_array']['back_cached']))) {
                // Remove cache here
                //* DEBUG: */ print __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>):uid={$uid},ref={$GLOBALS['cache_array']['up_refid'][$GLOBALS['cache_array']['back_level']]} - CACHE!<br />\n";
-               if ($GLOBALS['cache_instance']->loadCacheFile("refback")) $GLOBALS['cache_instance']->destroyCacheFile();
+               if ($GLOBALS['cache_instance']->loadCacheFile('refback')) $GLOBALS['cache_instance']->destroyCacheFile();
                $GLOBALS['cache_array']['back_cached'] = 1;
        } // END - if
 
@@ -270,11 +270,11 @@ function UPDATE_REFBACK_TABLE ($uid) {
 function GET_USER_REFS ($uid, $level) {
        //* DEBUG: */ print "----------------------- <font color=\"#00aa00\">".__FUNCTION__." - ENTRY</font> ------------------------<ul><li>\n";
        // Default is no refs and no nickname
-       $add = "";
+       $add = '';
        $refs = array();
 
        // Do we have nickname extension installed?
-       if (EXT_IS_ACTIVE("nickname")) {
+       if (EXT_IS_ACTIVE('nickname')) {
                $add = ", d.nickname";
        } // END - if
 
index aa0ea1baf50f15528a477b178c3964e9b959cfb1..7630933ab70f1f91c449a15f931e4db573fb3f21 100644 (file)
@@ -48,8 +48,8 @@ function REGISTER_FILL_MUST_CONSTANTS () {
                __FUNCTION__, __LINE__);
 
        while ($content = SQL_FETCHARRAY($result)) {
-               $value = "";
-               if ($content['field_required'] == "Y") $value = "<div class=\\\"guest_failed\\\">&nbsp;(*)</div>";
+               $value = '';
+               if ($content['field_required'] == 'Y') $value = "<div class=\\\"guest_failed\\\">&nbsp;(*)</div>";
                // @TODO Rewrite these constants
                $eval = "define('MUST_".strtoupper($content['field_name'])."', \"".$value."\");";
                eval($eval);
@@ -78,8 +78,8 @@ function REGISTER_CHECK_REQUIRED_FIELDS (&$array) {
                        // Check if extension country is not found (you have to enter the 2-chars long country code) or
                        // if extensions is present check if country code was selected
                        //         01              2         21    12             3         32    234     5      54    4               43    34                      4    4      5      5432    2      3                      3210
-                       $country = ((!EXT_IS_ACTIVE("country")) || ((EXT_IS_ACTIVE("country")) && (((empty($value)) && ($key == "cntry")) || (($key == "country_code") && (!empty($value)))) && (!empty($array['country_code']))));
-                       if ((empty($value)) && ($chk == "Y") && (!$country))
+                       $country = ((!EXT_IS_ACTIVE('country')) || ((EXT_IS_ACTIVE('country')) && (((empty($value)) && ($key == "cntry")) || (($key == "country_code") && (!empty($value)))) && (!empty($array['country_code']))));
+                       if ((empty($value)) && ($chk == 'Y') && (!$country))
                        {
                                // Required field not set
                                $array[$key] = "!";
@@ -97,9 +97,9 @@ function REGISTER_CHECK_REQUIRED_FIELDS (&$array) {
 function REGISTER_OUTPUT_REQUIRE_CHECK (&$array) {
        $result = SQL_QUERY("SELECT field_name, field_required FROM `{!_MYSQL_PREFIX!}_must_register` ORDER BY `id`", __FUNCTION__, __LINE__);
        while ($content = SQL_FETCHARRAY($result)) {
-               if (($array[$content['field_name']] == "!") && ($content['field_required'] == "Y")) {
+               if (($array[$content['field_name']] == "!") && ($content['field_required'] == 'Y')) {
                        // Empty entry found
-                       $array[$content['field_name']] = "";
+                       $array[$content['field_name']] = '';
                        $OUT = constant('REGISTER_'.strtoupper($content['field_name']).'_REQUIRED');
                        OUTPUT_HTML("<div class=\"register_failed\">".$OUT."</div>");
                } // END - if
@@ -111,14 +111,14 @@ function REGISTER_OUTPUT_REQUIRE_CHECK (&$array) {
 
 //
 function REGISTER_ADD_CATEGORY_TABLE ($MODE, $return=false) {
-       $OUT = "";
+       $OUT = '';
 
        // Guests are mostly not interested in how many members has
        // choosen an individual category
        $AND = "WHERE `visible`='Y' ";
 
        // Admins are allowed to see every category...
-       if (IS_ADMIN()) $AND = "";
+       if (IS_ADMIN()) $AND = '';
 
        // Look for categories
        $result = SQL_QUERY("SELECT id, cat, visible FROM `{!_MYSQL_PREFIX!}_cats` ".$AND." ORDER BY `sort`",
@@ -132,7 +132,7 @@ function REGISTER_ADD_CATEGORY_TABLE ($MODE, $return=false) {
                        // Is the array element not set?
                        if (!REQUEST_ISSET_POST('cat', $content['id'])) {
                                // Then set it
-                               REQUEST_SET_POST(array('cat', $content['id']), "");
+                               REQUEST_SET_POST(array('cat', $content['id']), '');
                        } // END - if
 
                        // Prepare array for the template
@@ -144,10 +144,10 @@ function REGISTER_ADD_CATEGORY_TABLE ($MODE, $return=false) {
                                'id'    => $content['id'],
                        );
 
-                       if ((REQUEST_POST('cat', $content['id']) == "Y") || ((getConfig('register_default') == "Y") && (!REQUEST_ISSET_POST('cat', $content['id'])))) {
-                               $content['def_y'] = " checked=\"checked\"";
+                       if ((REQUEST_POST('cat', $content['id']) == 'Y') || ((getConfig('register_default') == 'Y') && (!REQUEST_ISSET_POST('cat', $content['id'])))) {
+                               $content['def_y'] = ' chkecked="checked"';
                        } else {
-                               $content['def_n'] = " checked=\"checked\"";
+                               $content['def_n'] = ' chkecked="checked"';
                        }
 
                        // Load template and switch color
@@ -160,7 +160,7 @@ function REGISTER_ADD_CATEGORY_TABLE ($MODE, $return=false) {
                SQL_FREERESULT($result);
        } else {
                // No categories setted up so far...
-               $OUT .= LOAD_TEMPLATE("admin_settings_saved", true, getMessage('NO_CATEGORIES_VISIBLE'));
+               $OUT .= LOAD_TEMPLATE('admin_settings_saved', true, getMessage('NO_CATEGORIES_VISIBLE'));
        }
 
        if ($return === true) {
index 88182524047aaf59918ee2152c4b3e8038eb5d37..ab59b19cf978e6d95029578a1e546f60d4aede0d 100644 (file)
@@ -45,7 +45,7 @@ if (!defined('__SECURITY')) {
 // "Getter" for anonymous remote IP number
 function GET_ANONYMOUS_REMOTE_ADDR ($remoteAddr) {
        // Is config enabled?
-       if (getConfig('removeip_anon_ip') == "Y") {
+       if (getConfig('removeip_anon_ip') == 'Y') {
                // Switch way do we like?
                switch (getConfig('anonymous_ip')) {
                        case "127.0.0.1": // mod_removeip style
@@ -65,7 +65,7 @@ function GET_ANONYMOUS_REMOTE_ADDR ($remoteAddr) {
 // "Getter" for anonymous remote hostname
 function GET_ANONYMOUS_REMOTE_HOST ($remoteHost) {
        // Is config enabled?
-       if (getConfig('removeip_anon_host') == "Y") {
+       if (getConfig('removeip_anon_host') == 'Y') {
                // Set anon hostname
                $remoteHost = "localhost.localnet";
        } // END - if
@@ -76,7 +76,7 @@ function GET_ANONYMOUS_REMOTE_HOST ($remoteHost) {
 // "Getter" for anonymous user agent
 function GET_ANONYMOUS_USER_AGENT ($userAgent) {
        // Is config enabled?
-       if (getConfig('removeip_anon_ua') == "Y") {
+       if (getConfig('removeip_anon_ua') == 'Y') {
                // Set anon user agent
                $userAgent = "-";
        } // END - if
@@ -87,7 +87,7 @@ function GET_ANONYMOUS_USER_AGENT ($userAgent) {
 // "Getter" for anonymous referer
 function GET_ANONYMOUS_REFERER ($referer) {
        // Is config enabled?
-       if (getConfig('removeip_anon_ref') == "Y") {
+       if (getConfig('removeip_anon_ref') == 'Y') {
                // Set anon user agent
                $referer = "-";
        } // END - if
@@ -101,10 +101,10 @@ function REMOVEIP_ADD_INFOS () {
        $anonymity = 0;
 
        // Is some data anonymized?
-       if (getConfig('removeip_anon_ip')   == "Y") $anonymity++;
-       if (getConfig('removeip_anon_host') == "Y") $anonymity++;
-       if (getConfig('removeip_anon_ua')   == "Y") $anonymity++;
-       if (getConfig('removeip_anon_ref')  == "Y") $anonymity++;
+       if (getConfig('removeip_anon_ip')   == 'Y') $anonymity++;
+       if (getConfig('removeip_anon_host') == 'Y') $anonymity++;
+       if (getConfig('removeip_anon_ua')   == 'Y') $anonymity++;
+       if (getConfig('removeip_anon_ref')  == 'Y') $anonymity++;
 
        // Calculate anonymity level
        $level = round($anonymity / 4 * 3);
@@ -151,7 +151,7 @@ function FILTER_ADD_ANONYMITY_NOTICE ($data) {
        $content = $data;
 
        // Extension removeip activated?
-       if ((EXT_IS_ACTIVE("removeip")) && (getConfig('removeip_'.strtolower($data['access_level']).'_show') == "Y")) {
+       if ((EXT_IS_ACTIVE('removeip')) && (getConfig('removeip_'.strtolower($data['access_level']).'_show') == 'Y')) {
                // Add anoymity/privacy infos
                $content['content'] .= REMOVEIP_ADD_INFOS()."<br />\n";
        } // END - if
index 4b6cd6d46cd71c2a80ddd3bc30c695fe50747c1e..aad7abbded90ed1ba31e6aa707c50cce24eb3672 100644 (file)
@@ -90,7 +90,7 @@ if (!isset($_POST)) {
 // Generate arrays which holds the relevante chars to replace
 $GLOBALS['security_chars'] = array(
        // The chars we are looking for...
-       'from' => array("{", "}", "/", ".", "'", "$", "(", ")", '{--', '--}', "%", ";", "[", "]", ":", "--"),
+       'from' => array("{", "}", "/", ".", "'", "$", "(", ")", '{--', '--}', "%", ';', "[", "]", ":", "--"),
        // ... and we will replace to.
        'to'   => array(
                "{OPEN_ANCHOR2}",
@@ -142,7 +142,7 @@ if (is_array($_GET)) {
        }
 }
 
-if (basename($_SERVER['PHP_SELF']) != "install.php") {
+if (basename($_SERVER['PHP_SELF']) != 'install.php') {
        // And POST data
        foreach ($_POST as $seckey => $secvalue) {
                if (!is_array($secvalue)) {
index d29e209338b9823b25a800e5263d99cf2aa054ad..3b639ad7657b4b26b6f95eff57799f81331fee0f 100644 (file)
@@ -67,7 +67,7 @@ function SPONSOR_HANDLE_SPONSOR (&$POST, $NO_UPDATE=false, $messageArray=array()
                        // Check only posted input entries not the submit button
                        switch ($k)
                        {
-                       case "email":
+                       case 'email':
                                $ALREADY = false;
                                if (!VALIDATE_EMAIL($v)) {
                                        // Email address is not valid
@@ -95,7 +95,7 @@ function SPONSOR_HANDLE_SPONSOR (&$POST, $NO_UPDATE=false, $messageArray=array()
                                break;
 
                        case "pass1":
-                               $k = ""; $v = "";
+                               $k = ''; $v = '';
                                break;
 
                        case "pass2":
@@ -125,7 +125,7 @@ function SPONSOR_HANDLE_SPONSOR (&$POST, $NO_UPDATE=false, $messageArray=array()
                if ((empty($POST['force'])) || (!IS_ADMIN())) $POST['force'] = 0;
 
                // SQL and message string is empty by default
-               $sql = ""; $message = "";
+               $sql = ''; $message = '';
 
                // Update?
                if ($UPDATE) {
@@ -172,7 +172,7 @@ function SPONSOR_HANDLE_SPONSOR (&$POST, $NO_UPDATE=false, $messageArray=array()
                        $ret = "added";
                } elseif ((!$NO_UPDATE) && (IS_ADMIN())) {
                        // Add all data as hidden data
-                       $OUT = "";
+                       $OUT = '';
                        foreach ($POST as $k => $v) {
                                // Do not add 'force' !
                                if ($k != "force") {
@@ -198,12 +198,12 @@ function SPONSOR_HANDLE_SPONSOR (&$POST, $NO_UPDATE=false, $messageArray=array()
 
                // Output message
                if ((!$NO_UPDATE) && (IS_ADMIN())) {
-                       LOAD_TEMPLATE("admin_settings_saved", false, $message);
+                       LOAD_TEMPLATE('admin_settings_saved', false, $message);
                }
        } else {
                // Error found!
                $message = SPONSOR_GET_MESSAGE(getMessage('SPONSOR_DATA_NOT_SAVED'), "failed", $messageArray);
-               LOAD_TEMPLATE("admin_settings_saved", false, $message);
+               LOAD_TEMPLATE('admin_settings_saved', false, $message);
        }
 
        // Shall we return the status?
@@ -228,7 +228,7 @@ function SPONSOR_TRANSLATE_STATUS ($status) {
 // Search for an email address in the database
 function SPONSOR_FOUND_EMAIL_DB ($email) {
        // Do we already have the provided email address in our DB?
-       $ret = (GET_TOTAL_DATA($email, "sponsor_data", "id", "email", true) == 1);
+       $ret = (GET_TOTAL_DATA($email, "sponsor_data", "id", 'email', true) == 1);
 
        // Return result
        return $ret;
@@ -272,9 +272,9 @@ WHERE id='%s' AND password='%s' AND `status`='CONFIRMED' LIMIT 1",
 //
 function GENERATE_SPONSOR_MENU($current)
 {
-       $OUT = "";
+       $OUT = '';
        $WHERE = " AND active='Y'";
-       if (IS_ADMIN()) $WHERE = "";
+       if (IS_ADMIN()) $WHERE = '';
 
        // Load main menu entries
        $result_main = SQL_QUERY("SELECT action AS main_action, title AS main_title FROM `{!_MYSQL_PREFIX!}_sponsor_menu`
@@ -290,7 +290,7 @@ ORDER BY `sort`",
                                array($content['main_action']), __FUNCTION__, __LINE__);
                        if (SQL_NUMROWS($result_sub) > 0) {
                                // Load sub menus
-                               $SUB = "";
+                               $SUB = '';
                                while ($content2 = SQL_FETCHARRAY($result_sub)) {
                                        // Merge both arrays
                                        $content = merge_array($content, $content2);
@@ -318,7 +318,7 @@ ORDER BY `sort`",
                                $OUT .= LOAD_TEMPLATE("sponsor_action", true, $content);
                        } else {
                                // No sub menus active
-                               $OUT .= LOAD_TEMPLATE("admin_settings_saved", true, getMessage('SPONSOR_NO_SUB_MENUS_ACTIVE'));
+                               $OUT .= LOAD_TEMPLATE('admin_settings_saved', true, getMessage('SPONSOR_NO_SUB_MENUS_ACTIVE'));
                        }
 
                        // Free memory
@@ -326,7 +326,7 @@ ORDER BY `sort`",
                }
        } else {
                // No main menus active
-               $OUT .= LOAD_TEMPLATE("admin_settings_saved", true, getMessage('SPONSOR_NO_MAIN_MENUS_ACTIVE'));
+               $OUT .= LOAD_TEMPLATE('admin_settings_saved', true, getMessage('SPONSOR_NO_MAIN_MENUS_ACTIVE'));
        }
 
        // Free memory
@@ -338,14 +338,14 @@ ORDER BY `sort`",
 
 //
 function GENERATE_SPONSOR_CONTENT ($what) {
-       $OUT = "";
+       $OUT = '';
        $INC = sprintf("inc/modules/sponsor/%s.php", $what);
        if (INCLUDE_READABLE($INC)) {
                // Every sponsor action will output nothing directly. It will be written into $OUT!
                LOAD_INC_ONCE($INC);
        } else {
                // File not found!
-               $OUT .= LOAD_TEMPLATE("admin_settings_saved", true, sprintf(getMessage('SPONSOR_CONTENT_404'), $what));
+               $OUT .= LOAD_TEMPLATE('admin_settings_saved', true, sprintf(getMessage('SPONSOR_CONTENT_404'), $what));
        }
 
        // Return content
@@ -467,7 +467,7 @@ function SPONSOR_SAVE_DATA ($POST, $content) {
        default: // Unknown sponsor what value!
                DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("Unknown sponsor module (what) %s detected.", $GLOBALS['what']));
                $message = sprintf(getMessage('SPONSOR_UNKNOWN_WHAT'), $GLOBALS['what']);
-               $templ = ""; $subj = "";
+               $templ = ''; $subj = '';
                break;
        }
 
@@ -490,7 +490,7 @@ function SPONSOR_SAVE_DATA ($POST, $content) {
                        SEND_ADMIN_NOTIFICATION($subj, $templ, $content);
 
                        // Shall we send mail to the sponsor's new email address?
-                       if ($content['receive_warnings'] == "Y") {
+                       if ($content['receive_warnings'] == 'Y') {
                                // Okay send email with confirmation link to new address and with no confirmation link
                                // to the old address
 
index 6babc26648a71476ff46913158b757cd07042a6d..cf7bf861f8271e934aa6e5ebb10c61470a6c5b94 100644 (file)
@@ -358,15 +358,15 @@ function SURFBAR_MEMBER_DISPLAY_ACTION_FORM ($action, $urlData) {
        // Include fields only for action 'edit'
        if ($action == "edit") {
                // Default is not limited
-               $urlData['limited_yes'] = "";
-               $urlData['limited_no']  = " checked=\"checked\"";
+               $urlData['limited_yes'] = '';
+               $urlData['limited_no']  = ' chkecked="checked"';
                $urlData['limited']     = "false";
 
                // Is this URL limited?
                if ($urlData['views_max'] > 0) {
                        // Then rewrite form data
-                       $urlData['limited_yes'] = " checked=\"checked\"";
-                       $urlData['limited_no']  = "";
+                       $urlData['limited_yes'] = ' chkecked="checked"';
+                       $urlData['limited_no']  = '';
                        $urlData['limited']     = "true";
                } // END - if
        } // END - if
@@ -383,7 +383,7 @@ function SURFBAR_MEMBER_EXECUTE_ACTION ($action, $urlData) {
        $executed = false;
 
        // Is limitation "no" and "limit" is > 0?
-       if ((isset($urlData[$action]['limited'])) && ($urlData[$action]['limited'] == "N") && ((isset($urlData[$action]['limit'])) && ($urlData[$action]['limit'] > 0)) || (!isset($urlData[$action]['limit']))) {
+       if ((isset($urlData[$action]['limited'])) && ($urlData[$action]['limited'] == 'N') && ((isset($urlData[$action]['limit'])) && ($urlData[$action]['limit'] > 0)) || (!isset($urlData[$action]['limit']))) {
                // Set it to unlimited
                $urlData[$action]['limit'] = 0;
        } // END - if
@@ -523,13 +523,13 @@ function SURFBAR_GET_URL_DATA ($searchTerm, $column="id", $order="id", $sort="AS
        $GLOBALS['last_url_data'] = array();
 
        // Is the column an id number?
-       if (($column == "id") || ($column == "userid")) {
+       if (($column == "id") || ($column == 'userid')) {
                // Extra secure input
                $searchTerm = bigintval($searchTerm);
        } // END - if
 
        // If the column is "id" there can be only one entry
-       $limit = "";
+       $limit = '';
        if ($column == "id") {
                $limit = "LIMIT 1";
        } // END - if
@@ -594,7 +594,7 @@ function SURFBAR_REGISTER_URL ($url, $uid, $status="PENDING", $addMode="reg", $e
        $content['limit'] = SURFBAR_TRANSLATE_LIMIT($content['limit']);
 
        // If in reg-mode we notify admin
-       if (($addMode == "reg") || (getConfig('surfbar_notify_admin_unlock') == "Y")) {
+       if (($addMode == "reg") || (getConfig('surfbar_notify_admin_unlock') == 'Y')) {
                // Notify admin even when he as unlocked an email
                SURFBAR_NOTIFY_ADMIN("url_{$addMode}", $content);
        } // END - if
@@ -862,7 +862,7 @@ WHERE userid NOT IN (".implode(",", $UIDs['uid']).") AND `status`='%s'",
 // Check wether the user is allowed to book more URLs
 function SURFBAR_IF_USER_BOOK_MORE_URLS ($uid=0) {
        // Is this admin and userid is zero or does the user has some URLs left to book?
-       return ((($uid == 0) && (IS_ADMIN())) || (SURFBAR_GET_TOTAL_USER_URLS($uid, "", array("REJECTED")) < getConfig('surfbar_max_order')));
+       return ((($uid == 0) && (IS_ADMIN())) || (SURFBAR_GET_TOTAL_USER_URLS($uid, '', array("REJECTED")) < getConfig('surfbar_max_order')));
 }
 // Get total amount of URLs of given status for current user
 function SURFBAR_GET_TOTAL_USER_URLS ($uid=0, $status="",$exclude="") {
@@ -876,7 +876,7 @@ function SURFBAR_GET_TOTAL_USER_URLS ($uid=0, $status="",$exclude="") {
        }
 
        // Default is all URLs
-       $add = "";
+       $add = '';
 
        // Is the status set?
        if (is_array($status)) {
@@ -922,7 +922,7 @@ function SURFBAR_GENERATE_VALIDATION_CODE ($urlId, $salt="") {
        if ($length == 0) $length = 10;
 
        // Generate a code until the length matches
-       $valCode = "";
+       $valCode = '';
        while (strlen($valCode) != $length) {
                // Is the salt set?
                if (empty($salt)) {
@@ -990,7 +990,7 @@ function SURFBAR_PAY_POINTS () {
 // Updates the statistics of current URL/userid
 function SURFBAR_UPDATE_INSERT_STATS_RECORD () {
        // Init add
-       $add = "";
+       $add = '';
 
        // Get allowed views
        $allowed = SURFBAR_GET_VIEWS_ALLOWED();
@@ -1242,7 +1242,7 @@ function SURFBAR_CALCULATE_DYNAMIC_MIN_VALUE () {
        $percent = abs(log(getConfig('surfbar_dynamic_percent') / 100 + 1));
 
        // Get total users
-       $totalUsers = GET_TOTAL_DATA("CONFIRMED", "user_data", "userid", "status", true);
+       $totalUsers = GET_TOTAL_DATA("CONFIRMED", "user_data", 'userid', "status", true);
 
        // Get online users
        $onlineUsers = SURFBAR_DETERMINE_TOTAL_ONLINE();
@@ -1278,7 +1278,7 @@ function SURFBAR_CALCULATE_DYNAMIC_MAX_VALUE () {
        $percent = abs(log(getConfig('surfbar_dynamic_percent') / 100 + 1));
 
        // Get total users
-       $totalUsers = GET_TOTAL_DATA("CONFIRMED", "user_data", "userid", "status", true);
+       $totalUsers = GET_TOTAL_DATA("CONFIRMED", "user_data", 'userid', "status", true);
 
        // Calculate addon
        $addon += abs($max * $percent * $totalUsers);
@@ -1459,7 +1459,7 @@ function SURFBAR_DETERMINE_NEXT_ID ($urlId = 0) {
                $USE = SURFBAR_GET_LOCK_IDS();
 
                // Shall we add some URL ids to ignore?
-               $add = "";
+               $add = '';
                if (count($USE) > 0) {
                        // Ignore some!
                        $add = " AND sbu.id NOT IN (";
@@ -1527,7 +1527,7 @@ LIMIT 1",
                if (is_null($GLOBALS['cache_array']['surfbar']['last_salt'])) {
                        // Then repair it wit the static!
                        //* DEBUG: */ DEBUG_LOG(__FUNCTION__, __LINE__, "last_salt - FIXED!", false);
-                       $GLOBALS['cache_array']['surfbar']['last_salt'] = "";
+                       $GLOBALS['cache_array']['surfbar']['last_salt'] = '';
                } // END - if
 
                // Fix missing last_surfed
index 8df89bcda1502558c7b1df6c4f32012dec35cacd..c4dd1f21b7da39fabb60d430481c46f0db196670 100644 (file)
@@ -53,8 +53,8 @@ if (!defined('__SECURITY')) {
 // @TODO Move all extension-dependent queries into filters
 function OUTPUT_ADVANCED_OVERVIEW (&$result_main) {
        // Init variables/arrays
-       $EXTRAS = "";
-       $OUT = "";
+       $EXTRAS = '';
+       $OUT = '';
        $WHATs = array();
        $DESCRs = array();
        $TITLEs = array();
@@ -82,7 +82,7 @@ function OUTPUT_ADVANCED_OVERVIEW (&$result_main) {
        // First check for all account status seperately
        //
        // Confirmed accounts
-       $value = GET_TOTAL_DATA("CONFIRMED", "user_data", "userid", "status", true);
+       $value = GET_TOTAL_DATA("CONFIRMED", "user_data", 'userid', "status", true);
 
        if ($value > 0) {
                define('__CONFIRMED_VALUE', "<a href=\"{!URL!}/modules.php?module=admin&amp;what=list_user&amp;status=confirmed\">".$value."</a>");
@@ -91,7 +91,7 @@ function OUTPUT_ADVANCED_OVERVIEW (&$result_main) {
        }
 
        // Unconfirmed accounts
-       $value = GET_TOTAL_DATA("UNCONFIRMED", "user_data", "userid", "status", true);
+       $value = GET_TOTAL_DATA("UNCONFIRMED", "user_data", 'userid', "status", true);
 
        if ($value > 0) {
                define('__UNCONFIRMED_VALUE', "<a href=\"{!URL!}/modules.php?module=admin&amp;what=chk_regs\">".$value."</a>");
@@ -100,7 +100,7 @@ function OUTPUT_ADVANCED_OVERVIEW (&$result_main) {
        }
 
        // And locked accounts
-       $value = GET_TOTAL_DATA("LOCKED", "user_data", "userid", "status", true);
+       $value = GET_TOTAL_DATA("LOCKED", "user_data", 'userid', "status", true);
 
        if ($value > 0) {
                define('__LOCKED_VALUE', "<a href=\"{!URL!}/modules.php?module=admin&amp;what=list_user&amp;status=locked\">".$value."</a>");
@@ -199,7 +199,7 @@ function OUTPUT_ADVANCED_OVERVIEW (&$result_main) {
        //
        // Autopurged mails
        //
-       if (EXT_IS_ACTIVE("autopurge")) {
+       if (EXT_IS_ACTIVE('autopurge')) {
                // Get auto-purged mails
                $value = GET_TOTAL_DATA("DELETED", "pool", "id", "data_type", true);
 
@@ -212,17 +212,17 @@ function OUTPUT_ADVANCED_OVERVIEW (&$result_main) {
                //
                // Autopurged bonus mails
                //
-               if (GET_EXT_VERSION("bonus") >= "0.1.8") {
+               if (GET_EXT_VERSION('bonus') >= '0.1.8') {
                        // Get auto-purged bonus mails
-                       $value = GET_TOTAL_DATA("DELETED", "bonus", "id", "data_type", true);
+                       $value = GET_TOTAL_DATA("DELETED", 'bonus', "id", "data_type", true);
 
                        if ($value > 0) {
                                define('__MAIL_BONUS_AP_VALUE', "<a href=\"{!URL!}/modules.php?module=admin&amp;what=email_details\">".$value."</a>");
                        } else {
                                define('__MAIL_BONUS_AP_VALUE', "0");
                        }
-               } elseif (EXT_IS_ACTIVE("bonus")) {
-                       define('__MAIL_BONUS_AP_VALUE', sprintf(getMessage('ADMIN_EXT_BONUS_OUTDATED', "0.1.8")));
+               } elseif (EXT_IS_ACTIVE('bonus')) {
+                       define('__MAIL_BONUS_AP_VALUE', sprintf(getMessage('ADMIN_EXT_BONUS_OUTDATED', '0.1.8')));
                } else {
                        define('__MAIL_BONUS_AP_VALUE', "<span class=\"admin_note\">{--ADMIN_EXT_BONUS_404--}</span>");
                }
@@ -234,35 +234,35 @@ function OUTPUT_ADVANCED_OVERVIEW (&$result_main) {
        //
        // Sent bonus mails
        //
-       if (GET_EXT_VERSION("bonus") >= "0.1.8") {
+       if (GET_EXT_VERSION('bonus') >= '0.1.8') {
                // Get sent bonus mails (but not notifications)
-               $value = GET_TOTAL_DATA("SEND", "bonus", "id", "data_type", true, " AND is_notify='N'");
+               $value = GET_TOTAL_DATA("SEND", 'bonus', "id", "data_type", true, " AND is_notify='N'");
 
                if ($value > 0) {
                        define('__MAIL_BONUS_SEND_VALUE', "<a href=\"{!URL!}/modules.php?module=admin&amp;what=email_details\">".$value."</a>");
                } else {
                        define('__MAIL_BONUS_SEND_VALUE', "0");
                }
-       } elseif (EXT_IS_ACTIVE("bonus")) {
-               define('__MAIL_BONUS_SEND_VALUE', sprintf(getMessage('ADMIN_EXT_BONUS_OUTDATED', "0.1.8")));
+       } elseif (EXT_IS_ACTIVE('bonus')) {
+               define('__MAIL_BONUS_SEND_VALUE', sprintf(getMessage('ADMIN_EXT_BONUS_OUTDATED', '0.1.8')));
        } else {
                define('__MAIL_BONUS_SEND_VALUE', getMessage('ADMIN_EXT_BONUS_404'));
        }
 
-       if (EXT_IS_ACTIVE("autopurge")) {
+       if (EXT_IS_ACTIVE('autopurge')) {
                // Start finding them...
                $since = getConfig('ap_inactive_since');
-               $EXCLUDE_LIST = "";
+               $EXCLUDE_LIST = '';
                if (getConfig('def_refid') > 0) {
                        $EXCLUDE_LIST = " AND d.userid != ".getConfig('def_refid')."";
                } // END - if
 
                // Check for more extensions
                // @TODO These can be rewritten to filter
-               if (EXT_IS_ACTIVE("beg"))                  $EXCLUDE_LIST .= " AND d.userid != ".getConfig('beg_uid')."";
-               if (EXT_IS_ACTIVE("bonus"))                $EXCLUDE_LIST .= " AND d.userid != ".getConfig('bonus_uid')."";
-               if (EXT_IS_ACTIVE("doubler"))              $EXCLUDE_LIST .= " AND d.userid != ".getConfig('doubler_uid')."";
-               if (GET_EXT_VERSION("holiday") >= "0.1.3") $EXCLUDE_LIST .= " AND d.holiday_active='N'";
+               if (EXT_IS_ACTIVE('beg'))                  $EXCLUDE_LIST .= " AND d.userid != ".getConfig('beg_uid')."";
+               if (EXT_IS_ACTIVE('bonus'))                $EXCLUDE_LIST .= " AND d.userid != ".getConfig('bonus_uid')."";
+               if (EXT_IS_ACTIVE('doubler'))              $EXCLUDE_LIST .= " AND d.userid != ".getConfig('doubler_uid')."";
+               if (GET_EXT_VERSION('holiday') >= '0.1.3') $EXCLUDE_LIST .= " AND d.holiday_active='N'";
 
                // Check for all accounts
                ADD_SQL("SELECT DISTINCT d.userid, d.email, d.last_online
@@ -275,7 +275,7 @@ ORDER BY d.userid");
                $TITLEs[] = getMessage('ADMIN_TASK_INACTIVE_AUTOPURGE_TITLE');
        }
 
-       if (GET_EXT_VERSION("sql_patches") >= "0.3.4") {
+       if (GET_EXT_VERSION('sql_patches') >= '0.3.4') {
                // Check for accounts without referal
                ADD_SQL("SELECT userid FROM `{!_MYSQL_PREFIX!}_user_data` WHERE refid='0' ORDER BY userid");
                $DESCRs[] = getMessage('ADMIN_TASK_LIST_ACCOUNT_NOREF');
@@ -283,7 +283,7 @@ ORDER BY d.userid");
                $WHATs[]  = "list_user&amp;mode=norefs";
        }
 
-       if (EXT_IS_ACTIVE("payout")) {
+       if (EXT_IS_ACTIVE('payout')) {
                // List new payout requests
                ADD_SQL("SELECT userid FROM `{!_MYSQL_PREFIX!}_user_payouts` WHERE `status`='NEW' ORDER BY userid");
                $WHATs[]  = "list_payouts";
@@ -295,7 +295,7 @@ ORDER BY d.userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_PAYOUTS_ALL_TITLE');
        }
 
-       if (EXT_IS_ACTIVE("wernis")) {
+       if (EXT_IS_ACTIVE('wernis')) {
                // List new wernis requests
                ADD_SQL("SELECT userid FROM `{!_MYSQL_PREFIX!}_user_wernis` ORDER BY userid");
                $WHATs[]  = "list_wernis";
@@ -303,7 +303,7 @@ ORDER BY d.userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_WERNIS_ALL_TITLE');
        }
 
-       if (EXT_IS_ACTIVE("primera")) {
+       if (EXT_IS_ACTIVE('primera')) {
                // List new primera requests
                ADD_SQL("SELECT userid FROM `{!_MYSQL_PREFIX!}_user_primera` ORDER BY userid");
                $WHATs[]  = "list_primera";
@@ -311,7 +311,7 @@ ORDER BY d.userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_PRIMERA_ALL_TITLE');
        }
 
-       if (EXT_IS_ACTIVE("holiday")) {
+       if (EXT_IS_ACTIVE('holiday')) {
                // List holiday requests
                ADD_SQL("SELECT userid FROM `{!_MYSQL_PREFIX!}_user_holidays` ORDER BY userid");
                $WHATs[]  = "list_holiday";
@@ -319,7 +319,7 @@ ORDER BY d.userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_HOLIDAYS_TITLE');
        }
 
-       if (GET_EXT_VERSION("bonus") >= "0.8.7") {
+       if (GET_EXT_VERSION('bonus') >= '0.8.7') {
                // List all notifications
                ADD_SQL("SELECT id FROM `{!_MYSQL_PREFIX!}_bonus` WHERE is_notify='Y' ORDER BY timestamp DESC");
                $WHATs[]  = "list_notifications";
@@ -327,16 +327,16 @@ ORDER BY d.userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_NOTIFICATIONS_TITLE');
        } // END - if
 
-       if (GET_EXT_VERSION("bonus") >= "0.2.3") {
+       if (GET_EXT_VERSION('bonus') >= '0.2.3') {
                // Active rallye
-               if (GET_EXT_VERSION("bonus") >= "0.6.9") {
+               if (GET_EXT_VERSION('bonus') >= '0.6.9') {
                        // Add more bonus points here
                        $USE = "(0";
-                       if (getConfig('bonus_click_yn') == "Y") $USE .= " + turbo_bonus";
-                       if (getConfig('bonus_login_yn') == "Y") $USE .= " + login_bonus";
-                       if (getConfig('bonus_order_yn') == "Y") $USE .= " + bonus_order";
-                       if (getConfig('bonus_stats_yn') == "Y") $USE .= " + bonus_stats";
-                       if (getConfig('bonus_ref_yn')   == "Y") $USE .= " + bonus_ref";
+                       if (getConfig('bonus_click_yn') == 'Y') $USE .= " + turbo_bonus";
+                       if (getConfig('bonus_login_yn') == 'Y') $USE .= " + login_bonus";
+                       if (getConfig('bonus_order_yn') == 'Y') $USE .= " + bonus_order";
+                       if (getConfig('bonus_stats_yn') == 'Y') $USE .= " + bonus_stats";
+                       if (getConfig('bonus_ref_yn')   == 'Y') $USE .= " + bonus_ref";
                        $USE .= ")";
                } else {
                        // Old version ???
@@ -344,8 +344,8 @@ ORDER BY d.userid");
                }
 
                // Autopurge installed?
-               $lastOnline = "";
-               if ((EXT_IS_ACTIVE("autopurge")) && (getConfig('autopurge_inactive') == "Y") && (getConfig('ap_inactive_since') > 0)) {
+               $lastOnline = '';
+               if ((EXT_IS_ACTIVE('autopurge')) && (getConfig('autopurge_inactive') == 'Y') && (getConfig('ap_inactive_since') > 0)) {
                        // Use last online timestamp to keep inactive members away from here
                        $lastOnline   = sprintf(" AND last_online >= (UNIX_TIMESTAMP() - %s)", getConfig('ap_inactive_since'));
                }
@@ -359,12 +359,12 @@ ORDER BY points DESC, userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_BONUS_TITLE');
        }
 
-       if (GET_EXT_VERSION("beg") >= "0.1.2") {
+       if (GET_EXT_VERSION('beg') >= '0.1.2') {
                // Begging rallye
 
                // Autopurge installed?
-               $lastOnline = "";
-               if ((EXT_IS_ACTIVE("autopurge")) && (getConfig('autopurge_inactive') == "Y") && (getConfig('ap_inactive_since') > 0)) {
+               $lastOnline = '';
+               if ((EXT_IS_ACTIVE('autopurge')) && (getConfig('autopurge_inactive') == 'Y') && (getConfig('ap_inactive_since') > 0)) {
                        // Use last online timestamp to keep inactive members away from here
                        $lastOnline   = sprintf(" AND last_online >= (UNIX_TIMESTAMP() - %s)", getConfig('ap_inactive_since'));
                }
@@ -377,7 +377,7 @@ ORDER BY beg_points DESC, userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_BEG_TITLE');
        }
 
-       if (EXT_IS_ACTIVE("doubler")) {
+       if (EXT_IS_ACTIVE('doubler')) {
                // List waiting payouts
                ADD_SQL("SELECT id FROM `{!_MYSQL_PREFIX!}_doubler` WHERE completed='N' ORDER BY `id`");
                $WHATs[]  = "list_doubler&amp;mode=waiting&amp;select=all";
@@ -447,7 +447,7 @@ ORDER BY beg_points DESC, userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_ENGINE_URLS_TITLE');
        }
 
-       if (EXT_IS_ACTIVE("sponsor")) {
+       if (EXT_IS_ACTIVE('sponsor')) {
                // List all sponsors
                ADD_SQL("SELECT id FROM `{!_MYSQL_PREFIX!}_sponsor_data` ORDER BY `id`");
                $WHATs[]  = "list_sponsor";
@@ -485,7 +485,7 @@ ORDER BY beg_points DESC, userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_SPONSOR_ORDERS_TITLE');
        }
 
-       if (EXT_IS_ACTIVE("country")) {
+       if (EXT_IS_ACTIVE('country')) {
                // List country codes
                ADD_SQL("SELECT id FROM `{!_MYSQL_PREFIX!}_countries` ORDER BY `id`");
                $WHATs[]  = "list_country";
@@ -493,7 +493,7 @@ ORDER BY beg_points DESC, userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_COUNTRY_TITLE');
        }
 
-       if (EXT_IS_ACTIVE("theme")) {
+       if (EXT_IS_ACTIVE('theme')) {
                // List all themes
                ADD_SQL("SELECT id FROM `{!_MYSQL_PREFIX!}_themes` ORDER BY `id`");
                $WHATs[]  = "theme_edit";
@@ -507,7 +507,7 @@ ORDER BY beg_points DESC, userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_THEME_ACTIVE_TITLE');
        }
 
-       if (EXT_IS_ACTIVE("admins")) {
+       if (EXT_IS_ACTIVE('admins')) {
                // List all administrator logins
                ADD_SQL("SELECT id FROM `{!_MYSQL_PREFIX!}_admins` ORDER BY `id`");
                $WHATs[]  = "admins_edit";
@@ -515,7 +515,7 @@ ORDER BY beg_points DESC, userid");
                $TITLEs[] = getMessage('ADMIN_TASK_LIST_ADMINS_ALL_TITLE');
        }
 
-       if (EXT_IS_ACTIVE("surfbar")) {
+       if (EXT_IS_ACTIVE('surfbar')) {
                // List all URLs in surfbar
                ADD_SQL("SELECT id FROM `{!_MYSQL_PREFIX!}_surfbar_urls` ORDER BY `id`");
                $WHATs[]  = "list_surfbar_urls";
@@ -545,7 +545,7 @@ ORDER BY beg_points DESC, userid");
 //
 function TASK_CREATE_EXTRA_ROWS ($WHATs, $DESCRs, $TITLEs) {
        // Init variables
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
 
        // Sadly this cannot be rewritten to a filter... :(
        foreach (GET_SQLS() as $key => $sql) {
index 640dd0b1f3be961dbb33a192acc9fce490a73659..3a7c791673e67d66ba9a50b5ff863991ad2c29f5 100644 (file)
@@ -71,7 +71,7 @@ function THEME_SELECTION_BOX ($mod, $act, $wht, $result) {
        array_pk_sort($themesArray, array("theme_name"));
 
        // Construct selection form for the box template
-       $OUT = "";
+       $OUT = '';
        foreach ($themesArray['theme_unix'] as $key => $theme) {
                $OUT .= "  <option value=\"".$theme."\"";
                if ($theme == GET_CURR_THEME()) $OUT .= " selected=\"selected\"";
@@ -90,8 +90,8 @@ function THEME_SELECTION_BOX ($mod, $act, $wht, $result) {
 
 // Get version from name
 function THEME_GET_VERSION ($name) {
-       // Is the extension "theme" installed?
-       if (!EXT_IS_ACTIVE("theme")) {
+       // Is the extension 'theme' installed?
+       if (!EXT_IS_ACTIVE('theme')) {
                // Then abort here
                return "!.!";
        } // END - if
@@ -106,7 +106,7 @@ function THEME_GET_VERSION ($name) {
 
                // Count up
                incrementConfigEntry('cache_hits');
-       } elseif (GET_EXT_VERSION("cache") != "0.1.8") {
+       } elseif (GET_EXT_VERSION('cache') != '0.1.8') {
                // Load version from database
                $result = SQL_QUERY_ESC("SELECT theme_ver FROM `{!_MYSQL_PREFIX!}_themes` WHERE theme_path='%s' LIMIT 1",
                        array($name), __FUNCTION__, __LINE__);
@@ -133,8 +133,8 @@ function THEME_CHECK_EXIST ($name) {
 
 // Checks if a theme is active
 function THEME_IS_ACTIVE ($name) {
-       // Is the extension "theme" installed?
-       if (!EXT_IS_ACTIVE("theme")) {
+       // Is the extension 'theme' installed?
+       if (!EXT_IS_ACTIVE('theme')) {
                // Then abort here
                return false;
        } // END - if
@@ -145,11 +145,11 @@ function THEME_IS_ACTIVE ($name) {
        // Is the cache entry there?
        if (isset($GLOBALS['cache_array']['themes']['theme_active'][$name])) {
                // Get the version from cache
-               $active = ($GLOBALS['cache_array']['themes']['theme_active'][$name] == "Y");
+               $active = ($GLOBALS['cache_array']['themes']['theme_active'][$name] == 'Y');
 
                // Count up
                incrementConfigEntry('cache_hits');
-       } elseif (GET_EXT_VERSION("cache") != "0.1.8") {
+       } elseif (GET_EXT_VERSION('cache') != '0.1.8') {
                // Check if current theme is already imported or not
                $result = SQL_QUERY_ESC("SELECT theme_active FROM `{!_MYSQL_PREFIX!}_themes` WHERE theme_path='%s' AND theme_active='Y' LIMIT 1",
                        array($name), __FUNCTION__, __LINE__);
@@ -167,8 +167,8 @@ function THEME_IS_ACTIVE ($name) {
 
 // Gets current human-readable theme name
 function GET_CURR_THEME_NAME () {
-       // Is the extension "theme" installed?
-       if (!EXT_IS_ACTIVE("theme")) {
+       // Is the extension 'theme' installed?
+       if (!EXT_IS_ACTIVE('theme')) {
                // Then abort here
                return "default";
        } // END - if
@@ -183,7 +183,7 @@ function GET_CURR_THEME_NAME () {
 
                // Count up
                incrementConfigEntry('cache_hits');
-       } elseif (GET_EXT_VERSION("cache") != "0.1.8") {
+       } elseif (GET_EXT_VERSION('cache') != '0.1.8') {
                // Check if current theme is already imported or not
                $result = SQL_QUERY_ESC("SELECT theme_name FROM `{!_MYSQL_PREFIX!}_themes` WHERE theme_path='%s' AND theme_active='Y' LIMIT 1",
                        array($name), __FUNCTION__, __LINE__);
index f5103384843691161a1fae922459644670daabbe..adeb3001ff0265ee3b8d11a634f5aa7f0ae5eaff 100644 (file)
@@ -51,7 +51,7 @@ function alpha ($sortby, $colspan, $return=false) {
        /* Creates the list of letters and makes them a link. */
        $alphabet = array(getMessage('_ALL2'),"A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z",getMessage('_OTHERS'));
        $num = count($alphabet) - 1;
-       $OUT = "";
+       $OUT = '';
        while (list($counter, $ltr) = each($alphabet)) {
                if (REQUEST_GET('letter') == $ltr) {
                        // Current letter is letter from URL
@@ -85,7 +85,7 @@ function alpha ($sortby, $colspan, $return=false) {
 
 // Add links for sorting
 function SortLinks ($letter, $sortby, $colspan, $return=false) {
-       $OUT = "";
+       $OUT = '';
        if (!REQUEST_ISSET_GET(('offset'))) REQUEST_SET_GET('offset', 0);
        if (!REQUEST_ISSET_GET(('page')))   REQUEST_SET_GET('page'  , 0);
 
@@ -108,7 +108,7 @@ function SortLinks ($letter, $sortby, $colspan, $return=false) {
        );
 
        // Add nickname if extension is installed
-       if (EXT_IS_ACTIVE("nickname")) {
+       if (EXT_IS_ACTIVE('nickname')) {
                $list['nickname'] = getMessage('NICKNAME');
        } // END - if
 
@@ -151,13 +151,13 @@ function ADD_PAGENAV ($PAGES, $offset, $show_form, $colspan,$return=false) {
                define('__FORM_FOOTER', "<tr><td colspan=\"{!__COLSPAN2!}\" class=\"seperator bottom2\">&nbsp;</td></tr>");
        }
 
-       $OUT = "";
+       $OUT = '';
        for ($page = 1; $page <= $PAGES; $page++) {
                if (($page == REQUEST_GET('page')) || ((!REQUEST_ISSET_GET(('page'))) && ($page == "1"))) {
                        $OUT .= "<strong>-";
                } else {
                        if (!REQUEST_ISSET_GET(('letter'))) REQUEST_SET_GET('letter', getMessage('_ALL2'));
-                       if (!REQUEST_ISSET_GET(('sortby'))) REQUEST_SET_GET('sortby', "userid");
+                       if (!REQUEST_ISSET_GET(('sortby'))) REQUEST_SET_GET('sortby', 'userid');
 
                        // Base link
                        $OUT .= "<a href=\"{!URL!}/modules.php?module=admin&amp;what=".$GLOBALS['what'];
@@ -195,12 +195,12 @@ function ADD_PAGENAV ($PAGES, $offset, $show_form, $colspan,$return=false) {
 }
 
 // Create email link to user's account
-function USER_CREATE_EMAIL_LINK($email, $mod="admin") {
+function USER_CREATE_EMAIL_LINK($email, $mod='admin') {
        // Show contact link only if user is confirmed by default
        $locked = " AND `status`='CONFIRMED'";
 
        // But admins shall always see it
-       if (IS_ADMIN()) $locked = "";
+       if (IS_ADMIN()) $locked = '';
 
        $result = SQL_QUERY_ESC("SELECT userid
 FROM `{!_MYSQL_PREFIX!}_user_data`
@@ -227,9 +227,9 @@ function SELECT_RANDOM_REFID () {
        $refid = 0;
 
        // Is the extension version fine?
-       if (GET_EXT_VERSION("user") >= "0.3.4") {
+       if (GET_EXT_VERSION('user') >= "0.3.4") {
                // Get all user ids
-               $totalUsers = GET_TOTAL_DATA("CONFIRMED", "user_data", "userid", "status", true, " AND `rand_confirmed` >= ".getConfig('user_min_confirmed')."");
+               $totalUsers = GET_TOTAL_DATA("CONFIRMED", "user_data", 'userid', "status", true, " AND `rand_confirmed` >= ".getConfig('user_min_confirmed')."");
 
                // Do we have at least one?
                if ($totalUsers > 0) {
@@ -262,11 +262,11 @@ function SELECT_RANDOM_REFID () {
 // Do the user login
 function USER_DO_LOGIN ($uid, $passwd) {
        // Init variables
-       $dmy = "";
+       $dmy = '';
 
        // Add last_login if available
-       $lastOnline = ""
-       if (GET_EXT_VERSION("sql_patches") >= "0.2.8") {
+       $lastOnline = ''
+       if (GET_EXT_VERSION('sql_patches') >= '0.2.8') {
                $lastOnline = ", last_login";
        } // END - if
 
@@ -280,7 +280,7 @@ function USER_DO_LOGIN ($uid, $passwd) {
        );
 
        // Check login data
-       if ((EXT_IS_ACTIVE("nickname")) && (NICKNAME_PROBE_ON_USERID($uid))) {
+       if ((EXT_IS_ACTIVE('nickname')) && (NICKNAME_PROBE_ON_USERID($uid))) {
                // Nickname entered
                $result = SQL_QUERY_ESC("SELECT userid, password, last_online".$lastOnline." FROM `{!_MYSQL_PREFIX!}_user_data` WHERE nickname='%s' AND `status`='CONFIRMED' LIMIT 1",
                        array($uid), __FUNCTION__, __LINE__);
@@ -324,7 +324,7 @@ function USER_DO_LOGIN ($uid, $passwd) {
                        // Probe for last online timemark
                        $probe = time() -  $content['last_online'];
                        if (!empty($content['last_login'])) $probe = time() - $content['last_login'];
-                       if ((GET_EXT_VERSION("bonus") >= "0.2.2") && ($probe >= getConfig('login_timeout'))) {
+                       if ((GET_EXT_VERSION('bonus') >= '0.2.2') && ($probe >= getConfig('login_timeout'))) {
                                // Add login bonus to user's account
                                $add = sprintf(", login_bonus=login_bonus+%s",
                                        (float)getConfig('login_bonus')
@@ -332,7 +332,7 @@ function USER_DO_LOGIN ($uid, $passwd) {
                                $GLOBALS['bonus_payed'] = true;
 
                                // Subtract login bonus from userid's account or jackpot
-                               if ((GET_EXT_VERSION("bonus") >= "0.3.5") && (getConfig('bonus_mode') != "ADD")) BONUS_POINTS_HANDLER('login_bonus');
+                               if ((GET_EXT_VERSION('bonus') >= '0.3.5') && (getConfig('bonus_mode') != "ADD")) BONUS_POINTS_HANDLER('login_bonus');
                        } // END - if
 
                        // Calculate new hash with the secret key and master salt together
@@ -349,7 +349,7 @@ function USER_DO_LOGIN ($uid, $passwd) {
                                        array($uid), __FUNCTION__, __LINE__);
                                if (SQL_AFFECTEDROWS() == 1) {
                                        // Procedure to checking for login data
-                                       if (($GLOBALS['bonus_payed']) && (EXT_IS_ACTIVE("bonus"))) {
+                                       if (($GLOBALS['bonus_payed']) && (EXT_IS_ACTIVE('bonus'))) {
                                                // Bonus added (just displaying!)
                                                $URL = "modules.php?module=chk_login&amp;mode=bonus";
                                        } else {
@@ -364,7 +364,7 @@ function USER_DO_LOGIN ($uid, $passwd) {
                                // Cookies not setable!
                                $URL = "modules.php?module=index&amp;what=login&amp;login=".getCode('NO_COOKIES');
                        }
-               } elseif (GET_EXT_VERSION("sql_patches") >= "0.6.1") {
+               } elseif (GET_EXT_VERSION('sql_patches') >= '0.6.1') {
                        // Update failture counter
                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET login_failures=login_failures+1,last_failure=NOW() WHERE userid=%s LIMIT 1",
                                array($uid), __FUNCTION__, __LINE__);
@@ -407,11 +407,11 @@ function USER_DO_NEW_PASSWORD ($email, $uid) {
        if (!empty($email)) $email = str_replace("{DOT}", '.', $email);
 
        // Init result and error
-       $errorCode = "";
+       $errorCode = '';
        $result = false;
 
        // Probe userid/nickname
-       if ((EXT_IS_ACTIVE("nickname")) && (NICKNAME_PROBE_ON_USERID($uid))) {
+       if ((EXT_IS_ACTIVE('nickname')) && (NICKNAME_PROBE_ON_USERID($uid))) {
                // Nickname entered
                $result = SQL_QUERY_ESC("SELECT userid, status FROM `{!_MYSQL_PREFIX!}_user_data` WHERE nickname='%s' OR email='%s' LIMIT 1",
                        array($uid, $email), __FUNCTION__, __LINE__);
@@ -447,7 +447,7 @@ function USER_DO_NEW_PASSWORD ($email, $uid) {
                        SEND_EMAIL($uid, getMessage('GUEST_NEW_PASSWORD'), $msg);
 
                        // Output note to user
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('GUEST_NEW_PASSWORD_SEND'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('GUEST_NEW_PASSWORD_SEND'));
                } else {
                        // Account is locked or unconfirmed
                        $errorCode = GEN_ERROR_CODE_FROM_ACCOUNT_STATUS($status);
@@ -457,7 +457,7 @@ function USER_DO_NEW_PASSWORD ($email, $uid) {
                }
        } else {
                // ID or email is wrong
-               LOAD_TEMPLATE("admin_settings_saved", false, "<span class=\"guest_failed\">{--GUEST_WRONG_ID_EMAIL--}</span>");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<span class=\"guest_failed\">{--GUEST_WRONG_ID_EMAIL--}</span>");
        }
 
        // Return the error code
index 61d12747ef551df73c0d7b7512896ebf4b7cef94..5c76e50c24936abad4c286f5fbb3351f94f9cdf2 100644 (file)
@@ -213,7 +213,7 @@ function WERNIS_TEST_API () {
 function WERNIS_EXECUTE_WITHDRAW ($wdsId, $userMd5, $amount) {
        // Is the sponsor extension installed?
        if (getConfig('wernis_withdraw_active') != "Y") {
-               if (!EXT_IS_ACTIVE("sponsor")) {
+               if (!EXT_IS_ACTIVE('sponsor')) {
                        // No, abort here
                        return false;
                } elseif (!IS_SPONSOR()) {
@@ -350,7 +350,7 @@ function WERNIS_TAKE_FEE ($points, $mode) {
        }
 
        // Divide/multiply the factor
-       if ($mode == "payout") {
+       if ($mode == 'payout') {
                // Divide for payout
                $points = $points / getConfig('wernis_payout_factor');
        } else {
index 69d4b301f79e44fe70cec8ae52be93d5311a140f..1eeaa3ef5b3736247f4e7ab280060ccf549c93cc 100644 (file)
@@ -172,13 +172,13 @@ function YOOMEDIA_PARSE_RESPONSE ($response, $type) {
        return $result;
 }
 
-// Prepares a bonus mail for delivery. Works only if extension "bonus" is active
+// Prepares a bonus mail for delivery. Works only if extension 'bonus' is active
 function YOOMEDIA_PREPARE_MAIL_DELIVERY ($data) {
        // Is this an admin?
        if (!IS_ADMIN()) {
                // Abort here
                return false;
-       } elseif (!EXT_IS_ACTIVE("bonus")) {
+       } elseif (!EXT_IS_ACTIVE('bonus')) {
                // Abort here
                return false;
        }
@@ -199,7 +199,7 @@ function YOOMEDIA_PREPARE_MAIL_DELIVERY ($data) {
        $data['all'] = TRANSLATE_COMMA(GET_TOTAL_RECEIVERS());
 
        // Add categories
-       $data['categories'] = ADD_CATEGORY_OPTIONS("normal");
+       $data['categories'] = ADD_CATEGORY_OPTIONS('normal');
 
        // Load template
        LOAD_TEMPLATE("admin_send_yoomedia", false, $data);
@@ -211,7 +211,7 @@ function YOOMEDIA_SEND_BONUS_MAIL ($data, $mode) {
        if (!IS_ADMIN()) {
                // Abort here
                return false;
-       } elseif (!EXT_IS_ACTIVE("bonus")) {
+       } elseif (!EXT_IS_ACTIVE('bonus')) {
                // Abort here
                return false;
        }
@@ -220,8 +220,8 @@ function YOOMEDIA_SEND_BONUS_MAIL ($data, $mode) {
        $data['receiver'] = 0;
 
        // HTML or normal? (normal is default...)
-       $type = "t";
-       if (($mode == "html") && (EXT_IS_ACTIVE("html"))) $type = "h";
+       $type = 't';
+       if (($mode == 'html') && (EXT_IS_ACTIVE('html_mail'))) $type = 'h';
 
        // Auto-generate URL
        $data['url'] = sprintf("http://www.yoomedia.de/code/%s-mail.php?id=%s&sid=%s",
@@ -345,11 +345,11 @@ function YOOMEDIA_RELOAD_LOCK ($data, $mode) {
 function YOOMEDIA_CONVERT_MODE ($mode) {
        // Convert mode for normal/html
        switch ($mode) {
-               case "normal":
+               case 'normal':
                        $mode = "textmail";
                        break;
 
-               case "html":
+               case 'html':
                        $mode = "htmlmail";
                        break;
        } // END - switch
index be9127238d13431efd72cd5fdca665fbf26cb805..2bf52439494d57e85a77a10a7c1ac93451e380f4 100644 (file)
@@ -44,7 +44,7 @@ if (!defined('__SECURITY')) {
 
 // Init & set the INC_POOL
 INIT_INC_POOL();
-SET_INC_POOL(GET_DIR_AS_ARRAY("inc/loader/", "load_cache-"));
+SET_INC_POOL(GET_DIR_AS_ARRAY('inc/loader/', 'load_cache-'));
 
 // Run the filter
 runFilterChain('load_includes');
index 975ffc393ecb60f04f2d78377cdd6dd76c093505..18ff9c64dffbf3e9fddebf5d52e122eed84fcda4 100644 (file)
 
 // Some security stuff...
 if (!defined('__SECURITY')) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
 }
 
 // Init variables
 EXT_INIT_CSS_FILES();
-$add = "";
+$add = '';
 
 // Init cache instance and array
 $GLOBALS['cache_instance'] = null;
@@ -65,12 +65,12 @@ if ((!isInstalled()) || (isInstalling())) {
 $GLOBALS['cache_array']['active_extensions'] = array();
 
 // By default no cache is set
-$GLOBALS['cache_mode'] = "no";
+$GLOBALS['cache_mode'] = 'no';
 
 // Load sql_patchrs extension alone
-if (!LOAD_EXTENSION("sql_patches")) {
+if (!LOAD_EXTENSION('sql_patches')) {
        // Could not load sql_patches! ARGH!!!
-       trigger_error("Cannot load extension sql_patches.");
+       trigger_error('Cannot load extension sql_patches.');
 } // END - if
 
 // Init inc pool array
@@ -79,37 +79,37 @@ INIT_INC_POOL();
 //
 // Load extensions
 //
-if (EXT_IS_ACTIVE("cache")) {
+if (EXT_IS_ACTIVE('cache')) {
        // Load cache extension alone
-       if (!LOAD_EXTENSION("cache")) {
+       if (!LOAD_EXTENSION('cache')) {
                // Extension 'cache' was not loaded
-               trigger_error("Cannot load extension cache.");
+               trigger_error('Cannot load extension cache.');
        } // END - if
 
        // Check extension cache
-       switch (($GLOBALS['cache_instance']->loadCacheFile("extensions", true)) && ($GLOBALS['cache_instance']->extensionVersionMatches("sql_patches"))) {
-               case true : $GLOBALS['cache_mode'] = "load"; break;
-               case false: $GLOBALS['cache_mode'] = "init"; break;
+       switch (($GLOBALS['cache_instance']->loadCacheFile('extensions', true)) && ($GLOBALS['cache_instance']->extensionVersionMatches('sql_patches'))) {
+               case true : $GLOBALS['cache_mode'] = 'load'; break;
+               case false: $GLOBALS['cache_mode'] = 'init'; break;
        }
 
        // Do we need to init the cache?
-       if (($GLOBALS['cache_mode'] == "init") && (getConfig('cache_exts') == "Y")) {
+       if (($GLOBALS['cache_mode'] == 'init') && (getConfig('cache_exts') == 'Y')) {
                // Init cache file
-               $GLOBALS['cache_instance']->init("EXTENSIONS");
-               $GLOBALS['cache_instance']->storeExtensionVersion("sql_patches");
-       } elseif (getConfig('cache_exts') != "Y") {
+               $GLOBALS['cache_instance']->init('EXTENSIONS');
+               $GLOBALS['cache_instance']->storeExtensionVersion('sql_patches');
+       } elseif (getConfig('cache_exts') != 'Y') {
                // Cache will not be created for extensions
-               $GLOBALS['cache_mode'] = "skip";
+               $GLOBALS['cache_mode'] = 'skip';
        }
 } // END - if
 
 // Load cache?
-if ($GLOBALS['cache_mode'] == "load") {
+if ($GLOBALS['cache_mode'] == 'load') {
        // Init include array
        $EXT_POOL = array();
 
        // Re-initialize handler
-       $GLOBALS['cache_instance']->loadCacheFile("extensions", true);
+       $GLOBALS['cache_instance']->loadCacheFile('extensions', true);
 
        // Load extension data from cache file
        $EXT_DUMMY = $GLOBALS['cache_instance']->getArrayFromCache();
@@ -128,10 +128,10 @@ if ($GLOBALS['cache_mode'] == "load") {
        $EXT_NAMES = array();
        foreach ($EXT_DUMMY['ext_name'] as $k => $name) {
                // Load CSS file
-               if ($EXT_DUMMY['ext_css'][$k] == "Y") EXT_ADD_CSS_FILE("".$name.".css");
+               if ($EXT_DUMMY['ext_css'][$k] == 'Y') EXT_ADD_CSS_FILE($name . '.css');
 
                // Load extension file itself
-               if ((($EXT_DUMMY['ext_active'][$k] == "Y") || ($EXT_DUMMY['ext_keep'][$k] == "Y") || (IS_ADMIN())) && (!in_array($name, array("sql_patches", "cache")))) {
+               if ((($EXT_DUMMY['ext_active'][$k] == 'Y') || ($EXT_DUMMY['ext_keep'][$k] == 'Y') || (IS_ADMIN())) && (!in_array($name, array('sql_patches', 'cache')))) {
                        $EXT_POOL[] = $name;
                } // END - if
 
@@ -155,8 +155,8 @@ if ($GLOBALS['cache_mode'] == "load") {
                // Add ext name
                $EXT_NAMES[$id] = $name;
 
-               // Add deprecated flag (defaults to "not deprecated")
-               $EXT_DUMMY['ext_deprecated'][$name] = "N";
+               // Add deprecated flag (defaults to 'not deprecated')
+               $EXT_DUMMY['ext_deprecated'][$name] = 'N';
 
                // Mark it as active extension
                $GLOBALS['cache_array']['active_extensions']['$name'] = $EXT_DUMMY['ext_keep'][$k];
@@ -188,7 +188,7 @@ if ($GLOBALS['cache_mode'] == "load") {
        INIT_FILTER_SYSTEM();
 
        // Load more cache files (like admins)
-       LOAD_INC_ONCE("inc/load_cache.php");
+       LOAD_INC_ONCE('inc/load_cache.php');
 
        // Remove array
        unset($EXT_POOL);
@@ -196,18 +196,18 @@ if ($GLOBALS['cache_mode'] == "load") {
        // If current user is not admin load only activated extensions. But load
        // them all if we are going to init the cache files. The admin shall use
        // every available extension for testing purposes.
-       if ((!IS_ADMIN()) && ($GLOBALS['cache_mode'] != "init")) $add = " WHERE ext_active='Y'";
+       if ((!IS_ADMIN()) && ($GLOBALS['cache_mode'] != 'init')) $add = " WHERE ext_active='Y'";
 
-       if (GET_EXT_VERSION("sql_patches") >= "0.0.6") {
+       if (GET_EXT_VERSION('sql_patches') >= '0.0.6') {
                // Query with CSS file from DB
-               $res_ext_crt = SQL_QUERY("SELECT id AS ext_id, ext_name, ext_has_css AS ext_css, ext_active, ext_version
-FROM `{!_MYSQL_PREFIX!}_extensions`".$add."
-ORDER BY ext_name", __FILE__, __LINE__);
+               $res_ext_crt = SQL_QUERY('SELECT id AS ext_id, ext_name, ext_has_css AS ext_css, ext_active, ext_version
+FROM `{!_MYSQL_PREFIX!}_extensions`' . $add . '
+ORDER BY ext_name', __FILE__, __LINE__);
        } else {
                // Old obsolete query string
-               $res_ext_crt = SQL_QUERY("SELECT id AS ext_id, ext_name, ext_name, ext_active, ext_version
-FROM `{!_MYSQL_PREFIX!}_extensions`".$add."
-ORDER BY ext_name", __FILE__, __LINE__);
+               $res_ext_crt = SQL_QUERY('SELECT id AS ext_id, ext_name, ext_name, ext_active, ext_version
+FROM `{!_MYSQL_PREFIX!}_extensions`' . $add . '
+ORDER BY ext_name', __FILE__, __LINE__);
        }
 }
 
@@ -215,13 +215,13 @@ ORDER BY ext_name", __FILE__, __LINE__);
 $DEL = array();
 
 // At least one found?
-if ((SQL_NUMROWS($res_ext_crt) > 0) && ((($GLOBALS['cache_mode'] == "init") && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) || ($GLOBALS['cache_mode'] == "no"))) {
+if ((SQL_NUMROWS($res_ext_crt) > 0) && ((($GLOBALS['cache_mode'] == 'init') && ($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != '-1')) || ($GLOBALS['cache_mode'] == 'no'))) {
        // Extensions are registered so we load them
        while ($content = SQL_FETCHARRAY($res_ext_crt)) {
                // Get menu entry
-               $content['ext_menu'] = "N";
+               $content['ext_menu'] = 'N';
                if (MODULE_HAS_MENU($content['ext_name'], true)) {
-                       $content['ext_menu'] = "Y";
+                       $content['ext_menu'] = 'Y';
                } // END - if
 
                // Generate FQFN for extension
@@ -230,41 +230,41 @@ if ((SQL_NUMROWS($res_ext_crt) > 0) && ((($GLOBALS['cache_mode'] == "init") && (
                // Does the extension file exists?
                if (FILE_READABLE($FQFN)) {
                        // By default no extension is always active, except sql_patches
-                       EXT_SET_ALWAYS_ACTIVE("N");
+                       EXT_SET_ALWAYS_ACTIVE('N');
 
                        // Load extension
-                       if (($content['ext_name'] != "sql_patches") && (($content['ext_name'] != "cache") || (!EXT_IS_ACTIVE("cache")))) {
+                       if (($content['ext_name'] != 'sql_patches') && (($content['ext_name'] != 'cache') || (!EXT_IS_ACTIVE('cache')))) {
                                // Load extension
                                LOAD_EXTENSION($content['ext_name']);
                        } else {
                                // Keep sql_patches always active
-                               EXT_SET_ALWAYS_ACTIVE("Y");
+                               EXT_SET_ALWAYS_ACTIVE('Y');
                        }
 
                        // Transfer EXT_ALWAYS_ACTIVE flag
                        $content['ext_keep'] = EXT_GET_ALWAYS_ACTIVE();
 
                        // CSS file handling:
-                       if ((!isset($content['ext_css'])) || ($content['ext_css'] == "Y")) {
+                       if ((!isset($content['ext_css'])) || ($content['ext_css'] == 'Y')) {
                                // Create FQFN for the CSS file
                                $FQFN = sprintf("%stheme/%s/css/%s.css", constant('PATH'), GET_CURR_THEME(), $content['ext_name']);
 
                                // Is the file there?
                                if (FILE_READABLE($FQFN)) {
                                        // CSS file for extension was found (use only relative path for now!)
-                                       EXT_ADD_CSS_FILE($content['ext_name'].".css");
-                                       $content['ext_css'] = "Y";
+                                       EXT_ADD_CSS_FILE($content['ext_name'] . '.css');
+                                       $content['ext_css'] = 'Y';
                                } else {
                                        // Don't load CSS file
-                                       $content['ext_css'] = "N";
+                                       $content['ext_css'] = 'N';
                                }
                        } // END - if
 
                        // Shall we cache?
-                       if ($GLOBALS['cache_mode'] == "init") {
+                       if ($GLOBALS['cache_mode'] == 'init') {
                                // Add cache row
                                $GLOBALS['cache_instance']->addRow($content);
-                       } elseif ($GLOBALS['cache_mode'] == "no") {
+                       } elseif ($GLOBALS['cache_mode'] == 'no') {
                                // Remember this value for later usage
                                $GLOBALS['cache_array']['active_extensions'][$content['ext_name']] = EXT_GET_ALWAYS_ACTIVE();
                        }
@@ -277,17 +277,17 @@ if ((SQL_NUMROWS($res_ext_crt) > 0) && ((($GLOBALS['cache_mode'] == "init") && (
        // Init filter system
        INIT_FILTER_SYSTEM();
 
-       if ($GLOBALS['cache_mode'] == "init") {
+       if ($GLOBALS['cache_mode'] == 'init') {
                // Close cache file
                $GLOBALS['cache_instance']->finalize();
 
                // Load more cache files (like admins)
-               LOAD_INC_ONCE("inc/load_cache.php");
+               LOAD_INC_ONCE('inc/load_cache.php');
        } // END - if
 
        // Free memory
        SQL_FREERESULT($res_ext_crt);
-} elseif (!EXT_IS_ACTIVE("cache")) {
+} elseif (!EXT_IS_ACTIVE('cache')) {
        // Init filter system even when there are no extensions installed. #16
        INIT_FILTER_SYSTEM();
 }
index 091d327a5f8d4554320f4fcd01d4da248474045a..93280c2a561025c23d7785aab7d576d40f47866c 100644 (file)
 
 // Some security stuff...
 if (!defined('__SECURITY')) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
 } // END - if
 
 // Let's start with the admins table...
-if (($GLOBALS['cache_instance']->loadCacheFile("admins")) && ($GLOBALS['cache_instance']->extensionVersionMatches("admins"))) {
+if (($GLOBALS['cache_instance']->loadCacheFile('admins')) && ($GLOBALS['cache_instance']->extensionVersionMatches('admins'))) {
        // Load cache
        $GLOBALS['cache_array']['admins'] = $GLOBALS['cache_instance']->getArrayFromCache();
 
@@ -59,7 +59,7 @@ if (($GLOBALS['cache_instance']->loadCacheFile("admins")) && ($GLOBALS['cache_in
                                // Rewrite all entries
                                foreach ($GLOBALS['cache_array']['admins'] as $key=>$entryArray) {
                                        // Rewrite the entry
-                                       if ($key == "aid") {
+                                       if ($key == 'aid') {
                                                // Rewrite admin id (use login name as index)
                                                $GLOBALS['cache_array']['admins']['aid'][$GLOBALS['cache_array']['admins']['login'][$idx]] = $entryArray[$idx];
                                        } else {
@@ -84,18 +84,18 @@ if (($GLOBALS['cache_instance']->loadCacheFile("admins")) && ($GLOBALS['cache_in
                $GLOBALS['cache_instance']->destroyCacheFile();
                unset($GLOBALS['cache_array']['admins']);
        }
-} elseif ((getConfig('cache_admins') == "Y") && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
+} elseif ((getConfig('cache_admins') == 'Y') && ($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != '-1')) {
        // Create cache file
-       $GLOBALS['cache_instance']->init("ADMINS");
-       $GLOBALS['cache_instance']->storeExtensionVersion("admins");
+       $GLOBALS['cache_instance']->init('ADMINS');
+       $GLOBALS['cache_instance']->storeExtensionVersion('admins');
 
        // Load every data from DB to cache file
        $add = runFilterChain('sql_admin_extra_data');
 
        // Query the database about this
-       $result_admins = SQL_QUERY("SELECT id AS aid, login, password, email".$add."
+       $result_admins = SQL_QUERY('SELECT id AS aid, login, password, email'.$add.'
 FROM `{!_MYSQL_PREFIX!}_admins`
-ORDER BY login", __FILE__, __LINE__);
+ORDER BY login', __FILE__, __LINE__);
        while ($dummy = SQL_FETCHARRAY($result_admins)) {
                // Save row
                $GLOBALS['cache_instance']->addRow($dummy);
@@ -112,18 +112,18 @@ ORDER BY login", __FILE__, __LINE__);
 }
 
 // Next cached table are the admins_acls...
-if (GET_EXT_VERSION("admins") >= "0.3") {
+if (GET_EXT_VERSION('admins') >= '0.3') {
        // Check for cache file
-       if (($GLOBALS['cache_instance']->loadCacheFile("admins_acls")) && ($GLOBALS['cache_instance']->extensionVersionMatches("admins"))) {
+       if (($GLOBALS['cache_instance']->loadCacheFile('admins_acls')) && ($GLOBALS['cache_instance']->extensionVersionMatches('admins'))) {
                // Load referal system from cache
                $GLOBALS['cache_array']['admin_acls'] = $GLOBALS['cache_instance']->getArrayFromCache();
-       } elseif ((getConfig('cache_acls') == "Y") && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
+       } elseif ((getConfig('cache_acls') == 'Y') && ($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != '-1')) {
                // Create cache file here
-               $GLOBALS['cache_instance']->init("ADMINS_ACLS");
-               $GLOBALS['cache_instance']->storeExtensionVersion("admins");
+               $GLOBALS['cache_instance']->init('ADMINS_ACLS');
+               $GLOBALS['cache_instance']->storeExtensionVersion('admins');
 
                // Load all modules and their data (column 'id' is no longer required)
-               $result = SQL_QUERY("SELECT admin_id, action_menu, what_menu, access_mode FROM `{!_MYSQL_PREFIX!}_admins_acls` ORDER BY admin_id, action_menu, what_menu", __FILE__, __LINE__);
+               $result = SQL_QUERY('SELECT admin_id, action_menu, what_menu, access_mode FROM `{!_MYSQL_PREFIX!}_admins_acls` ORDER BY admin_id, action_menu, what_menu', __FILE__, __LINE__);
 
                // Add all rows
                while ($data = SQL_FETCHARRAY($result)) {
index 49402d59d2c22aa807078d606084be942ebb9ba0..cbb44999bb6711b4474c14a8199d4df80c562a9f 100644 (file)
 
 // Some security stuff...
 if (!defined('__SECURITY')) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
 }
 
 // Next cached table is the configuration (config)...
-if (($GLOBALS['cache_instance']->loadCacheFile("config", true)) && ($GLOBALS['cache_instance']->extensionVersionMatches("sql_patches"))) {
+if (($GLOBALS['cache_instance']->loadCacheFile('config', true)) && ($GLOBALS['cache_instance']->extensionVersionMatches('sql_patches'))) {
        // Load config from cache
        $GLOBALS['cache_array']['config'] = $GLOBALS['cache_instance']->getArrayFromCache();
-} elseif ((getConfig('cache_config') == "Y") && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
+} elseif ((getConfig('cache_config') == 'Y') && ($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != '-1')) {
        // Create cache file here
-       $GLOBALS['cache_instance']->init("CONFIG");
-       $GLOBALS['cache_instance']->storeExtensionVersion("sql_patches");
+       $GLOBALS['cache_instance']->init('CONFIG');
+       $GLOBALS['cache_instance']->storeExtensionVersion('sql_patches');
 
        // Load all modules and their data
-       $result = SQL_QUERY("SELECT * FROM `{!_MYSQL_PREFIX!}_config` ORDER BY config ASC", __FILE__, __LINE__);
+       $result = SQL_QUERY('SELECT * FROM `{!_MYSQL_PREFIX!}_config` ORDER BY config ASC', __FILE__, __LINE__);
        while ($data = SQL_FETCHARRAY($result)) {
                // Add row to cache file
                $GLOBALS['cache_instance']->addRow($data);
index 9aa642ca065495d544267875615aa2ccab321ba1..92be2dfe84510e65f8683d9cbed5fe6c6c75316f 100644 (file)
 
 // Some security stuff...
 if (!defined('__SECURITY')) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
 }
 
 // Next cached table is the module registry (mod_reg)...
-if (($GLOBALS['cache_instance']->loadCacheFile("modreg")) && ($GLOBALS['cache_instance']->extensionVersionMatches("sql_patches"))) {
+if (($GLOBALS['cache_instance']->loadCacheFile('modreg')) && ($GLOBALS['cache_instance']->extensionVersionMatches('sql_patches'))) {
        // Load cache
        $GLOBALS['cache_array']['modules'] = $GLOBALS['cache_instance']->getArrayFromCache();
 
@@ -68,20 +68,20 @@ if (($GLOBALS['cache_instance']->loadCacheFile("modreg")) && ($GLOBALS['cache_in
                } // END - if
        } // END - foreach
        unset($modArray);
-} elseif ((getConfig('cache_modreg') == "Y") && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
+} elseif ((getConfig('cache_modreg') == 'Y') && ($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != '-1')) {
        // Create cache file here
-       $GLOBALS['cache_instance']->init("MODULES");
-       $GLOBALS['cache_instance']->storeExtensionVersion("sql_patches");
+       $GLOBALS['cache_instance']->init('MODULES');
+       $GLOBALS['cache_instance']->storeExtensionVersion('sql_patches');
 
        // Load all modules and their data
-       if (GET_EXT_VERSION("sql_patches") >= "0.3.6") {
+       if (GET_EXT_VERSION('sql_patches') >= '0.3.6') {
                // Load has_menu
-               $result = SQL_QUERY("SELECT id, module, title, locked, hidden, admin_only, title, mem_only, has_menu
-FROM `{!_MYSQL_PREFIX!}_mod_reg` ORDER BY `id`", __FILE__, __LINE__);
+               $result = SQL_QUERY('SELECT id, module, title, locked, hidden, admin_only, title, mem_only, has_menu
+FROM `{!_MYSQL_PREFIX!}_mod_reg` ORDER BY `id`', __FILE__, __LINE__);
        } else {
                // Don't load has_menu
-               $result = SQL_QUERY("SELECT id, module, title, locked, hidden, admin_only, title, mem_only
-FROM `{!_MYSQL_PREFIX!}_mod_reg` ORDER BY `id`", __FILE__, __LINE__);
+               $result = SQL_QUERY('SELECT id, module, title, locked, hidden, admin_only, title, mem_only
+FROM `{!_MYSQL_PREFIX!}_mod_reg` ORDER BY `id`', __FILE__, __LINE__);
        }
 
        // Cache all data
index d1a9752677b05bdd768fded3a28a56ea0e5bcea7..6414981688c0294f4ffccaa45ce566ebd110a230 100644 (file)
 
 // Some security stuff...
 if (!defined('__SECURITY')) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
 }
 
 // Next cached table is the referal system (refdepths)...
-if (($GLOBALS['cache_instance']->loadCacheFile("refdepths")) && ($GLOBALS['cache_instance']->extensionVersionMatches("sql_patches"))) {
+if (($GLOBALS['cache_instance']->loadCacheFile('refdepths')) && ($GLOBALS['cache_instance']->extensionVersionMatches('sql_patches'))) {
        // Load referal system from cache
        $GLOBALS['cache_array']['ref_depths'] = $GLOBALS['cache_instance']->getArrayFromCache();
-} elseif ((getConfig('cache_refdepth') == "Y") && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
+} elseif ((getConfig('cache_refdepth') == 'Y') && ($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != '-1')) {
        // Create cache file here
-       $GLOBALS['cache_instance']->init("REFDEPTHS");
-       $GLOBALS['cache_instance']->storeExtensionVersion("sql_patches");
+       $GLOBALS['cache_instance']->init('REFDEPTHS');
+       $GLOBALS['cache_instance']->storeExtensionVersion('sql_patches');
 
        // Load all modules and their data
-       $result = SQL_QUERY("SELECT id, level, percents FROM `{!_MYSQL_PREFIX!}_refdepths` ORDER BY level", __FILE__, __LINE__);
+       $result = SQL_QUERY('SELECT id, level, percents FROM `{!_MYSQL_PREFIX!}_refdepths` ORDER BY level', __FILE__, __LINE__);
        while ($data = SQL_FETCHARRAY($result)) {
                // Add row to cache file
                $GLOBALS['cache_instance']->addRow($data);
index 42aa8cb8a7939e8adc398f218abb03bd516a5bb2..8a8b50f8c4676799d26acf6f8f0ee86a403087bf 100644 (file)
 
 // Some security stuff...
 if (!defined('__SECURITY')) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
 }
 
 // Next cached table is the referal system (refsystem)...
-if (($GLOBALS['cache_instance']->loadCacheFile("refsystem")) && ($GLOBALS['cache_instance']->extensionVersionMatches("sql_patches"))) {
+if (($GLOBALS['cache_instance']->loadCacheFile('refsystem')) && ($GLOBALS['cache_instance']->extensionVersionMatches('sql_patches'))) {
        // Load referal system from cache
        $GLOBALS['cache_array']['refsystem'] = $GLOBALS['cache_instance']->getArrayFromCache();
-} elseif ((getConfig('cache_refsys') == "Y") && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
+} elseif ((getConfig('cache_refsys') == 'Y') && ($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != '-1')) {
        // Create cache file here
-       $GLOBALS['cache_instance']->init("REFSYSTEM");
-       $GLOBALS['cache_instance']->storeExtensionVersion("sql_patches");
+       $GLOBALS['cache_instance']->init('REFSYSTEM');
+       $GLOBALS['cache_instance']->storeExtensionVersion('sql_patches');
 
        // Load all modules and their data
-       $result = SQL_QUERY("SELECT id, userid, level, counter FROM `{!_MYSQL_PREFIX!}_refsystem` ORDER BY userid, level", __FILE__, __LINE__);
+       $result = SQL_QUERY('SELECT id, userid, level, counter FROM `{!_MYSQL_PREFIX!}_refsystem` ORDER BY userid, level', __FILE__, __LINE__);
        while ($data = SQL_FETCHARRAY($result)) {
                // Add row to cache file
                $GLOBALS['cache_instance']->addRow($data);
index fc4b883dd4e6979265dfb3aaf57ee23819770889..f9e9ec11003ed9b3ed4680f3e29465ac9bf913ba 100644 (file)
 
 // Some security stuff...
 if (!defined('__SECURITY')) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
 }
 
 // Next cached table is the revision...
-if (($GLOBALS['cache_instance']->loadCacheFile("revision", true))) {
+if (($GLOBALS['cache_instance']->loadCacheFile('revision', true))) {
        // Load revision from cache
        $GLOBALS['cache_array']['revision'] = $GLOBALS['cache_instance']->getArrayFromCache();
-} elseif (($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
+} elseif (($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != '-1')) {
        // Create cache file here
-       $GLOBALS['cache_instance']->init("REVISION");
+       $GLOBALS['cache_instance']->init('revision');
 
        // add the new RevInfos in and saves it to the cache
        $GLOBALS['cache_instance']->addRow(getAkt_vers());
index 0bec8ccc15061ed475164d73b48712d7e92438c0..382be5c04e9d31f1776aa2e63b5602cab198b855 100644 (file)
 
 // Some security stuff...
 if (!defined('__SECURITY')) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
-} elseif (!EXT_IS_ACTIVE("theme")) {
+} elseif (!EXT_IS_ACTIVE('theme')) {
        // Skip this loader
        return false;
 }
 
 // Next cached table is the referal system (themes)...
-if (($GLOBALS['cache_instance']->loadCacheFile("themes")) && ($GLOBALS['cache_instance']->extensionVersionMatches("theme"))) {
+if (($GLOBALS['cache_instance']->loadCacheFile('themes')) && ($GLOBALS['cache_instance']->extensionVersionMatches('theme'))) {
        // Load referal system from cache
        $cache = $GLOBALS['cache_instance']->getArrayFromCache();
 
        // Restructure the array
        $GLOBALS['cache_array']['themes'] = array();
        foreach ($cache as $key => $data) {
-               // Skip "theme_path" because we don't need to rebuild it
-               if ($key == "theme_path") {
+               // Skip 'theme_path' because we don't need to rebuild it
+               if ($key == 'theme_path') {
                        // Add entries with id
                        foreach ($data as $id => $entry) {
                                $GLOBALS['cache_array']['themes']['theme_path'][$cache['id'][$id]] = $entry;
@@ -65,20 +65,20 @@ if (($GLOBALS['cache_instance']->loadCacheFile("themes")) && ($GLOBALS['cache_in
                                $GLOBALS['cache_array']['themes'][$key][$cache['theme_path'][$id]] = $entry;
                        } // END - foreach
                }
-       } // END - if
+       } // END - foreach
 
        // Remove dummy array
        unset($cache);
-} elseif ((getConfig('cache_themes') == "Y") && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) {
+} elseif ((getConfig('cache_themes') == 'Y') && ($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != '-1')) {
        // Create cache file here
-       $GLOBALS['cache_instance']->init("THEMES");
-       $GLOBALS['cache_instance']->storeExtensionVersion("theme");
+       $GLOBALS['cache_instance']->init('THEMES');
+       $GLOBALS['cache_instance']->storeExtensionVersion('theme');
 
        // Load all themes and their data
-       if (GET_EXT_VERSION("theme") >= "0.0.7") {
-               $result = SQL_QUERY("SELECT id, theme_path, theme_active, theme_ver, theme_name FROM `{!_MYSQL_PREFIX!}_themes` ORDER BY `id`", __FILE__, __LINE__);
+       if (GET_EXT_VERSION('theme') >= '0.0.7') {
+               $result = SQL_QUERY('SELECT id, theme_path, theme_active, theme_ver, theme_name FROM `{!_MYSQL_PREFIX!}_themes` ORDER BY `id`', __FILE__, __LINE__);
        } else {
-               $result = SQL_QUERY("SELECT id, theme_path, theme_active, theme_ver FROM `{!_MYSQL_PREFIX!}_themes` ORDER BY `id`", __FILE__, __LINE__);
+               $result = SQL_QUERY('SELECT id, theme_path, theme_active, theme_ver FROM `{!_MYSQL_PREFIX!}_themes` ORDER BY `id`', __FILE__, __LINE__);
        }
        while ($data = SQL_FETCHARRAY($result)) {
                // Add row to cache file
index 4e81eaa6c7373be7f35a013a878b4819e261f646..4370b8f4f4cf3a3abfc040ceb408625a1a0ba8bd 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("beg")) {
+} elseif (!EXT_IS_ACTIVE('beg')) {
        return;
 }
 
@@ -49,14 +49,14 @@ if ($GLOBALS['output_mode'] == 1) return;
 
 // Create timemark from saved month
 $mark = mktime(0, 0, 0, getConfig('last_month'), date("d", time()), date('Y', time()));
-$sql = ""; $MODE = "";
+$sql = ''; $MODE = '';
 
 // Shall I sent activation or deactivation mail?
 $sql = "SELECT userid, email FROM `{!_MYSQL_PREFIX!}_user_data` WHERE (beg_ral_notify ";
 switch (getConfig('beg_rallye'))
 {
-case "Y": // Begging rallye is activated
-       if (getConfig('beg_ral_en_notify') == "Y")
+case 'Y': // Begging rallye is activated
+       if (getConfig('beg_ral_en_notify') == 'Y')
        {
                // Okay, let's check for member accounts
                $sql .= "= 0 OR (beg_ral_notify > 0 AND beg_ral_en_notify < beg_ral_di_notify)";
@@ -65,12 +65,12 @@ case "Y": // Begging rallye is activated
         else
        {
                // Do not notify!
-               $sql = "";
+               $sql = '';
        }
        break;
 
-case "N": // Begging rallye is deactivated
-       if (getConfig('beg_ral_di_notify') == "Y")
+case 'N': // Begging rallye is deactivated
+       if (getConfig('beg_ral_di_notify') == 'Y')
        {
                // Okay, let's check for member accounts
                $sql .= " > 0 AND beg_ral_di_notify < beg_ral_en_notify";
@@ -79,7 +79,7 @@ case "N": // Begging rallye is deactivated
         else
        {
                // Do not notify!
-               $sql = "";
+               $sql = '';
        }
        break;
 }
@@ -107,14 +107,14 @@ if (!empty($sql)) {
        $result_main = SQL_QUERY($sql, __FILE__, __LINE__);
        if (SQL_NUMROWS($result_main) > 0) {
                // Normal notification mails or bonus mails?
-               $sentBonusMails = ((getConfig('beg_notify_bonus') > 0) && ($MODE == "en") && (EXT_IS_ACTIVE("bonus")));
+               $sentBonusMails = ((getConfig('beg_notify_bonus') > 0) && ($MODE == "en") && (EXT_IS_ACTIVE('bonus')));
 
                // Generate subject line
                $subject = constant('BEG_RALLYE_'.strtoupper($MODE).'_NOTIFY');
 
                // Load message body for bonus mails
-               $message = LOAD_EMAIL_TEMPLATE("beg_en_notify_body", "", "{PER}uid{PER}");
-               $RECEIVER = ""; $UIDs = array();
+               $message = LOAD_EMAIL_TEMPLATE("beg_en_notify_body", '', "{PER}uid{PER}");
+               $RECEIVER = ''; $UIDs = array();
 
                // Okay lets notify all users!
                while ($content = SQL_FETCHARRAY($result_main)) {
@@ -139,13 +139,13 @@ LIMIT 1",
                // Shall I send out bonus mails?
                if ($sentBonusMails === true) {
                        // Okay, make array to string
-                       $RECEIVER = implode(";", $UIDs);
+                       $RECEIVER = implode(';', $UIDs);
 
                        // Prepare URL
                        $URL = "modules.php?module=index&amp;what=login";
 
                        // Insert mail
-                       ADD_BONUS_MAIL_TO_QUEUE($subject, $message, $RECEIVER, getConfig('beg_notify_bonus'), getConfig('beg_notify_wait'), $URL, 0, "normal", SQL_NUMROWS($result_main));
+                       ADD_BONUS_MAIL_TO_QUEUE($subject, $message, $RECEIVER, getConfig('beg_notify_bonus'), getConfig('beg_notify_wait'), $URL, 0, 'normal', SQL_NUMROWS($result_main));
                } // END - if
        } // END - if
 
index c8dcf4e935d803825df5832cd89fbc1852cff830..02d08acb9960e7a6641f4228e81a01bbbbcae1ab 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("birthday")) {
+} elseif (!EXT_IS_ACTIVE('birthday')) {
        return;
 }
 
@@ -53,8 +53,8 @@ $MONTH = date("m", time());
 $YEAR  = date('Y', time());
 
 // Shall I include only active members?
-$add = "%s"; $VALUE = "";
-if ((getConfig('birthday_active')) && (EXT_IS_ACTIVE("autopurge")) && (getConfig('autopurge_inactive') == "Y") && (getConfig('ap_inactive_since') > 0)) {
+$add = "%s"; $VALUE = '';
+if ((getConfig('birthday_active')) && (EXT_IS_ACTIVE('autopurge')) && (getConfig('autopurge_inactive') == 'Y') && (getConfig('ap_inactive_since') > 0)) {
        $add = " AND last_online >= (UNIX_TIMESTAP() - %s)";
        $VALUE = getConfig('ap_inactive_since');
 }
@@ -80,7 +80,7 @@ if (SQL_NUMROWS($result_birthday) > 0) {
                        // Add more entries to the array
                        $content['age']    = $AGE;
                        $content['points'] = TRANSLATE_COMMA(getConfig('birthday_points'));
-                       $content['check']  = "";
+                       $content['check']  = '';
 
                        // @TODO 4 is hard-coded here, should we move it out in config?
                        for ($idx = 0; $idx < 4; $idx++) {
index daae83b501bc66d1860e05c3f4b165f81f30a048..8a867453f445c22b8add8e54ea7ab4ae2025ed09 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("bonus")) {
+} elseif (!EXT_IS_ACTIVE('bonus')) {
        return;
 }
 
@@ -49,31 +49,31 @@ if ($GLOBALS['output_mode'] == 1) return;
 
 // Create timemark from saved month
 $mark = mktime(0, 0, 0, getConfig('last_month'), date("d", time()), date('Y', time()));
-$sql = ""; $MODE = "";
+$sql = ''; $MODE = '';
 
 // Shall I sent activation or deactivation mail?
 $sql = "SELECT userid, email FROM `{!_MYSQL_PREFIX!}_user_data` WHERE (bonus_ral_notify ";
 switch (getConfig('bonus_active'))
 {
-case "Y": // Active rallye is activated
-       if (getConfig('bonus_en_notify') == "Y") {
+case 'Y': // Active rallye is activated
+       if (getConfig('bonus_en_notify') == 'Y') {
                // Okay, let's check for member accounts
                $sql .= "= 0 OR (bonus_ral_notify > 0 AND bonus_ral_en_notify < bonus_ral_di_notify)";
                $MODE = "en";
        } else {
                // Do not notify!
-               $sql = "";
+               $sql = '';
        }
        break;
 
-case "N": // Active rallye is deactivated
-       if (getConfig('bonus_di_notify') == "Y") {
+case 'N': // Active rallye is deactivated
+       if (getConfig('bonus_di_notify') == 'Y') {
                // Okay, let's check for member accounts
                $sql .= " > 0 AND bonus_ral_di_notify < bonus_ral_en_notify";
                $MODE = "di";
        } else {
                // Do not notify!
-               $sql = "";
+               $sql = '';
        }
        break;
 }
@@ -83,14 +83,14 @@ if (!empty($sql)) {
        $sql .= ") AND `status`='CONFIRMED' ORDER BY last_online ASC";
 
        // Normal notification mails or bonus mails?
-       $sentBonusMails = ((getConfig('bonus_notify_points') > 0) && ($MODE == "en") && (EXT_IS_ACTIVE("bonus")));
+       $sentBonusMails = ((getConfig('bonus_notify_points') > 0) && ($MODE == "en") && (EXT_IS_ACTIVE('bonus')));
 
        // Generate subject line
        $subject = constant('BONUS_RALLYE_'.strtoupper($MODE).'_NOTIFY');
 
        // Load message body for bonus mails
-       $message = LOAD_EMAIL_TEMPLATE("bonus_en_notify_body", "", "{PER}uid{PER}");
-       $RECEIVER = ""; $UIDs = array();
+       $message = LOAD_EMAIL_TEMPLATE("bonus_en_notify_body", '', "{PER}uid{PER}");
+       $RECEIVER = ''; $UIDs = array();
 
        // Check for accounts to be notified
        $result_main = SQL_QUERY($sql, __FILE__, __LINE__);
@@ -118,13 +118,13 @@ LIMIT 1",
                // Shall I send out bonus mails?
                if ($sentBonusMails === true) {
                        // Okay, make array to string
-                       $RECEIVER = implode(";", $UIDs);
+                       $RECEIVER = implode(';', $UIDs);
 
                        // Prepare URL
                        $URL = "modules.php?module=index&amp;what=login";
 
                        // Insert mail
-                       ADD_BONUS_MAIL_TO_QUEUE($subject, $message, $RECEIVER, getConfig('bonus_notify_points'), getConfig('bonus_notify_wait'), $URL, 0, "normal", SQL_NUMROWS($result_main));
+                       ADD_BONUS_MAIL_TO_QUEUE($subject, $message, $RECEIVER, getConfig('bonus_notify_points'), getConfig('bonus_notify_wait'), $URL, 0, 'normal', SQL_NUMROWS($result_main));
                } // END - if
        } // END - if
 
index 4dd0b55cf7bec103ebfca561a49ce2840a78ad9a..0a4994c7ab6e490e3fd3a024052964eedd9de83d 100644 (file)
@@ -113,7 +113,7 @@ if (!isAdminRegistered()) {
                if (REQUEST_ISSET_POST(('login'))) {
                        define('__LOGIN_VALUE', REQUEST_POST('login'));
                } else {
-                       define('__LOGIN_VALUE', "");
+                       define('__LOGIN_VALUE', '');
                }
 
                // Yet-another "Notice" fix
@@ -135,15 +135,15 @@ if (!isAdminRegistered()) {
                        define('__MSG_PASS',  LOAD_TEMPLATE("admin_login_msg", true, $passwdMessage));
 
                        // Reset variables
-                       $loginMessage = ""; $passwdMessage = "";
+                       $loginMessage = ''; $passwdMessage = '';
                } else {
                        // Reset values to nothing
-                       define('__MSG_LOGIN', "");
-                       define('__MSG_PASS' , "");
+                       define('__MSG_LOGIN', '');
+                       define('__MSG_PASS' , '');
                }
 
                // Output message in seperate template
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NOT_REGISTERED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NOT_REGISTERED'));
 
                // Load register template
                LOAD_TEMPLATE("admin_reg_form");
@@ -155,7 +155,7 @@ if (!isAdminRegistered()) {
                $OUT = ADMIN_SEND_PASSWORD_RESET_LINK(REQUEST_POST('email'));
 
                // Output result
-               LOAD_TEMPLATE("admin_settings_saved", false, $OUT);
+               LOAD_TEMPLATE('admin_settings_saved', false, $OUT);
        } elseif (REQUEST_ISSET_GET(('hash'))) {
                // Output form for hash validation
                LOAD_TEMPLATE("admin_validate_reset_hash_form", false, REQUEST_GET('hash'));
@@ -175,7 +175,7 @@ if (!isAdminRegistered()) {
                        LOAD_TEMPLATE("admin_reset_password_form", false, $content);
                } else {
                        // Cannot validate the login data and hash
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_VALIDATION_RESET_LOGIN_HASH_FAILED'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_VALIDATION_RESET_LOGIN_HASH_FAILED'));
                }
        } elseif ((REQUEST_ISSET_POST(('reset_pass'))) && (REQUEST_ISSET_POST(('hash'))) && (REQUEST_ISSET_POST(('login'))) && (REQUEST_ISSET_POST(('pass1'))) && (REQUEST_POST('pass1') == REQUEST_POST('pass2'))) {
                // Okay, we shall the admin password here. So first revalidate the hash
@@ -187,7 +187,7 @@ if (!isAdminRegistered()) {
                        LOAD_TEMPLATE("admin_reset_pass_done", false, $OUT);
                } else {
                        // Validation failed
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_VALIDATION_RESET_LOGIN_HASH_FAILED2'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_VALIDATION_RESET_LOGIN_HASH_FAILED2'));
                }
        } else {
                // Output reset password form
@@ -202,7 +202,7 @@ if (!isAdminRegistered()) {
 
        if (REQUEST_ISSET_GET(('register'))) {
                // Registration of first admin is done
-               if (REQUEST_GET('register') == "done") LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_REGISTER_DONE'));
+               if (REQUEST_GET('register') == "done") LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_REGISTER_DONE'));
        } // END - if
 
        // Check if the admin has submitted data or not
@@ -241,7 +241,7 @@ if (!isAdminRegistered()) {
                        destroyAdminSession();
                        break;
 
-               case "pass": // Wrong password
+               case 'pass': // Wrong password
                        REQUEST_SET_POST('ok', $ret);
                        $ret = "{--WRONG_PASS--} [<a href=\"{!URL!}/modules.php?module=admin&amp;reset_pass=1\">{--ADMIN_RESET_PASS--}</a>]\n";
                        destroyAdminSession();
@@ -259,12 +259,12 @@ if (!isAdminRegistered()) {
                if (REQUEST_ISSET_POST(('login'))) {
                        define('__LOGIN_VALUE', REQUEST_POST('login'));
                } else {
-                       define('__LOGIN_VALUE', "");
+                       define('__LOGIN_VALUE', '');
                }
 
                if (IS_FORM_SENT()) {
                        // Set messages to zero
-                       $loginMessage = ""; $passwdMessage = "";
+                       $loginMessage = ''; $passwdMessage = '';
 
                        // No login entered?
                        if (!REQUEST_ISSET_POST(('login'))) $loginMessage = getMessage('ADMIN_NO_LOGIN');
@@ -279,7 +279,7 @@ if (!isAdminRegistered()) {
                        if (strlen(REQUEST_POST('pass')) < 4) $passwdMessage = getMessage('ADMIN_SHORT_PASS');
 
                        // An error comes back from login?
-                       if ((!empty($ret)) && (REQUEST_POST('ok') == "pass")) $passwdMessage = $ret;
+                       if ((!empty($ret)) && (REQUEST_POST('ok') == 'pass')) $passwdMessage = $ret;
 
                        // Load message template
                        define('__MSG_LOGIN', LOAD_TEMPLATE("admin_login_msg", true, $loginMessage));
@@ -290,8 +290,8 @@ if (!isAdminRegistered()) {
                        unset($passwdMessage);
                } else {
                        // Set constants to empty for hiding them
-                       define('__MSG_LOGIN', "");
-                       define('__MSG_PASS' , "");
+                       define('__MSG_LOGIN', '');
+                       define('__MSG_PASS' , '');
                }
 
                // Load login form
@@ -339,7 +339,7 @@ if (!isAdminRegistered()) {
                }
        } else {
                // Something went wrong here...
-               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_fatal\">{--ADMIN_LOGOUT_FAILED--}</div>");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_fatal\">{--ADMIN_LOGOUT_FAILED--}</div>");
 
                // Add fatal message
                addFatalMessage(__FILE__, __LINE__, getMessage('CANNOT_UNREG_SESS'));
@@ -382,7 +382,7 @@ if (!isAdminRegistered()) {
                addFatalMessage(__FILE__, __LINE__, getMessage('ADMIN_NOT_FOUND'));
                break;
 
-       case "pass": // Wrong password
+       case 'pass': // Wrong password
                REQUEST_SET_POST('ok', $ret);
                destroyAdminSession();
                addFatalMessage(__FILE__, __LINE__, getMessage('WRONG_PASS'));
index 044af67da2036ac9f88659d345ee1bf86dd63f07..ffcee89378b786817053923a3986d5ba390583c5 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 63872aee33b8d09b26bd303495171a9715bf54ef..98f8bacbac51f19ad91820212efe7578ae162ad6 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 748b74e52ebca5e4a96dfe9281845ae16ee0a3af..933e1adb113f74ecc677320b3cc1c4b3a3333b22 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 122937a2533942f1ee3045e853ee81f5e975989e..f41673dc0ffadc3f8efe9ceb5cbc1142242ca7fb 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index d42e64980630c0c50311c444d1eb00cc6736ce6e..eab43a46c41d123360ac6c0b404ed8c63e3a565c 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index e00e8713a6195a401ad9c8eb242ec95cf85f5907..cbe72d46a92dbb51eb22755f74cbadf7491d200b 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index fe58f3db70318e855caec9d70f95b165ecd1d41e..d5bdfce2532cc59c99a04968b294f79fea57eaca 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index a42753e683d5c0225d600fc962213b9457f7f4a2..bf32bfe71f0533f128fc5a7dfc7e9334b2608936 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 8764a6e4314766f673fdb53062a2d3c6c41b811c..e24b8eb249711db4031a55689dcd4568b4458b2f 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (REQUEST_ISSET_POST(('no'))) {
        // Do not logout now
index c5405b8bdae87db73b014a540f334a19ad48cdd0..0aae0a407bda531cd75db97f03cff8ff2cfbbeaf 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 4dd9cf25491ada2166ebad446a2f35ad3c208142..8fd387bbd06124ce24828f01e6cb17a85a3801a4 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index eeb7fa7bf1f5de524b31af456455e8734a8b1de7..cccbecee91d71ed350c36a112db6cc85863466ab 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 6082b99919f83535cdcca7ae04ea5c7bf5bc1116..4a4910d2c55cfc62ee90e9418594fea27393c103 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 852774a2d61ec71194c14dee3118a62f327e521c..ad328aba85f806d44189e2de5402c00007bf5846 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index de8e2b0bdeaac026e1bff4e09e25f5f6982a1a2f..e4421da1b2d03b908bc3bb7c568b4bb11d36ca57 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 4f3583d4ecd37ed42d3f298face7d4bcd192225e..263446a1862add5d25959e96d2fa42fa9254c06d 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 370931a72ca7bb66a5f769b4914162fb96d928fd..ca0bb51e1872578d6145090255776c1f73355719 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index a5bde459d92fc987ccc3e9900b96ab3a80d8f03e..2720de6a191fcc94a6ac7758ec8c1b2498c8e8a6 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 5dce9adaf3f01ff27f89071f68eec1cf0f165bee..d592a703739244cc57f7d91ef086693e3583dc21 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index db2e256f0b8251b920d5e98717d5b13a012984b6..9f8b309b6310a4f13321725dae7cecf652cec27f 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 3c6a3354558b6be3a1a6a9be87f0325687b4986b..65abbcf68ef564e536bd0d0b52627810c7eb08db 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index a5c0c3e686363d3e16eaa9634e47fe1c1476d06c..02944b27a370928ba0714b43bceaacb13fcdd8f8 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("task")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "task");
+} elseif (!EXT_IS_ACTIVE('task')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'task');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index bdd2087dc56e3fd4ab225cc3c9c194090e646a10..2713c007745a27732ed0c11e05f605405c9fff97 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 3aecae200e9ccfe64b45ebd3b015b1981996ab26..d7b948248f58a80df1e0448988dd8045f4810a87 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 957f77b1eea1fef0533542387d5b05f367e3dd47..87520655e338a05fd085fb81dbfc15a3cfa28630 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 3bdf691d1436f5fcffed2a2ec6d2f89330e28a79..8fea412fa42e685d7ac371f52435c32d21a9b950 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/admin/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index f0aff19e6aae954eef2d6e6ef8e1995794ab4d95..f1119eac69426b9e2b5bd988c5d5e2a02c77c91a 100644 (file)
@@ -81,16 +81,16 @@ function CHECK_ADMIN_LOGIN ($admin_login, $password) {
        if (isset($GLOBALS['cache_array']['admins']['password'][$aid])) {
                // Get password from cache
                $data['password'] = $GLOBALS['cache_array']['admins']['password'][$aid];
-               $ret = "pass";
+               $ret = 'pass';
                incrementConfigEntry('cache_hits');
 
                // Include more admins data?
-               if (GET_EXT_VERSION("admins") >= "0.7.2") {
+               if (GET_EXT_VERSION('admins') >= '0.7.2') {
                        // Load them here
                        $data['login_failures'] = $GLOBALS['cache_array']['admins']['login_failures'][$aid];
                        $data['last_failure']   = $GLOBALS['cache_array']['admins']['last_failure'][$aid];
                } // END - if
-       } elseif (!EXT_IS_ACTIVE("cache")) {
+       } elseif (!EXT_IS_ACTIVE('cache')) {
                // Add extra data via filter now
                $add = runFilterChain('sql_admin_extra_data');
 
@@ -101,7 +101,7 @@ function CHECK_ADMIN_LOGIN ($admin_login, $password) {
                // Entry found?
                if (SQL_NUMROWS($result) == 1) {
                        // Login password found
-                       $ret = "pass";
+                       $ret = 'pass';
 
                        // Fetch data
                        $data = SQL_FETCHARRAY($result);
@@ -117,8 +117,8 @@ function CHECK_ADMIN_LOGIN ($admin_login, $password) {
                $data['password'] = generateHash($password);
 
                // Is the sql_patches not installed, than we cannot have a valid hashed password here!
-               if (($ret == "pass") && ((EXT_VERSION_IS_OLDER("sql_patches", "0.3.6")) || (GET_EXT_VERSION("sql_patches") == ""))) $ret = "done";
-       } elseif ((EXT_VERSION_IS_OLDER("sql_patches", "0.3.6")) || (GET_EXT_VERSION("sql_patches") == "")) {
+               if (($ret == 'pass') && ((EXT_VERSION_IS_OLDER('sql_patches', '0.3.6')) || (GET_EXT_VERSION('sql_patches') == ""))) $ret = "done";
+       } elseif ((EXT_VERSION_IS_OLDER('sql_patches', '0.3.6')) || (GET_EXT_VERSION('sql_patches') == "")) {
                // Old hashing way
                return $ret;
        } elseif (!isset($data['password'])) {
@@ -132,13 +132,13 @@ function CHECK_ADMIN_LOGIN ($admin_login, $password) {
 
        // Check if password is same
        //* DEBUG: */ echo "*".$ret.",".$data['password'].",".$password.",".$salt."*<br >\n";
-       if (($ret == "pass") && ($data['password'] == generateHash($password, $salt)) && ((!empty($salt))) || ($data['password'] == $password)) {
+       if (($ret == 'pass') && ($data['password'] == generateHash($password, $salt)) && ((!empty($salt))) || ($data['password'] == $password)) {
                // Re-hash the plain passord with new random salt
                $data['password'] = generateHash($password);
 
                // Do we have 0.7.0 of admins or later?
                // Remmeber login failures if available
-               if (GET_EXT_VERSION("admins") >= "0.7.2") {
+               if (GET_EXT_VERSION('admins') >= '0.7.2') {
                        // Store it in session
                        set_session('mxchange_admin_failures', $data['login_failures']);
                        set_session('mxchange_admin_last_fail', $data['last_failure']);
@@ -153,7 +153,7 @@ function CHECK_ADMIN_LOGIN ($admin_login, $password) {
                }
 
                // Rebuild cache
-               rebuildCacheFiles("admins", "admin");
+               rebuildCacheFiles('admins', 'admin');
 
                // Login has failed by default... ;-)
                $ret = "failed";
@@ -163,7 +163,7 @@ function CHECK_ADMIN_LOGIN ($admin_login, $password) {
                        // All done now
                        $ret = "done";
                } // END - if
-       } elseif ((empty($salt)) && ($ret == "pass")) {
+       } elseif ((empty($salt)) && ($ret == 'pass')) {
                // Something bad went wrong
                $ret = "failed";
        } elseif ($ret == "done") {
@@ -175,13 +175,13 @@ function CHECK_ADMIN_LOGIN ($admin_login, $password) {
        }
 
        // Count login failure if admins extension version is 0.7.0+
-       if (($ret == "pass") && (GET_EXT_VERSION("admins") >= "0.7.0")) {
+       if (($ret == 'pass') && (GET_EXT_VERSION('admins') >= '0.7.0')) {
                // Update counter
                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_admins` SET login_failures=login_failures+1,last_failure=NOW() WHERE id=%s LIMIT 1",
                        array($aid), __FUNCTION__, __LINE__);
 
                // Rebuild cache
-               rebuildCacheFiles("admins", "admin");
+               rebuildCacheFiles('admins', 'admin');
        } // END - if
 
        // Return the result
@@ -192,13 +192,13 @@ function CHECK_ADMIN_LOGIN ($admin_login, $password) {
 // Try to login the admin by setting some session/cookie variables
 function LOGIN_ADMIN ($adminLogin, $passHash) {
        // Reset failure counter on matching admins version
-       if ((GET_EXT_VERSION("admins") >= "0.7.0") && ((EXT_VERSION_IS_OLDER("sql_patches", "0.3.6")) || (GET_EXT_VERSION("sql_patches") == ""))) {
+       if ((GET_EXT_VERSION('admins') >= '0.7.0') && ((EXT_VERSION_IS_OLDER('sql_patches', '0.3.6')) || (GET_EXT_VERSION('sql_patches') == ""))) {
                // Reset counter on out-dated sql_patches version
                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_admins` SET login_failures=0,last_failure='0000-00-00 00:00:00' WHERE login='%s' LIMIT 1",
                        array($adminLogin), __FUNCTION__, __LINE__);
 
                // Rebuild cache
-               rebuildCacheFiles("admins", "admin");
+               rebuildCacheFiles('admins', 'admin');
        } // END - if
 
        // Now set all session variables and return the result
@@ -218,16 +218,16 @@ function LOGIN_ADMIN ($adminLogin, $passHash) {
 // Only be executed on cookie checking
 function CHECK_ADMIN_COOKIES ($admin_login, $password) {
        // By default no admin cookies are found
-       $ret = "404"; $pass = "";
+       $ret = "404"; $pass = '';
 
        // Get hash
        $pass = GET_ADMIN_HASH(GET_ADMIN_ID($admin_login));
-       if ($pass != "-1") $ret = "pass";
+       if ($pass != "-1") $ret = 'pass';
 
        //* DEBUG: */ print __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>):".generatePassString($pass)."(".strlen($pass).")/".$password."(".strlen($password).")<br />\n";
 
        // Check if password matches
-       if (($ret == "pass") && ((generatePassString($pass) == $password) || ($pass == $password) || ((strlen($pass) == 32) && (md5($password) == $pass)))) {
+       if (($ret == 'pass') && ((generatePassString($pass) == $password) || ($pass == $password) || ((strlen($pass) == 32) && (md5($password) == $pass)))) {
                // Passwords matches!
                $ret = "done";
        }
@@ -258,7 +258,7 @@ function ADMIN_DO_ACTION ($wht) {
        define('__ADMIN_ID'   , GET_CURRENT_ADMIN_ID());
 
        // Preload templates
-       if (EXT_IS_ACTIVE("admins")) {
+       if (EXT_IS_ACTIVE('admins')) {
                define('__ADMIN_WELCOME', LOAD_TEMPLATE("admin_welcome_admins", true));
        } else {
                define('__ADMIN_WELCOME', LOAD_TEMPLATE("admin_welcome", true));
@@ -276,7 +276,7 @@ LIMIT 1", array($act, $wht, $wht), __FUNCTION__, __LINE__);
        if (SQL_NUMROWS($result_action) == 1) {
                // Is valid but does the inlcude file exists?
                $INC = sprintf("inc/modules/admin/action-%s.php", $act);
-               if ((INCLUDE_READABLE($INC)) && (VALIDATE_MENU_ACTION("admin", $act, $wht)) && ($GLOBALS['acl_allow'] === true)) {
+               if ((INCLUDE_READABLE($INC)) && (VALIDATE_MENU_ACTION('admin', $act, $wht)) && ($GLOBALS['acl_allow'] === true)) {
                        // Ok, we finally load the admin action module
                        LOAD_INC($INC);
                } elseif ($GLOBALS['acl_allow'] === false) {
@@ -305,14 +305,14 @@ LIMIT 1", array($act, $wht, $wht), __FUNCTION__, __LINE__);
 function ADD_ADMIN_MENU ($act, $wht, $return=false) {
        // Init variables
        $SUB = false;
-       $OUT = "";
+       $OUT = '';
 
        // Menu descriptions
        $GLOBALS['menu']['description'] = array();
        $GLOBALS['menu']['title'] = array();
 
        // Is there a cache instance?
-       if ((isCacheInstanceValid()) && (getConfig('cache_admin_menu') == "Y")) {
+       if ((isCacheInstanceValid()) && (getConfig('cache_admin_menu') == 'Y')) {
                // Create cache name
                $cacheName = "admin_".$act."_".$wht."_".GET_LANGUAGE()."_".strtolower(get_session('admin_login'));
 
@@ -342,8 +342,8 @@ function ADD_ADMIN_MENU ($act, $wht, $return=false) {
 <tr><td colspan=\"2\" height=\"7\" class=\"seperator\">&nbsp;</td></tr>\n";
                // @TODO Rewrite this to $content = SQL_FETCHARRAY()
                while (list($menu, $title, $descr) = SQL_FETCHROW($result_main)) {
-                       if ((EXT_IS_ACTIVE("admins")) && (GET_EXT_VERSION("admins") > "0.2")) {
-                               $ACL = ADMINS_CHECK_ACL($menu, "");
+                       if ((EXT_IS_ACTIVE('admins')) && (GET_EXT_VERSION('admins') > '0.2.0')) {
+                               $ACL = ADMINS_CHECK_ACL($menu, '');
                        } else {
                                // ACL is "allow"... hmmm
                                $ACL = true;
@@ -395,7 +395,7 @@ function ADD_ADMIN_MENU ($act, $wht, $return=false) {
                                        while (list($wht_sub, $title_what, $desc_what) = SQL_FETCHROW($result_what)) {
                                                // Filename
                                                $INC = sprintf("inc/modules/admin/what-%s.php", $wht_sub);
-                                               if ((EXT_IS_ACTIVE("admins")) && (GET_EXT_VERSION("admins") > "0.2")) {
+                                               if ((EXT_IS_ACTIVE('admins')) && (GET_EXT_VERSION('admins') > '0.2.0')) {
                                                        $ACL = ADMINS_CHECK_ACL("", $wht_sub);
                                                } else {
                                                        // ACL is "allow"... hmmm
@@ -456,7 +456,7 @@ function ADD_ADMIN_MENU ($act, $wht, $return=false) {
        }
 
        // Is there a cache instance again?
-       if ((isCacheInstanceValid()) && (getConfig('cache_admin_menu') == "Y")) {
+       if ((isCacheInstanceValid()) && (getConfig('cache_admin_menu') == 'Y')) {
                // Init cache
                $GLOBALS['cache_instance']->init($cacheName);
 
@@ -483,12 +483,12 @@ function ADD_ADMIN_MENU ($act, $wht, $return=false) {
 }
 
 // Create member selection box
-function ADD_MEMBER_SELECTION_BOX ($def="0", $add_all=false, $return=false, $none=false, $field="userid") {
+function ADD_MEMBER_SELECTION_BOX ($def="0", $add_all=false, $return=false, $none=false, $field='userid') {
        // Output selection form with all confirmed user accounts listed
        $result = SQL_QUERY("SELECT userid, surname, family FROM `{!_MYSQL_PREFIX!}_user_data` ORDER BY userid", __FUNCTION__, __LINE__);
 
        // Default output
-       $OUT = "";
+       $OUT = '';
 
        // USe this only for adding points (e.g. adding refs really makes no sence ;-) )
        if ($add_all === true)   $OUT = "      <option value=\"all\">{--ALL_MEMBERS--}</option>\n";
@@ -650,13 +650,13 @@ function ADMIN_SAVE_SETTINGS (&$POST, $tableName = "_config", $whereStatement =
        rebuildCacheFiles("config", "config");
 
        // Settings saved
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_SAVED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_SAVED'));
 }
 
 // Generate a selection box
 function ADMIN_MAKE_MENU_SELECTION ($menu, $type, $name, $default="") {
        // Open the requested menu directory
-       $menuArray = GET_DIR_AS_ARRAY(sprintf("inc/modules/%s/", $menu), "", false, false);
+       $menuArray = GET_DIR_AS_ARRAY(sprintf("inc/modules/%s/", $menu), '', false, false);
 
        // Init the selection box
        $OUT = "<select name=\"".$name."\" class=\"admin_select\" size=\"1\">
@@ -723,8 +723,8 @@ function ADMIN_CHECK_MENU_MODE () {
                // Load from cache
                $ADMIN = $GLOBALS['cache_array']['admins']['la_mode'][$aid];
                incrementConfigEntry('cache_hits');
-       } elseif (GET_EXT_VERSION("admins") >= "0.6.7") {
-               // Load from database when version of "admins" is enough
+       } elseif (GET_EXT_VERSION('admins') >= '0.6.7') {
+               // Load from database when version of 'admins' is enough
                $result = SQL_QUERY_ESC("SELECT la_mode FROM `{!_MYSQL_PREFIX!}_admins` WHERE id=%s LIMIT 1",
                        array($aid), __FUNCTION__, __LINE__);
                if (SQL_NUMROWS($result) == 1) {
@@ -764,7 +764,7 @@ function ADMIN_CHANGE_ACTIVATION_STATUS ($IDs, $table, $row, $idRow = "id") {
                                        list($currStatus) = SQL_FETCHROW($result);
 
                                        // And switch it N<->Y
-                                       if ($currStatus == "Y") $newStatus = "N"; else $newStatus = "Y";
+                                       if ($currStatus == 'Y') $newStatus = "N"; else $newStatus = "Y";
 
                                        // Change this status
                                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_%s` SET %s='%s' WHERE %s=%s LIMIT 1",
@@ -780,10 +780,10 @@ function ADMIN_CHANGE_ACTIVATION_STATUS ($IDs, $table, $row, $idRow = "id") {
                } // END - foreach
 
                // Output status
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_STATUS_CHANGED'), $cnt, count($IDs)));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_STATUS_CHANGED'), $cnt, count($IDs)));
        } else {
                // Nothing selected!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NOTHING_SELECTED_CHANGE'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NOTHING_SELECTED_CHANGE'));
        }
 }
 
@@ -827,7 +827,7 @@ function ADMIN_SEND_BUILD_MAILS ($mode, $table, $content, $id, $subjectPart="")
 
 // Build a special template list
 function ADMIN_BUILD_LIST ($listType, $IDs, $table, $columns, $filterFunctions, $extraValues, $idColumn, $userIdColumn) {
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
 
        // "Walk" through all entries
        foreach ($IDs as $id => $selected) {
@@ -848,7 +848,7 @@ function ADMIN_BUILD_LIST ($listType, $IDs, $table, $columns, $filterFunctions,
                                $idx = array_search($key, $columns, true);
 
                                // Do we have a userid?
-                               if ($key == "userid") {
+                               if ($key == 'userid') {
                                        // Add it again as raw id
                                        $content['uid'] = bigintval($value);
                                } // END - if
@@ -969,7 +969,7 @@ function ADMIN_BUILD_STATUS_HANDLER ($mode, $IDs, $table, $columns, $filterFunct
 }
 
 // Delete rows by given ID numbers
-function ADMIN_DELETE_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFunctions=array(), $extraValues=array(), $deleteNow=false, $idColumn="id", $userIdColumn="userid") {
+function ADMIN_DELETE_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFunctions=array(), $extraValues=array(), $deleteNow=false, $idColumn="id", $userIdColumn='userid') {
        // All valid entries? (We hope so here!)
        if ((is_array($IDs)) && (count($IDs) > 0) && (count($columns) == count($filterFunctions)) && (count($columns) == count($extraValues))) {
                // Shall we delete here or list for deletion?
@@ -978,7 +978,7 @@ function ADMIN_DELETE_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFu
                        $sql = "DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_%s` WHERE %s IN (%s)";
 
                        // Delete them all
-                       $idList = "";
+                       $idList = '';
                        foreach ($IDs as $id => $sel) {
                                // Is there a userid?
                                if (REQUEST_ISSET_POST('uid_raw', $id)) {
@@ -1006,10 +1006,10 @@ function ADMIN_DELETE_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFu
                        // Was this fine?
                        if (SQL_AFFECTEDROWS() == count($IDs)) {
                                // All deleted
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_ALL_ENTRIES_REMOVED'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_ALL_ENTRIES_REMOVED'));
                        } else {
                                // Some are still there :(
-                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_SOME_ENTRIES_NOT_DELETED'), SQL_AFFECTEDROWS(), count($IDs)));
+                               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_SOME_ENTRIES_NOT_DELETED'), SQL_AFFECTEDROWS(), count($IDs)));
                        }
                } else {
                        // List for deletion confirmation
@@ -1019,7 +1019,7 @@ function ADMIN_DELETE_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFu
 }
 
 // Edit rows by given ID numbers
-function ADMIN_EDIT_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFunctions=array(), $extraValues=array(), $editNow=false, $idColumn="id", $userIdColumn="userid") {
+function ADMIN_EDIT_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFunctions=array(), $extraValues=array(), $editNow=false, $idColumn="id", $userIdColumn='userid') {
        // All valid entries? (We hope so here!)
        if ((is_array($IDs)) && (count($IDs) > 0) && (count($columns) == count($filterFunctions)) && (count($columns) == count($extraValues))) {
                // Shall we change here or list for editing?
@@ -1096,10 +1096,10 @@ function ADMIN_EDIT_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFunc
                        // Was this fine?
                        if ($affected == count($IDs)) {
                                // All deleted
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_ALL_ENTRIES_EDITED'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_ALL_ENTRIES_EDITED'));
                        } else {
                                // Some are still there :(
-                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_SOME_ENTRIES_NOT_EDITED'), $affected, count($IDs)));
+                               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_SOME_ENTRIES_NOT_EDITED'), $affected, count($IDs)));
                        }
                } else {
                        // List for editing
@@ -1109,7 +1109,7 @@ function ADMIN_EDIT_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFunc
 }
 
 // Un-/lock rows by given ID numbers
-function ADMIN_LOCK_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFunctions=array(), $extraValues=array(), $statusArray=array(), $lockNow=false, $idColumn="id", $userIdColumn="userid") {
+function ADMIN_LOCK_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFunctions=array(), $extraValues=array(), $statusArray=array(), $lockNow=false, $idColumn="id", $userIdColumn='userid') {
        // All valid entries? (We hope so here!)
        if ((is_array($IDs)) && (count($IDs) > 0) && (count($columns) == count($filterFunctions)) && (count($columns) == count($extraValues)) && ((!$lockNow) || (count($statusArray) == 1))) {
                // Shall we un-/lock here or list for locking?
@@ -1124,7 +1124,7 @@ function ADMIN_LOCK_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFunc
 }
 
 // Undelete rows by given ID numbers
-function ADMIN_UNDELETE_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFunctions=array(), $extraValues=array(), $statusArray=array(), $lockNow=false, $idColumn="id", $userIdColumn="userid") {
+function ADMIN_UNDELETE_ENTRIES_CONFIRM ($IDs, $table, $columns=array(), $filterFunctions=array(), $extraValues=array(), $statusArray=array(), $lockNow=false, $idColumn="id", $userIdColumn='userid') {
        // All valid entries? (We hope so here!)
        if ((is_array($IDs)) && (count($IDs) > 0) && (count($columns) == count($filterFunctions)) && (count($columns) == count($extraValues)) && ((!$lockNow) || (count($statusArray) == 1))) {
                // Shall we un-/lock here or list for locking?
@@ -1156,7 +1156,7 @@ function ADMIN_TEST_PROXY_SETTINGS ($settingsArray) {
 // Sends out a link to the given email adress so the admin can reset his/her password
 function ADMIN_SEND_PASSWORD_RESET_LINK ($email) {
        // Init output
-       $OUT = "";
+       $OUT = '';
 
        // Compile out security characters (must be for looking up!)
        $email = COMPILE_CODE($email);
@@ -1228,10 +1228,10 @@ function ADMIN_VALIDATE_RESET_LINK_HASH_LOGIN ($hash, $login) {
 // Reset the password for the login. Do NOT call this function without calling above function first!
 function ADMIN_RESET_PASSWORD ($login, $password) {
        // Init hash
-       $passHash = "";
+       $passHash = '';
 
        // Now check if we have sql_patches installed
-       if (GET_EXT_VERSION("sql_patches") >= "0.3.6") {
+       if (GET_EXT_VERSION('sql_patches') >= '0.3.6') {
                // Use new way of hashing
                $passHash = generateHash($password);
        } else {
index 6840cbe603d36df4ebe92fe6969c4aff999af256..3dbffb5c1c3bf170251ec541f3e9139291b61f41 100644 (file)
@@ -48,7 +48,7 @@ function OUTPUT_STANDARD_OVERVIEW(&$result_tasks) {
                array(GET_CURRENT_ADMIN_ID()), __FILE__, __LINE__);
 
        // We currently don't want to install an extension so let's find out if we need...
-       $EXT_LOAD_MODE = "register";
+       $EXT_LOAD_MODE = 'register';
        $jobsDone = true;
 
        // Open the extension directory
@@ -89,7 +89,7 @@ function OUTPUT_STANDARD_OVERVIEW(&$result_tasks) {
 
                                if (isset($GLOBALS['cache_array']['active_extensions'][$ext_name])) {
                                        // Maybe we want to keept the current extension active?
-                                       if (($GLOBALS['cache_array']['active_extensions'][$ext_name] == "Y") && (!EXT_IS_ACTIVE($ext_name))) {
+                                       if (($GLOBALS['cache_array']['active_extensions'][$ext_name] == 'Y') && (!EXT_IS_ACTIVE($ext_name))) {
                                                // Reactivate this extension!
                                                ACTIVATE_EXTENSION($ext_name);
                                        } // END - if
@@ -121,7 +121,7 @@ ORDER BY userid DESC, task_type DESC, subject, task_created DESC",
 function OUTPUT_SELECTED_TASKS ($POST, $result_tasks) {
        if ((isset($POST['assign'])) && (count($POST['task']) > 0)) {
                // Assign / do tasks
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                foreach ($POST['task'] as $id => $sel) {
                        $result_task = SQL_QUERY_ESC("SELECT id, userid, task_type, subject, text, task_created, status, assigned_admin FROM `{!_MYSQL_PREFIX!}_task_system` WHERE id=%s AND (assigned_admin='%s' OR (assigned_admin='0' AND `status`='NEW')) LIMIT 1",
                                array(bigintval($id), GET_CURRENT_ADMIN_ID()), __FILE__, __LINE__);
@@ -136,7 +136,7 @@ function OUTPUT_SELECTED_TASKS ($POST, $result_tasks) {
                                                array(GET_CURRENT_ADMIN_ID(), bigintval($tid)), __FILE__, __LINE__);
                                } // END - if
 
-                               $add = "";
+                               $add = '';
                                if ($type == "SUPPORT_MEMBER") {
                                        $mode = substr($text, 0, strpos($text, ":"));
                                        $text = substr($text, strpos($text, ":") + 1);
@@ -160,11 +160,11 @@ function OUTPUT_SELECTED_TASKS ($POST, $result_tasks) {
                                $text = LOAD_TEMPLATE("admin_extensions_text", true, $text);
 
                                // Initialize variables (no title for SQL commands by default)
-                               $ext_name = "";
+                               $ext_name = '';
                                $title = getMessage('TASK_NO_TITLE');
 
                                // Shall I list SQL commands assigned to an extension installation or update task?
-                               if (((GET_EXT_VERSION("sql_patches") != '') && (getConfig('verbose_sql') == "Y")) || (!EXT_IS_ACTIVE("sql_patches"))) {
+                               if (((GET_EXT_VERSION('sql_patches') != '') && (getConfig('verbose_sql') == 'Y')) || (!EXT_IS_ACTIVE('sql_patches'))) {
                                        $ext_name = substr($subj, 1, strpos($subj, ":") - 1);
                                        if ($type == "EXTENSION") {
                                                // Load SQL commands for registering
@@ -193,13 +193,13 @@ function OUTPUT_SELECTED_TASKS ($POST, $result_tasks) {
                                                $title = getMessage('ADMIN_SQLS_EXECUTED_ON_UPDATE');
                                        } else {
                                                // Remove extension's name
-                                               $ext_name = "";
+                                               $ext_name = '';
                                        }
 
                                        // Add SQLs to a table
                                        if (!IS_SQLS_VALID()) INIT_SQLS();
-                                       if (empty($title)) $title = "";
-                                       if ((!empty($ext_name)) && (GET_EXT_VERSION("sql_patches")) && (getConfig('verbose_sql') == "Y")) {
+                                       if (empty($title)) $title = '';
+                                       if ((!empty($ext_name)) && (GET_EXT_VERSION('sql_patches')) && (getConfig('verbose_sql') == 'Y')) {
                                                // Add verbose SQL table
                                                $text .= EXTENSION_VERBOSE_TABLE($title, " class=\"admin_table top2 left2 right2\"", true, "100%")."<br />\n";
                                        } // END - if
@@ -273,7 +273,7 @@ function OUTPUT_SELECTED_TASKS ($POST, $result_tasks) {
                                        break;
 
                                case "PAYOUT_REQUEST": // Payout requests
-                                       if (EXT_IS_ACTIVE("payout")) {
+                                       if (EXT_IS_ACTIVE('payout')) {
                                                // Extension is installed so let him send a notification to the user
                                                $result_pay = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_user_payouts` WHERE userid=%s AND payout_timestamp=%s LIMIT 1",
                                                        array(bigintval($uid), bigintval($created)), __FILE__, __LINE__);
@@ -298,7 +298,7 @@ function OUTPUT_SELECTED_TASKS ($POST, $result_tasks) {
                                        break;
 
                                case "WERNIS_REQUEST": // Wernis requests
-                                       if (EXT_IS_ACTIVE("wernis")) {
+                                       if (EXT_IS_ACTIVE('wernis')) {
                                                // Extension is installed so let him send a notification to the user
                                                $result_pay = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_user_wernis` WHERE userid=%s AND wernis_timestamp=%s LIMIT 1",
                                                        array(bigintval($uid), bigintval($created)), __FILE__, __LINE__);
@@ -383,7 +383,7 @@ function OUTPUT_SELECTED_TASKS ($POST, $result_tasks) {
                } // END - if
 
                // There are uncompleted jobs!
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result_tasks)) {
                        // Init infos
                        $content['infos'] = "---";
index 19f3994debd2ef988202efab414dc99b5eb243df..8de0e24041089513afe0c82ef7b3248fb29d29e1 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!is_admin())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 //
 ?>
index 1b22f288e8fe843b6ff7dd2e0c46221ac8db11cc..091f8bc60555a96ac390ccb41616af2356751073 100644 (file)
@@ -43,12 +43,12 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Is the formular sent?
 if (IS_FORM_SENT()) {
        // Save the row to the database
-       ADMIN_SAVE_SETTINGS(REQUEST_POST_ARRAY(), "_bank_packages", "", array("account_fee", "interest_plus", "interest_minus", "first_payment"), true);
+       ADMIN_SAVE_SETTINGS(REQUEST_POST_ARRAY(), "_bank_packages", '', array("account_fee", "interest_plus", "interest_minus", "first_payment"), true);
 } else {
        // Display form
        LOAD_TEMPLATE("admin_add_bank_package");
index d431a191cc7fc15a1cd0d088318ed8dc4a13deee..a19cb838f3f1e3cca1137a701964e34d6e7a790f 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Check if category does already exist
index b3bb60ced6ec55120fcbf2b7f7b3768f06e2ac14..d6936169e84088d3acb7e7f96020c31db2256072 100644 (file)
@@ -43,10 +43,10 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Fix a notice
-if (!REQUEST_ISSET_GET(('uid'))) REQUEST_SET_GET('uid', "");
+if (!REQUEST_ISSET_GET('uid')) REQUEST_SET_GET('uid', '');
 
 if (REQUEST_GET('uid') == "all") {
        // Add points to all accounts
@@ -81,12 +81,12 @@ if (REQUEST_GET('uid') == "all") {
                SQL_FREERESULT($result_main);
 
                // Output message
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_ALL_POINTS_ADDED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_ALL_POINTS_ADDED'));
        } else {
                // Display form add points
                LOAD_TEMPLATE("admin_add_points_all");
        }
-} elseif (REQUEST_ISSET_GET(('uid'))) {
+} elseif (REQUEST_ISSET_GET('uid')) {
        // User ID found in URL so we use this give him some credits
        $result = SQL_QUERY_ESC("SELECT surname, family, email FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s AND `status`='CONFIRMED' LIMIT 1",
                array(bigintval(REQUEST_GET('uid'))), __FILE__, __LINE__);
@@ -114,7 +114,7 @@ if (REQUEST_GET('uid') == "all") {
                        $msg = LOAD_EMAIL_TEMPLATE("add-points", $content, bigintval(REQUEST_GET('uid')));
 
                        SEND_EMAIL(bigintval(REQUEST_GET('uid')), getMessage('ADMIN_ADD_SUBJ'), $msg);
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_POINTS_ADDED'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_POINTS_ADDED'));
                } else {
                        // Opps, missing form here
                        // @TODO Rewrite these both constants
@@ -124,7 +124,7 @@ if (REQUEST_GET('uid') == "all") {
                }
        } else {
                // User not found!
-               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
        }
 } else {
        // Output selection form with all confirmed user accounts listed
index 0bb32ca89dbd22e2a085d5059445c4aeeedb5171..668d6eba56722fc086eade2f7cfc4cffc9456f5c 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Generate timestamps
@@ -81,14 +81,14 @@ VALUES ('%s','%s','%s','%s','%s','%s','%s','%s','%s')",
                        LOAD_URL("modules.php?module=admin&amp;what=config_rallye_prices&amp;rallye=".$id);
                } else {
                        // Problem detected...
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('RALLYE_PROBLEM_CREATE'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('RALLYE_PROBLEM_CREATE'));
                }
        } else {
                // Free memory
                SQL_FREERESULT($result);
 
                // Overlapping detected
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('RALLYE_OVERLAP_TIMES'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('RALLYE_OVERLAP_TIMES'));
        }
 }
 
index ce71cf8d18b55b2cc7ef80264254da1670ceb2cc..9fc78f746e3a6ddd47f6677f6234acfcd8a50685 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save sponsor in database
index 53b7eaf110f346e27c2781efb98c0c42b93c1a83..274f2f07ccd50180e0f84e930aafc86ff50bb307 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Was an URL added?
 if ((REQUEST_ISSET_POST(('add'))) && (REQUEST_ISSET_POST(('url')))) {
@@ -56,10 +56,10 @@ if ((REQUEST_ISSET_POST(('add'))) && (REQUEST_ISSET_POST(('url')))) {
        // Then add this URL
        if (SURFBAR_ADMIN_ADD_URL(REQUEST_POST('url'), REQUEST_POST('limit'), REQUEST_POST('reload'))) {
                // URL was added
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_URL_ADDED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_URL_ADDED'));
        } else {
                // Not added
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_URL_NOT_ADDED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_URL_NOT_ADDED'));
        }
 } // END - if
 
index 9b9479cc6696cf115b6e31d88fa0b1b076b355b9..3b92526c35347adea2022c470601f7cf1e7e1383 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Check if the admin has entered title and what-php file name...
 if (((!REQUEST_ISSET_POST(('title'))) || (!REQUEST_ISSET_POST(('menu'))) || (!REQUEST_ISSET_POST(('descr')))) && (IS_FORM_SENT())) {
@@ -75,7 +75,7 @@ if (!IS_FORM_SENT())
 
                // Remove double eintries
                // @TODO This can be somehow rewritten to a function
-               $prev = ""; $dmy = $menus; $dmy2 = $titles; $dmy3 = $below;
+               $prev = ''; $dmy = $menus; $dmy2 = $titles; $dmy3 = $below;
                foreach ($menus as $key => $value)
                {
                        if ($value == $prev)
@@ -117,7 +117,7 @@ if (!IS_FORM_SENT())
 
                                // Remove double eintries
                                // @TODO This can be somehow rewritten to a function
-                               $prev = ""; $dmy = $menus[$value_main]; $dmy2 = $titles[$value_main]; $dmy3 = $below[$value_main];
+                               $prev = ''; $dmy = $menus[$value_main]; $dmy2 = $titles[$value_main]; $dmy3 = $below[$value_main];
                                foreach ($menus[$value_main] as $key => $value) {
                                        if ($value == $prev) {
                                                unset($dmy[$key]);
@@ -160,8 +160,8 @@ if (!IS_FORM_SENT())
        $OUT .= "</select>";
 
        define('__BELOW_SELECTION' , $OUT);
-       define('__WHAT_SELECTION'  , ADMIN_MAKE_MENU_SELECTION("admin", "what", "name"));
-       define('__ACTION_SELECTION', ADMIN_MAKE_MENU_SELECTION("admin", "action", "menu"));
+       define('__WHAT_SELECTION'  , ADMIN_MAKE_MENU_SELECTION('admin', "what", "name"));
+       define('__ACTION_SELECTION', ADMIN_MAKE_MENU_SELECTION('admin', "action", "menu"));
 
        // Display form
        LOAD_TEMPLATE("admin_admin_add");
@@ -191,10 +191,10 @@ if (!IS_FORM_SENT())
                );
                CACHE_PURGE_ADMIN_MENU(0, REQUEST_POST('name'));
        }
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_SAVED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_SAVED'));
 } else {
        // Is demo login!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_NOT_SAVED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_NOT_SAVED'));
 }
 
 //
index 87a8575d8744b71ac4236d69cf76eab70a63922a..d080e206d9a27fd2a61a0676206fe1c7768397e2 100644 (file)
@@ -43,14 +43,14 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Do we edit/delete/change main menus or sub menus?
-$AND = "(`what` = '' OR `what` IS NULL)"; $SUB = "";
-if (REQUEST_ISSET_GET(('sub')))
+$AND = "(`what` = '' OR `what` IS NULL)"; $SUB = '';
+if (REQUEST_ISSET_GET('sub'))
 {
-       $AND = sprintf("`action`='%s' AND `what` IS NOT NULL", REQUEST_GET(('sub')));
-       $SUB = REQUEST_GET(('sub'));
+       $AND = sprintf("`action`='%s' AND `what` IS NOT NULL", REQUEST_GET('sub'));
+       $SUB = REQUEST_GET('sub');
 }
 
 // Get count of (maybe) selected menu points
@@ -78,8 +78,8 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO())) {
 
                                // Prepare data for the row template
                                $content = array(
-                                       'action' => ADMIN_MAKE_MENU_SELECTION("admin", "action", "sel_action[".$sel."]", $act),
-                                       'what'   => ADMIN_MAKE_MENU_SELECTION("admin", "what", "sel_what[".$sel."]", $wht),
+                                       'action' => ADMIN_MAKE_MENU_SELECTION('admin', "action", "sel_action[".$sel."]", $act),
+                                       'what'   => ADMIN_MAKE_MENU_SELECTION('admin', "what", "sel_what[".$sel."]", $wht),
                                        'sw'     => $SW,
                                        'sel'    => $sel,
                                        'menu'   => $menu,
@@ -111,7 +111,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO())) {
        define('__SUB_VALUE', $SUB);
        define('__CHK_VALUE', $chk);
        // Del menu entries with or without confirmation
-       $SW = 2; $cnt = 0; $OUT = "";
+       $SW = 2; $cnt = 0; $OUT = '';
        foreach (REQUEST_POST('sel') as $sel => $confirm)
        {
                if ($confirm == 1)
@@ -180,18 +180,18 @@ WHERE ".$AND." AND id=%s LIMIT 1",
                CACHE_PURGE_ADMIN_MENU(0, REQUEST_POST('sel_action', $sel), REQUEST_POST('sel_what', $sel));
 
                // Load template
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_SAVED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_SAVED'));
                break;
 
        case "del": // Delete menu
                foreach (REQUEST_POST('sel') as $sel => $menu) {
                        SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_admin_menu` WHERE ".$AND." AND id=%s LIMIT 1",
                                array(bigintval($sel)), __FILE__, __LINE__);
-                       CACHE_PURGE_ADMIN_MENU(0, "", "", $AND);
+                       CACHE_PURGE_ADMIN_MENU(0, '', '', $AND);
                } // END - foreach
 
                // Load template
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_SAVED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_SAVED'));
                break;
 
        default: // Unexpected action
@@ -231,7 +231,7 @@ WHERE ".$AND." AND id=%s LIMIT 1",
                                array(bigintval(REQUEST_GET('tid')), bigintval($fid)), __FILE__, __LINE__);
                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_admin_menu` SET `sort`='%s' WHERE ".$AND." AND id=%s LIMIT 1",
                                array(bigintval(REQUEST_GET('fid')), bigintval($tid)), __FILE__, __LINE__);
-                       CACHE_PURGE_ADMIN_MENU(0, "", "", $AND);
+                       CACHE_PURGE_ADMIN_MENU(0, '', '', $AND);
                }
        }
 
@@ -251,7 +251,7 @@ WHERE ".$AND." AND id=%s LIMIT 1",
                define('__SUB_VALUE', $SUB);
 
                // Init variables
-               $OUT = ""; $SW  = 2; $cnt = 0;
+               $OUT = ''; $SW  = 2; $cnt = 0;
 
                // Process all entries
                while ($content = SQL_FETCHARRAY($result)) {
@@ -259,7 +259,7 @@ WHERE ".$AND." AND id=%s LIMIT 1",
                        $cnt++;
 
                        // Init navigation variable
-                       $content['navi'] = "";
+                       $content['navi'] = '';
                        if (($content['sort'] == 0) || (($content['sort'] == 1) && (!empty($SUB)))) {
                                // Is highest position
                                $content['navi'] = "<a href=\"{!URL!}/modules.php?module=admin&amp;what=adminedit&amp;sub={!__SUB_VALUE!}&amp;act=".$content['action']."&amp;w=".$content['what']."&amp;tid=".($content['sort']+1)."&amp;fid=".$content['sort']."\">{--LOWER--}</a>";
@@ -278,7 +278,7 @@ WHERE ".$AND." AND id=%s LIMIT 1",
 
                        // Add more data to $content
                        $content['sw']   = $SW;
-                       $content['mode'] = "admin";
+                       $content['mode'] = 'admin';
 
                        // Load row template and switch colors
                        $OUT .= LOAD_TEMPLATE("admin_menu_overview_row", true, $content);
@@ -295,7 +295,7 @@ WHERE ".$AND." AND id=%s LIMIT 1",
                LOAD_TEMPLATE("admin_amenu_edit");
        } else {
                // Menu entries are missing... (???)
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NO_MENUS_FOUND'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NO_MENUS_FOUND'));
        }
 }
 
index 2935f1230e65731a6c7a727457be60e42bfb9352..6f17e02cd1e28adb3d9a0b3ca034993568f18718 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Display form is default
 $FORM = true;
@@ -55,7 +55,7 @@ if ((REQUEST_ISSET_POST(('add'))) && (REQUEST_ISSET_POST(('login'))) && (REQUEST
                $FORM = false;
 
                // Admin login saved
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_ADMINS_ADD_DONE'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_ADMINS_ADD_DONE'));
 
                // Run filter chain
                runFilterChain('post_admin_added', REQUEST_POST_ARRAY());
@@ -66,8 +66,8 @@ if ((REQUEST_ISSET_POST(('add'))) && (REQUEST_ISSET_POST(('login'))) && (REQUEST
 if ($FORM === true) {
        // Set missing elements
        // @TODO Do we still need this ugly code here?
-       if (!REQUEST_ISSET_POST(('login'))) REQUEST_SET_POST('login', "");
-       if (!REQUEST_ISSET_POST(('email'))) REQUEST_SET_POST('email', "");
+       if (!REQUEST_ISSET_POST(('login'))) REQUEST_SET_POST('login', '');
+       if (!REQUEST_ISSET_POST(('email'))) REQUEST_SET_POST('email', '');
 
        // Load form from template
        LOAD_TEMPLATE("admin_admins_add");
index 4cd6523c195c001211de2173e49197563e437f20..b7805a01c71b0b64bca776038c4e945cbd33cde2 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if ((IS_FORM_SENT()) && (REQUEST_ISSET_GET('admin'))) {
        // Send mail or message
@@ -61,7 +61,7 @@ if ((IS_FORM_SENT()) && (REQUEST_ISSET_GET('admin'))) {
        }
 
        // Mail / message dropped
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMINS_ADMIN_CONTACTED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMINS_ADMIN_CONTACTED'));
 } elseif (REQUEST_ISSET_GET('admin')) {
        // Load contact form template
        define('__ADMIN', REQUEST_GET('admin'));
@@ -75,7 +75,7 @@ if ((IS_FORM_SENT()) && (REQUEST_ISSET_GET('admin'))) {
        LOAD_TEMPLATE("admin_admins_contct_form");
 } else {
        // Please select an admin!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMINS_SELECT_ADMIN'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMINS_SELECT_ADMIN'));
 }
 
 //
index 2ba1e8bab2bbdd6ec1fa9a77a18dda7d72ac27a1..ae1fff666566445dac7e9cddfc3ed9b732a2c5ce 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Set selection data to empty array when it is empty
 if (!REQUEST_ISSET_POST('sel')) REQUEST_SET_POST('sel', array());
index 3f8f9d8be87362a6de60422b4f51569836862673..a39dedae8851c90a75e7daeed55a34b4b1d7b9da 100644 (file)
@@ -43,32 +43,32 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (REQUEST_ISSET_POST('edit')) {
        // Check if entires are checked
        $SEL = SELECTION_COUNT(REQUEST_POST('sel'));
        if ($SEL > 0) {
                // Add option for events
-               $GLOBALS['cache_array']['admins'] = ADD_OPTION_LINES("admins", "id", "login", "", "email");
-               $SW = 2; $rowNameS = "";
+               $GLOBALS['cache_array']['admins'] = ADD_OPTION_LINES('admins', "id", "login", '', 'email');
+               $SW = 2; $rowNameS = '';
                foreach (REQUEST_POST('sel') as $template => $sel) {
                        // First of all load data from DB
                        $result = SQL_QUERY_ESC("SELECT admin_id, id FROM `{!_MYSQL_PREFIX!}_admins_mails` WHERE mail_template='%s' ORDER BY `id`",
                                array($template), __FILE__, __LINE__);
-                       $OUT = ""; $aid2 = 0;
+                       $OUT = ''; $aid2 = 0;
                        while ($content = SQL_FETCHARRAY($result)) {
                                // @TODO Can this be rewritten???
                                $OUT .= "<select name=\"admin_id[".$content['id']."]\" size=\"1\" class=\"admin_select\">
 <option value=\"0\"";
                                if ($content['admin_id'] == "0") $OUT .= " selected=\"selected\"";
                                $OUT .=">{--ADMINS_ALL_ADMINS--}</option>\n";
-                               if (EXT_IS_ACTIVE("events")) {
+                               if (EXT_IS_ACTIVE('events')) {
                                        $OUT .= "<option value=\"-1\"";
                                        if ($content['admin_id'] == "-1") $OUT .= " selected=\"selected\"";
                                        $OUT .= ">{--ADMINS_TO_USER_EVENTS--}</option>\n";
                                }
-                               $OUT .= ADD_OPTION_LINES("admins", "id", "login", $content['admin_id'], "email");
+                               $OUT .= ADD_OPTION_LINES('admins', "id", "login", $content['admin_id'], 'email');
                                $OUT .= "</select>\n<br />\n";
                                $aid2 = $content['admin_id']; $id2 = $content['id'];
                        }
@@ -104,7 +104,7 @@ if (REQUEST_ISSET_POST('edit')) {
                LOAD_TEMPLATE("admin_admins_mails_edit");
        } else {
                // Nothing selected
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMINS_NO_MAIL_CHECKED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMINS_NO_MAIL_CHECKED'));
        }
 } else {
        // Load all assigned mails
@@ -152,7 +152,7 @@ ORDER BY m.admin_id, m.mail_template", __FILE__, __LINE__);
                } // END - if
 
                // List found entries
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($data = SQL_FETCHARRAY($result)) {
                        // Prepare content
                        $content = array(
@@ -177,7 +177,7 @@ ORDER BY m.admin_id, m.mail_template", __FILE__, __LINE__);
                LOAD_TEMPLATE("admin_admins_mails_list");
        } else {
                // No entries found
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMINS_MAILS_NO_ENTRIES'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMINS_MAILS_NO_ENTRIES'));
        }
 }
 
index c80c99b28da335900de7ba365bb319d82ce523c1..2a01d1e625e4669ae077b721070e4a9da7af941f 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 //
 ?>
index 65cf634c9eaa2b7a45644483abab19b901f88d57..684e3b60206142e0fc1bde76ae8e9b6ebb4f3a0a 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Calculate total hits
 $totalHits = (getConfig('db_hits') + getConfig('cache_hits'));
index cb4b4e7a6b7d1e50bd89403b7f4d3b650f53b1af..e583aa7f2ce4acfe4e72cea869b69aaef007c9ac 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR ("admin", basename(__FILE__));
+ADD_DESCR ('admin', basename(__FILE__));
 
 // Check for accounts
 $result = SQL_QUERY("SELECT userid, gender, surname, family, email, REMOTE_ADDR, refid, user_hash
@@ -53,7 +53,7 @@ ORDER BY userid ASC", __FILE__, __LINE__);
 
 if (SQL_NUMROWS($result) > 0) {
        // We have some (new?) registrations!
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Add link to refid
                if ($content['refid'] > 0) $content['refid'] = ADMIN_USER_PROFILE_LINK($content['refid']);
@@ -85,7 +85,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("admin_reg");
 } else {
        // No registrations left - or all has confirmed their email address... :-)
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_ALL_CONFIRMED_EMAIL'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_ALL_CONFIRMED_EMAIL'));
 }
 
 // Free memory
index a658a20b1d590b68815f8415acbbf270d2e6a298..8eae76c3620d3fa0c80bbd74c252d86b7bd3140f 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save data
index 81d5ef2fb55807d43aef2325c4f71cb413900368..6db300e1794fbb34e94284a18d6718dd801d1661 100644 (file)
@@ -42,7 +42,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        require($INC);
 }
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save configuration
@@ -52,13 +52,13 @@ if (IS_FORM_SENT()) {
        switch (getConfig('admin_menu'))
        {
        case "NEW":
-               define('__ADMIN_MENU_NEW', " checked=\"checked\"");
-               define('__ADMIN_MENU_OLD'   , "");
+               define('__ADMIN_MENU_NEW', ' chkecked="checked"');
+               define('__ADMIN_MENU_OLD'   , '');
                break;
 
        case "OLD":
-               define('__ADMIN_MENU_NEW', "");
-               define('__ADMIN_MENU_OLD'   , " checked=\"checked\"");
+               define('__ADMIN_MENU_NEW', '');
+               define('__ADMIN_MENU_OLD'   , ' chkecked="checked"');
                break;
        }
 
index eb0ab1447064940e223fd2a840989f12034bd852..c3f1b65da864afde10994a36f65d1f3f314c494b 100644 (file)
@@ -43,14 +43,14 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 $SEL = 0;
 if (REQUEST_ISSET_POST('sel')) $SEL = SELECTION_COUNT(REQUEST_POST('sel'));
 
 if ((REQUEST_ISSET_POST('edit')) && ($SEL > 0)) {
        // Edit ACLs
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('sel') as $id => $selected) {
                // Load data for the ID
                $result = SQL_QUERY_ESC("SELECT admin_id, action_menu, what_menu, access_mode FROM `{!_MYSQL_PREFIX!}_admins_acls` WHERE id=%s LIMIT 1",
@@ -62,7 +62,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($SEL > 0)) {
                $content = array(
                        'sw'               => $SW,
                        'id'               => $id,
-                       'admins_selection' => ADD_OPTION_LINES("admins", "id", "login", $aid, "default_acl"),
+                       'admins_selection' => ADD_OPTION_LINES('admins', "id", "login", $aid, "default_acl"),
                        'action_selection' => ADMIN_MENU_SELECTION("action", $act, $id),
                        'what_selection'   => ADMIN_MENU_SELECTION("what", $wht, $id),
                        'mode_options'     => ADD_OPTION_LINES(
@@ -99,7 +99,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($SEL > 0)) {
        }
 
        // Update cache when installed
-       if (EXT_IS_ACTIVE("cache")) {
+       if (EXT_IS_ACTIVE('cache')) {
                if ($GLOBALS['cache_instance']->loadCacheFile("admins_acls")) $GLOBALS['cache_instance']->destroyCacheFile();
 
                // Purge menu cache
@@ -107,10 +107,10 @@ if ((REQUEST_ISSET_POST('edit')) && ($SEL > 0)) {
        }
 
        // Entries changed
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_ADMINS_ENTRIES_CHANGED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_ADMINS_ENTRIES_CHANGED'));
 } elseif ((REQUEST_ISSET_POST('del')) && ($SEL > 0)) {
        // Delete ACLs
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('sel') as $id => $selected) {
                // Load data for the ID
                $result = SQL_QUERY_ESC("SELECT admin_id, action_menu, what_menu, access_mode FROM `{!_MYSQL_PREFIX!}_admins_acls` WHERE id=%s LIMIT 1",
@@ -154,7 +154,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($SEL > 0)) {
        }
 
        // Update cache when installed
-       if (EXT_IS_ACTIVE("cache")) {
+       if (EXT_IS_ACTIVE('cache')) {
                if ($GLOBALS['cache_instance']->loadCacheFile("admins_acls")) $GLOBALS['cache_instance']->destroyCacheFile();
 
                // @TODO This causes the whole (!) menu cache being rebuild
@@ -162,7 +162,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($SEL > 0)) {
        }
 
        // Entries deleted
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_ADMINS_ENTRIES_DELETED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_ADMINS_ENTRIES_DELETED'));
 } elseif (REQUEST_ISSET_POST(('add'))) {
        // Check if everything is fine...
        $mode = GET_ADMIN_DEFAULT_ACL(bigintval(REQUEST_POST('admin_id')));
@@ -171,7 +171,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($SEL > 0)) {
        $ACL = false;
        if (REQUEST_ISSET_POST(('what_menu'))) {
                // Check parent ACL
-               $ACL = ADMINS_CHECK_ACL(GET_ACTION("admin", REQUEST_POST('what_menu')), "");
+               $ACL = ADMINS_CHECK_ACL(GET_ACTION('admin', REQUEST_POST('what_menu')), '');
        }
 
        if ($mode != REQUEST_POST('mode') || ($ACL)) {
@@ -194,7 +194,7 @@ VALUES ('%s','%s','%s','%s')",
                                $content = getMessage('ADMIN_ADMINS_ACL_SAVED');
 
                                // Update cache when installed
-                               if (EXT_IS_ACTIVE("cache")) {
+                               if (EXT_IS_ACTIVE('cache')) {
                                        if ($GLOBALS['cache_instance']->loadCacheFile("admins_acls")) $GLOBALS['cache_instance']->destroyCacheFile();
 
                                        // Purge cache
@@ -217,13 +217,13 @@ VALUES ('%s','%s','%s','%s')",
        }
 
        // Display message
-       LOAD_TEMPLATE("admin_settings_saved", false, $content);
+       LOAD_TEMPLATE('admin_settings_saved', false, $content);
 } else {
        // List all ACLs
        $result_acls = SQL_QUERY("SELECT id, admin_id, action_menu, what_menu, access_mode FROM `{!_MYSQL_PREFIX!}_admins_acls` ORDER BY admin_id, id", __FILE__, __LINE__);
        if (SQL_NUMROWS($result_acls) > 0) {
                // List ACLs
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result_acls)) {
                        // Prepare variables
                        if (empty($content['action_menu'])) $content['action_menu'] = "---";
@@ -256,7 +256,7 @@ VALUES ('%s','%s','%s','%s')",
        }
 
        // Prepare some constants for the template
-       define('_ADMINS_SELECTION', ADD_OPTION_LINES("admins", "id", "login", "", "default_acl"));
+       define('_ADMINS_SELECTION', ADD_OPTION_LINES('admins', "id", "login", '', "default_acl"));
        define('_ACTION_SELECTION', ADMIN_MENU_SELECTION("action"));
        define('_WHAT_SELECTION'  , ADMIN_MENU_SELECTION("what"));
        define('_MODE_OPTIONS'    ,
index 2e33d729ac9f0eaf2e6e7851f0d907b870d6ec86..92ecc56c9f70a20df2fc7121b331f8f8a65fe721 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Data was submitted so we store it
@@ -71,11 +71,11 @@ if (IS_FORM_SENT()) {
        // Mail confirmation links
        define('_CFG_AUTO_PURGE', CREATE_TIME_SELECTIONS(getConfig('auto_purge'), "auto_purge", "MWD"));
        if (getConfig('auto_purge_active') != "Y") {
-               define('_CFG_AP_ACTIVE_N', " checked=\"checked\"");
-               define('_CFG_AP_ACTIVE_Y', "");
+               define('_CFG_AP_ACTIVE_N', ' chkecked="checked"');
+               define('_CFG_AP_ACTIVE_Y', '');
        } else {
-               define('_CFG_AP_ACTIVE_N', "");
-               define('_CFG_AP_ACTIVE_Y', " checked=\"checked\"");
+               define('_CFG_AP_ACTIVE_N', '');
+               define('_CFG_AP_ACTIVE_Y', ' chkecked="checked"');
        }
 
        // Output template
index a1f99c0434430db9f3dddef027d166349fed9c8f..c9b82cbd2521114db3bdafa34c49544ecc9f4d1e 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Translate german decimal commas to computer decimal dots
@@ -72,121 +72,121 @@ if (IS_FORM_SENT()) {
        // Activate / Deactivate beg rallye (Y/N)
        switch (getConfig('beg_rallye'))
        {
-       case "Y":
-               define('__BEG_RALLYE_Y', " checked=\"checked\"");
-               define('__BEG_RALLYE_N', "");
+       case 'Y':
+               define('__BEG_RALLYE_Y', ' chkecked="checked"');
+               define('__BEG_RALLYE_N', '');
                break;
 
-       case "N":
-               define('__BEG_RALLYE_Y', "");
-               define('__BEG_RALLYE_N', " checked=\"checked\"");
+       case 'N':
+               define('__BEG_RALLYE_Y', '');
+               define('__BEG_RALLYE_N', ' chkecked="checked"');
                break;
        }
 
        switch (getConfig('beg_active'))
        {
-       case "Y":
-               define('__BEG_ACTIVE_Y', " checked=\"checked\"");
-               define('__BEG_ACTIVE_N', "");
+       case 'Y':
+               define('__BEG_ACTIVE_Y', ' chkecked="checked"');
+               define('__BEG_ACTIVE_N', '');
                break;
 
-       case "N":
-               define('__BEG_ACTIVE_Y', "");
-               define('__BEG_ACTIVE_N', " checked=\"checked\"");
+       case 'N':
+               define('__BEG_ACTIVE_Y', '');
+               define('__BEG_ACTIVE_N', ' chkecked="checked"');
                break;
        }
 
        switch (getConfig('beg_mode'))
        {
        case "DIRECT":
-               define('__BEG_MODE_DIRECT', " checked=\"checked\"");
-               define('__BEG_MODE_REF'   , "");
+               define('__BEG_MODE_DIRECT', ' chkecked="checked"');
+               define('__BEG_MODE_REF'   , '');
                break;
 
        case "REF":
-               define('__BEG_MODE_DIRECT', "");
-               define('__BEG_MODE_REF'   , " checked=\"checked\"");
+               define('__BEG_MODE_DIRECT', '');
+               define('__BEG_MODE_REF'   , ' chkecked="checked"');
                break;
        }
 
        switch (getConfig('beg_ral_en_notify'))
        {
-       case "Y":
-               define('__BEG_RAL_EN_NOTIFY_Y', " checked=\"checked\"");
-               define('__BEG_RAL_EN_NOTIFY_N', "");
+       case 'Y':
+               define('__BEG_RAL_EN_NOTIFY_Y', ' chkecked="checked"');
+               define('__BEG_RAL_EN_NOTIFY_N', '');
                break;
 
-       case "N":
-               define('__BEG_RAL_EN_NOTIFY_Y', "");
-               define('__BEG_RAL_EN_NOTIFY_N', " checked=\"checked\"");
+       case 'N':
+               define('__BEG_RAL_EN_NOTIFY_Y', '');
+               define('__BEG_RAL_EN_NOTIFY_N', ' chkecked="checked"');
                break;
        }
 
        switch (getConfig('beg_ral_di_notify'))
        {
-       case "Y":
-               define('__BEG_RAL_DI_NOTIFY_Y', " checked=\"checked\"");
-               define('__BEG_RAL_DI_NOTIFY_N', "");
+       case 'Y':
+               define('__BEG_RAL_DI_NOTIFY_Y', ' chkecked="checked"');
+               define('__BEG_RAL_DI_NOTIFY_N', '');
                break;
 
-       case "N":
-               define('__BEG_RAL_DI_NOTIFY_Y', "");
-               define('__BEG_RAL_DI_NOTIFY_N', " checked=\"checked\"");
+       case 'N':
+               define('__BEG_RAL_DI_NOTIFY_Y', '');
+               define('__BEG_RAL_DI_NOTIFY_N', ' chkecked="checked"');
                break;
        }
 
        switch (getConfig('beg_new_mem_notify'))
        {
-       case "Y":
-               define('__BEG_NEW_MEMBER_NOTIFY_Y', " checked=\"checked\"");
-               define('__BEG_NEW_MEMBER_NOTIFY_N', "");
+       case 'Y':
+               define('__BEG_NEW_MEMBER_NOTIFY_Y', ' chkecked="checked"');
+               define('__BEG_NEW_MEMBER_NOTIFY_N', '');
                break;
 
-       case "N":
-               define('__BEG_NEW_MEMBER_NOTIFY_Y', "");
-               define('__BEG_NEW_MEMBER_NOTIFY_N', " checked=\"checked\"");
+       case 'N':
+               define('__BEG_NEW_MEMBER_NOTIFY_Y', '');
+               define('__BEG_NEW_MEMBER_NOTIFY_N', ' chkecked="checked"');
                break;
        }
 
        switch (getConfig('beg_include_own'))
        {
-       case "Y":
-               define('__BEG_INCLUDE_OWN_Y', " checked=\"checked\"");
-               define('__BEG_INCLUDE_OWN_N', "");
+       case 'Y':
+               define('__BEG_INCLUDE_OWN_Y', ' chkecked="checked"');
+               define('__BEG_INCLUDE_OWN_N', '');
                break;
 
-       case "N":
-               define('__BEG_INCLUDE_OWN_Y', "");
-               define('__BEG_INCLUDE_OWN_N', " checked=\"checked\"");
+       case 'N':
+               define('__BEG_INCLUDE_OWN_Y', '');
+               define('__BEG_INCLUDE_OWN_N', ' chkecked="checked"');
                break;
        }
 
        switch (getConfig('beg_pay_mode')) {
                case "IMG":
                        define('__BEG_PAY_MODE_IMG' , " selected=\"selected\"");
-                       define('__BEG_PAY_MODE_JS'  , "");
-                       define('__BEG_PAY_MODE_BOTH', "");
-                       define('__BEG_PAY_MODE_NONE', "");
+                       define('__BEG_PAY_MODE_JS'  , '');
+                       define('__BEG_PAY_MODE_BOTH', '');
+                       define('__BEG_PAY_MODE_NONE', '');
                        break;
 
                case "JS":
-                       define('__BEG_PAY_MODE_IMG' , "");
+                       define('__BEG_PAY_MODE_IMG' , '');
                        define('__BEG_PAY_MODE_JS'  , " selected=\"selected\"");
-                       define('__BEG_PAY_MODE_BOTH', "");
-                       define('__BEG_PAY_MODE_NONE', "");
+                       define('__BEG_PAY_MODE_BOTH', '');
+                       define('__BEG_PAY_MODE_NONE', '');
                        break;
 
                case "BOTH":
-                       define('__BEG_PAY_MODE_IMG' , "");
-                       define('__BEG_PAY_MODE_JS'  , "");
+                       define('__BEG_PAY_MODE_IMG' , '');
+                       define('__BEG_PAY_MODE_JS'  , '');
                        define('__BEG_PAY_MODE_BOTH', " selected=\"selected\"");
-                       define('__BEG_PAY_MODE_NONE', "");
+                       define('__BEG_PAY_MODE_NONE', '');
                        break;
 
                case "NONE":
-                       define('__BEG_PAY_MODE_IMG' , "");
-                       define('__BEG_PAY_MODE_JS'  , "");
-                       define('__BEG_PAY_MODE_BOTH', "");
+                       define('__BEG_PAY_MODE_IMG' , '');
+                       define('__BEG_PAY_MODE_JS'  , '');
+                       define('__BEG_PAY_MODE_BOTH', '');
                        define('__BEG_PAY_MODE_NONE', " selected=\"selected\"");
                        break;
        }
index bbe078d52f16aefcd988b8a2c915d891fd6413ba..bbfc37fae71121336197b0d5760a536b60a624a9 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save configuration
@@ -53,26 +53,26 @@ if (IS_FORM_SENT()) {
        define('__POINTS_VALUE', getConfig('birthday_points'));
        switch (getConfig('birthday_active'))
        {
-       case "Y":
-               define('__BIRTHDAY_ACTIVE_Y', " checked=\"checked\"");
-               define('__BIRTHDAY_ACTIVE_N', "");
+       case 'Y':
+               define('__BIRTHDAY_ACTIVE_Y', ' chkecked="checked"');
+               define('__BIRTHDAY_ACTIVE_N', '');
                break;
 
-       case "N":
-               define('__BIRTHDAY_ACTIVE_Y', "");
-               define('__BIRTHDAY_ACTIVE_N', " checked=\"checked\"");
+       case 'N':
+               define('__BIRTHDAY_ACTIVE_Y', '');
+               define('__BIRTHDAY_ACTIVE_N', ' chkecked="checked"');
                break;
        }
        switch (getConfig('birthday_mode'))
        {
        case "DIRECT":
-               define('__BIRTHDAY_MODE_DIRECT', " checked=\"checked\"");
-               define('__BIRTHDAY_MODE_REF'   , "");
+               define('__BIRTHDAY_MODE_DIRECT', ' chkecked="checked"');
+               define('__BIRTHDAY_MODE_REF'   , '');
                break;
 
        case "REF":
-               define('__BIRTHDAY_MODE_DIRECT', "");
-               define('__BIRTHDAY_MODE_REF'   , " checked=\"checked\"");
+               define('__BIRTHDAY_MODE_DIRECT', '');
+               define('__BIRTHDAY_MODE_REF'   , ' chkecked="checked"');
                break;
        }
 
index c39aac612ab26d497421c79a371aaa8c112aec78..1ea7250a868e251c1d453b18da69b0f38dac83fc 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Replace german decimal commas to computer decimal dots
@@ -54,17 +54,17 @@ if (IS_FORM_SENT()) {
        REQUEST_SET_POST('bonus_notify_points', REVERT_COMMA(REQUEST_POST('bonus_notify_points')));
 
        // Generate string for saving ranks
-       REQUEST_SET_POST('turbo_rates', "");
+       REQUEST_SET_POST('turbo_rates', '');
        $RATES = array();
        foreach (REQUEST_POST('rate') as $rate) {
                $rate = trim(REVERT_COMMA($rate));
                if (!empty($rate)) $RATES[] = $rate;
        }
-       REQUEST_SET_POST('turbo_rates', trim(implode(";", $RATES)));
+       REQUEST_SET_POST('turbo_rates', trim(implode(';', $RATES)));
        REQUEST_UNSET_POST(('rate'));
 
        // Automatically calculate bonus points for ranks 2 and 3 when not set
-       if (!REQUEST_ISSET_POST(('turbo_rates'))) REQUEST_SET_POST('turbo_rates', "".round(getConfig('turbo_bonus') / 2).";".round(getConfig('turbo_bonus') / 4)."");
+       if (!REQUEST_ISSET_POST(('turbo_rates'))) REQUEST_SET_POST('turbo_rates', "".round(getConfig('turbo_bonus') / 2).';'.round(getConfig('turbo_bonus') / 4)."");
 
        // Save data
        ADMIN_SAVE_SETTINGS_POST();
@@ -89,7 +89,7 @@ if (IS_FORM_SENT()) {
 
        // Initialize array for the points list
        //die("*".getConfig('turbo_rates')."*");
-       $RANKS = explode(";", getConfig('turbo_rates'));
+       $RANKS = explode(';', getConfig('turbo_rates'));
 
        // Automatically calculate bonus points for ranks 2 and 3 when not set
        if (getConfig('turbo_rates') == "") $RANKS = array(round(getConfig('turbo_bonus') / 2), round(getConfig('turbo_bonus') / 4));
@@ -122,123 +122,123 @@ if (IS_FORM_SENT()) {
        // Activate / Deactivate bonus active rallye (Y/N)
        switch (getConfig('bonus_active'))
        {
-       case "Y":
-               define('__BONUS_ACTIVE_Y', " checked=\"checked\"");
-               define('__BONUS_ACTIVE_N', "");
+       case 'Y':
+               define('__BONUS_ACTIVE_Y', ' chkecked="checked"');
+               define('__BONUS_ACTIVE_N', '');
                break;
 
-       case "N":
-               define('__BONUS_ACTIVE_Y', "");
-               define('__BONUS_ACTIVE_N', " checked=\"checked\"");
+       case 'N':
+               define('__BONUS_ACTIVE_Y', '');
+               define('__BONUS_ACTIVE_N', ' chkecked="checked"');
                break;
        }
        // Other bonus to de-/activate
        switch (getConfig('bonus_login_yn'))
        {
-       case "Y":
-               define('__BONUS_LOGIN_Y', " checked=\"checked\"");
-               define('__BONUS_LOGIN_N', "");
+       case 'Y':
+               define('__BONUS_LOGIN_Y', ' chkecked="checked"');
+               define('__BONUS_LOGIN_N', '');
                break;
 
-       case "N":
-               define('__BONUS_LOGIN_Y', "");
-               define('__BONUS_LOGIN_N', " checked=\"checked\"");
+       case 'N':
+               define('__BONUS_LOGIN_Y', '');
+               define('__BONUS_LOGIN_N', ' chkecked="checked"');
                break;
        }
        switch (getConfig('bonus_stats_yn'))
        {
-       case "Y":
-               define('__BONUS_STATS_Y', " checked=\"checked\"");
-               define('__BONUS_STATS_N', "");
+       case 'Y':
+               define('__BONUS_STATS_Y', ' chkecked="checked"');
+               define('__BONUS_STATS_N', '');
                break;
 
-       case "N":
-               define('__BONUS_STATS_Y', "");
-               define('__BONUS_STATS_N', " checked=\"checked\"");
+       case 'N':
+               define('__BONUS_STATS_Y', '');
+               define('__BONUS_STATS_N', ' chkecked="checked"');
                break;
        }
        switch (getConfig('bonus_order_yn'))
        {
-       case "Y":
-               define('__BONUS_ORDER_Y', " checked=\"checked\"");
-               define('__BONUS_ORDER_N', "");
+       case 'Y':
+               define('__BONUS_ORDER_Y', ' chkecked="checked"');
+               define('__BONUS_ORDER_N', '');
                break;
 
-       case "N":
-               define('__BONUS_ORDER_Y', "");
-               define('__BONUS_ORDER_N', " checked=\"checked\"");
+       case 'N':
+               define('__BONUS_ORDER_Y', '');
+               define('__BONUS_ORDER_N', ' chkecked="checked"');
                break;
        }
        switch (getConfig('bonus_ref_yn'))
        {
-       case "Y":
-               define('__BONUS_REF_Y', " checked=\"checked\"");
-               define('__BONUS_REF_N', "");
+       case 'Y':
+               define('__BONUS_REF_Y', ' chkecked="checked"');
+               define('__BONUS_REF_N', '');
                break;
 
-       case "N":
-               define('__BONUS_REF_Y', "");
-               define('__BONUS_REF_N', " checked=\"checked\"");
+       case 'N':
+               define('__BONUS_REF_Y', '');
+               define('__BONUS_REF_N', ' chkecked="checked"');
                break;
        }
        switch (getConfig('bonus_click_yn'))
        {
-       case "Y":
-               define('__BONUS_CLICK_Y', " checked=\"checked\"");
-               define('__BONUS_CLICK_N', "");
+       case 'Y':
+               define('__BONUS_CLICK_Y', ' chkecked="checked"');
+               define('__BONUS_CLICK_N', '');
                break;
 
-       case "N":
-               define('__BONUS_CLICK_Y', "");
-               define('__BONUS_CLICK_N', " checked=\"checked\"");
+       case 'N':
+               define('__BONUS_CLICK_Y', '');
+               define('__BONUS_CLICK_N', ' chkecked="checked"');
                break;
        }
        switch (getConfig('bonus_en_notify'))
        {
-       case "Y":
-               define('__BONUS_EN_NOTIFY_Y', " checked=\"checked\"");
-               define('__BONUS_EN_NOTIFY_N', "");
+       case 'Y':
+               define('__BONUS_EN_NOTIFY_Y', ' chkecked="checked"');
+               define('__BONUS_EN_NOTIFY_N', '');
                break;
 
-       case "N":
-               define('__BONUS_EN_NOTIFY_Y', "");
-               define('__BONUS_EN_NOTIFY_N', " checked=\"checked\"");
+       case 'N':
+               define('__BONUS_EN_NOTIFY_Y', '');
+               define('__BONUS_EN_NOTIFY_N', ' chkecked="checked"');
                break;
        }
        switch (getConfig('bonus_di_notify'))
        {
-       case "Y":
-               define('__BONUS_DI_NOTIFY_Y', " checked=\"checked\"");
-               define('__BONUS_DI_NOTIFY_N', "");
+       case 'Y':
+               define('__BONUS_DI_NOTIFY_Y', ' chkecked="checked"');
+               define('__BONUS_DI_NOTIFY_N', '');
                break;
 
-       case "N":
-               define('__BONUS_DI_NOTIFY_Y', "");
-               define('__BONUS_DI_NOTIFY_N', " checked=\"checked\"");
+       case 'N':
+               define('__BONUS_DI_NOTIFY_Y', '');
+               define('__BONUS_DI_NOTIFY_N', ' chkecked="checked"');
                break;
        }
        switch (getConfig('bonus_new_mem_notify'))
        {
-       case "Y":
-               define('__BONUS_NEW_MEMBER_NOTIFY_Y', " checked=\"checked\"");
-               define('__BONUS_NEW_MEMBER_NOTIFY_N', "");
+       case 'Y':
+               define('__BONUS_NEW_MEMBER_NOTIFY_Y', ' chkecked="checked"');
+               define('__BONUS_NEW_MEMBER_NOTIFY_N', '');
                break;
 
-       case "N":
-               define('__BONUS_NEW_MEMBER_NOTIFY_Y', "");
-               define('__BONUS_NEW_MEMBER_NOTIFY_N', " checked=\"checked\"");
+       case 'N':
+               define('__BONUS_NEW_MEMBER_NOTIFY_Y', '');
+               define('__BONUS_NEW_MEMBER_NOTIFY_N', ' chkecked="checked"');
                break;
        }
        switch (getConfig('bonus_include_own'))
        {
-       case "Y":
-               define('__BONUS_INCLUDE_OWN_Y', " checked=\"checked\"");
-               define('__BONUS_INCLUDE_OWN_N', "");
+       case 'Y':
+               define('__BONUS_INCLUDE_OWN_Y', ' chkecked="checked"');
+               define('__BONUS_INCLUDE_OWN_N', '');
                break;
 
-       case "N":
-               define('__BONUS_INCLUDE_OWN_Y', "");
-               define('__BONUS_INCLUDE_OWN_N', " checked=\"checked\"");
+       case 'N':
+               define('__BONUS_INCLUDE_OWN_Y', '');
+               define('__BONUS_INCLUDE_OWN_N', ' chkecked="checked"');
                break;
        }
 
index 3ac70789d147b9e14b3739cd241cb9583970e70a..22fb95a0d78f6fb3e8b02145fc16444fde975129 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Cache path has been not changed by default so don't test it again
@@ -55,31 +55,31 @@ if (IS_FORM_SENT()) {
                REQUEST_SET_POST('cache_tested', "Y");
        }
 
-       if ((REQUEST_POST('cache_admins') == "N") && ($GLOBALS['cache_instance']->loadCacheFile("admins"))) {
+       if ((REQUEST_POST('cache_admins') == 'N') && ($GLOBALS['cache_instance']->loadCacheFile('admins'))) {
                $GLOBALS['cache_instance']->destroyCacheFile();
        }
 
-       if ((REQUEST_POST('cache_acls') == "N") && ($GLOBALS['cache_instance']->loadCacheFile("acls"))) {
+       if ((REQUEST_POST('cache_acls') == 'N') && ($GLOBALS['cache_instance']->loadCacheFile("acls"))) {
                $GLOBALS['cache_instance']->destroyCacheFile();
        }
 
-       if ((REQUEST_POST('cache_exts') == "N") && ($GLOBALS['cache_instance']->loadCacheFile("extensions", true))) {
+       if ((REQUEST_POST('cache_exts') == 'N') && ($GLOBALS['cache_instance']->loadCacheFile("extensions", true))) {
                $GLOBALS['cache_instance']->destroyCacheFile();
        }
 
-       if ((REQUEST_POST('cache_config') == "N") && ($GLOBALS['cache_instance']->loadCacheFile("config"))) {
+       if ((REQUEST_POST('cache_config') == 'N') && ($GLOBALS['cache_instance']->loadCacheFile("config"))) {
                $GLOBALS['cache_instance']->destroyCacheFile();
        }
 
-       if ((REQUEST_POST('cache_modreg') == "N") && ($GLOBALS['cache_instance']->loadCacheFile("modreg"))) {
+       if ((REQUEST_POST('cache_modreg') == 'N') && ($GLOBALS['cache_instance']->loadCacheFile("modreg"))) {
                $GLOBALS['cache_instance']->destroyCacheFile();
        }
 
-       if ((REQUEST_POST('cache_refdepth') == "N") && ($GLOBALS['cache_instance']->loadCacheFile("refdepth"))) {
+       if ((REQUEST_POST('cache_refdepth') == 'N') && ($GLOBALS['cache_instance']->loadCacheFile("refdepth"))) {
                $GLOBALS['cache_instance']->destroyCacheFile();
        }
 
-       if ((REQUEST_POST('cache_refsys') == "N") && ($GLOBALS['cache_instance']->loadCacheFile("refsys"))) {
+       if ((REQUEST_POST('cache_refsys') == 'N') && ($GLOBALS['cache_instance']->loadCacheFile("refsys"))) {
                $GLOBALS['cache_instance']->destroyCacheFile();
        }
 
@@ -88,110 +88,110 @@ if (IS_FORM_SENT()) {
 } else {
        // Prepare data
        switch (getConfig('cache_admins')) {
-               case "Y":
-                       define('__ADMINS_Y', " checked=\"checked\"");
-                       define('__ADMINS_N', "");
+               case 'Y':
+                       define('__ADMINS_Y', ' chkecked="checked"');
+                       define('__ADMINS_N', '');
                        break;
 
-               case "N":
-                       define('__ADMINS_Y', "");
-                       define('__ADMINS_N', " checked=\"checked\"");
+               case 'N':
+                       define('__ADMINS_Y', '');
+                       define('__ADMINS_N', ' chkecked="checked"');
                        break;
        }
 
        switch (getConfig('cache_acls')) {
-               case "Y":
-                       define('__ACLS_Y', " checked=\"checked\"");
-                       define('__ACLS_N', "");
+               case 'Y':
+                       define('__ACLS_Y', ' chkecked="checked"');
+                       define('__ACLS_N', '');
                        break;
 
-               case "N":
-                       define('__ACLS_Y', "");
-                       define('__ACLS_N', " checked=\"checked\"");
+               case 'N':
+                       define('__ACLS_Y', '');
+                       define('__ACLS_N', ' chkecked="checked"');
                        break;
        }
 
        switch (getConfig('cache_exts')) {
-               case "Y":
-                       define('__EXTS_Y', " checked=\"checked\"");
-                       define('__EXTS_N', "");
+               case 'Y':
+                       define('__EXTS_Y', ' chkecked="checked"');
+                       define('__EXTS_N', '');
                        break;
 
-               case "N":
-                       define('__EXTS_Y', "");
-                       define('__EXTS_N', " checked=\"checked\"");
+               case 'N':
+                       define('__EXTS_Y', '');
+                       define('__EXTS_N', ' chkecked="checked"');
                        break;
        }
 
        switch (getConfig('cache_config')) {
-               case "Y":
-                       define('__CONFIG_Y', " checked=\"checked\"");
-                       define('__CONFIG_N', "");
+               case 'Y':
+                       define('__CONFIG_Y', ' chkecked="checked"');
+                       define('__CONFIG_N', '');
                        break;
 
-               case "N":
-                       define('__CONFIG_Y', "");
-                       define('__CONFIG_N', " checked=\"checked\"");
+               case 'N':
+                       define('__CONFIG_Y', '');
+                       define('__CONFIG_N', ' chkecked="checked"');
                        break;
        }
 
        switch (getConfig('cache_modreg')) {
-               case "Y":
-                       define('__MODREG_Y', " checked=\"checked\"");
-                       define('__MODREG_N', "");
+               case 'Y':
+                       define('__MODREG_Y', ' chkecked="checked"');
+                       define('__MODREG_N', '');
                        break;
 
-               case "N":
-                       define('__MODREG_Y', "");
-                       define('__MODREG_N', " checked=\"checked\"");
+               case 'N':
+                       define('__MODREG_Y', '');
+                       define('__MODREG_N', ' chkecked="checked"');
                        break;
        }
 
        switch (getConfig('cache_refdepth')) {
-               case "Y":
-                       define('__REFDEPTH_Y', " checked=\"checked\"");
-                       define('__REFDEPTH_N', "");
+               case 'Y':
+                       define('__REFDEPTH_Y', ' chkecked="checked"');
+                       define('__REFDEPTH_N', '');
                        break;
 
-               case "N":
-                       define('__REFDEPTH_Y', "");
-                       define('__REFDEPTH_N', " checked=\"checked\"");
+               case 'N':
+                       define('__REFDEPTH_Y', '');
+                       define('__REFDEPTH_N', ' chkecked="checked"');
                        break;
        }
 
        switch (getConfig('cache_refsys')) {
-               case "Y":
-                       define('__REFSYS_Y', " checked=\"checked\"");
-                       define('__REFSYS_N', "");
+               case 'Y':
+                       define('__REFSYS_Y', ' chkecked="checked"');
+                       define('__REFSYS_N', '');
                        break;
 
-               case "N":
-                       define('__REFSYS_Y', "");
-                       define('__REFSYS_N', " checked=\"checked\"");
+               case 'N':
+                       define('__REFSYS_Y', '');
+                       define('__REFSYS_N', ' chkecked="checked"');
                        break;
        }
 
        switch (getConfig('cache_themes')) {
-               case "Y":
-                       define('__THEMES_Y', " checked=\"checked\"");
-                       define('__THEMES_N', "");
+               case 'Y':
+                       define('__THEMES_Y', ' chkecked="checked"');
+                       define('__THEMES_N', '');
                        break;
 
-               case "N":
-                       define('__THEMES_Y', "");
-                       define('__THEMES_N', " checked=\"checked\"");
+               case 'N':
+                       define('__THEMES_Y', '');
+                       define('__THEMES_N', ' chkecked="checked"');
                        break;
        }
 
        switch (getConfig('cache_admin_menu')) {
-               case "Y":
-                       define('__ADMIN_MENU_Y', " checked=\"checked\"");
-                       define('__ADMIN_MENU_N', "");
+               case 'Y':
+                       define('__ADMIN_MENU_Y', ' chkecked="checked"');
+                       define('__ADMIN_MENU_N', '');
                        break;
 
-               case "N":
-                       define('__ADMIN_MENU_Y', "");
-                       define('__ADMIN_MENU_N', " checked=\"checked\"");
+               case 'N':
+                       define('__ADMIN_MENU_Y', '');
+                       define('__ADMIN_MENU_N', ' chkecked="checked"');
                        break;
        }
 
index 1defd21c5dca05ee5b1e264ed6e0e83b05ec1556..7f11a7226b88250006e5feaa4ea9b3dc77303193 100644 (file)
@@ -44,10 +44,10 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Init variable to avoid a notice
-$CATS = "";
+$CATS = '';
 
 if (REQUEST_ISSET_POST(('add'))) {
        // Add a new category
@@ -67,10 +67,10 @@ if (REQUEST_ISSET_POST(('add'))) {
        SQL_FREERESULT($result);
 
        // Display message
-       LOAD_TEMPLATE("admin_settings_saved", false, $content);
+       LOAD_TEMPLATE('admin_settings_saved', false, $content);
 } elseif ((IS_FORM_SENT()) && (REQUEST_ISSET_POST(('id'))) && (is_array(REQUEST_POST('id')))) {
        // Change or delete categories...
-       $TEXT = "";
+       $TEXT = '';
        foreach (REQUEST_POST('id') as $id => $cat) {
                // Secure ID
                $id = bigintval($id);
@@ -106,11 +106,11 @@ if (REQUEST_ISSET_POST(('add'))) {
 
        if (isset($TEXT)) {
                // Display message
-               LOAD_TEMPLATE("admin_settings_saved", false, $TEXT);
+               LOAD_TEMPLATE('admin_settings_saved', false, $TEXT);
        }
 } elseif ((REQUEST_ISSET_POST('del')) && (SELECTION_COUNT(REQUEST_POST('sel')) > 0)) {
        // Delete categories
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('sel') as $id => $value) {
                // Load data of category
                $result = SQL_QUERY_ESC("SELECT cat FROM `{!_MYSQL_PREFIX!}_cats` WHERE id=%s LIMIT 1",
@@ -135,7 +135,7 @@ if (REQUEST_ISSET_POST(('add'))) {
        LOAD_TEMPLATE("admin_del_cats");
 } elseif ((REQUEST_ISSET_POST('edit')) && (SELECTION_COUNT(REQUEST_POST('sel')) > 0)) {
        // Edit categories
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('sel') as $id => $value)
        {
                // Load data from the category
@@ -163,13 +163,13 @@ if (REQUEST_ISSET_POST(('add'))) {
        LOAD_TEMPLATE("admin_edit_cats");
 } else {
        // Init variable here
-       $CATS = "";
+       $CATS = '';
 
        // Load all categories
        $result = SQL_QUERY("SELECT id, cat, visible, sort FROM `{!_MYSQL_PREFIX!}_cats` ORDER BY `sort`", __FILE__, __LINE__);
        if (SQL_NUMROWS($result) > 0) {
                // Init variables
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
 
                // List already existing categories for editing
                while ($content = SQL_FETCHARRAY($result)) {
index 5b12bfe31c73a18844e222bebbe7f209b9448126..c63c919315fbdf7f30a03ef588149d376e5b7e77 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Replace commata with decimal dot
@@ -75,28 +75,28 @@ if (IS_FORM_SENT()) {
        // Take points from jackpot (Y/N)
        switch (getConfig('doubler_jackpot'))
        {
-       case "Y":
-               define('__DOUBLER_JACKPOT_Y', " checked=\"checked\"");
-               define('__DOUBLER_JACKPOT_N', "");
+       case 'Y':
+               define('__DOUBLER_JACKPOT_Y', ' chkecked="checked"');
+               define('__DOUBLER_JACKPOT_N', '');
                break;
 
-       case "N":
-               define('__DOUBLER_JACKPOT_Y', "");
-               define('__DOUBLER_JACKPOT_N', " checked=\"checked\"");
+       case 'N':
+               define('__DOUBLER_JACKPOT_Y', '');
+               define('__DOUBLER_JACKPOT_N', ' chkecked="checked"');
                break;
        }
 
        // Take points from own account (Y/N)
        switch (getConfig('doubler_own'))
        {
-       case "Y":
-               define('__DOUBLER_OWN_Y', " checked=\"checked\"");
-               define('__DOUBLER_OWN_N', "");
+       case 'Y':
+               define('__DOUBLER_OWN_Y', ' chkecked="checked"');
+               define('__DOUBLER_OWN_N', '');
                break;
 
-       case "N":
-               define('__DOUBLER_OWN_Y', "");
-               define('__DOUBLER_OWN_N', " checked=\"checked\"");
+       case 'N':
+               define('__DOUBLER_OWN_Y', '');
+               define('__DOUBLER_OWN_N', ' chkecked="checked"');
                break;
        }
 
@@ -104,27 +104,27 @@ if (IS_FORM_SENT()) {
        switch (getConfig('doubler_send_mode'))
        {
        case "DIRECT":
-               define('__DOUBLER_SEND_DIRECT', " checked=\"checked\"");
-               define('__DOUBLER_SEND_RESET' , "");
+               define('__DOUBLER_SEND_DIRECT', ' chkecked="checked"');
+               define('__DOUBLER_SEND_RESET' , '');
                break;
 
        case "RESET":
-               define('__DOUBLER_SEND_DIRECT', "");
-               define('__DOUBLER_SEND_RESET' , " checked=\"checked\"");
+               define('__DOUBLER_SEND_DIRECT', '');
+               define('__DOUBLER_SEND_RESET' , ' chkecked="checked"');
                break;
        }
 
        // Take points from own account (Y/N)
        switch (getConfig('doubler_sent_all'))
        {
-       case "Y":
-               define('__DOUBLER_SENT_ALL_Y', " checked=\"checked\"");
-               define('__DOUBLER_SENT_ALL_N', "");
+       case 'Y':
+               define('__DOUBLER_SENT_ALL_Y', ' chkecked="checked"');
+               define('__DOUBLER_SENT_ALL_N', '');
                break;
 
-       case "N":
-               define('__DOUBLER_SENT_ALL_Y', "");
-               define('__DOUBLER_SENT_ALL_N', " checked=\"checked\"");
+       case 'N':
+               define('__DOUBLER_SENT_ALL_Y', '');
+               define('__DOUBLER_SENT_ALL_N', ' chkecked="checked"');
                break;
        }
 
index dfe8417c2f0bc8d41259f5cb00d1242d9bb69c38..95ab0b57ea55dcb2eab773725b9af0502afb16aa 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Remove empty array index
 if (!REQUEST_ISSET_POST(('max'))) REQUEST_UNSET_POST(('add_max'));
@@ -66,10 +66,10 @@ if (REQUEST_ISSET_POST(('add_max'))) {
        SQL_FREERESULT($result);
 
        // Display message
-       LOAD_TEMPLATE("admin_settings_saved", false, $content);
+       LOAD_TEMPLATE('admin_settings_saved', false, $content);
 } elseif ((IS_FORM_SENT()) && (REQUEST_ISSET_GET('do'))) {
        // Change or delete entries...
-       $TEXT = "";
+       $TEXT = '';
        foreach (REQUEST_POST('id') as $id => $value) {
                // Secure ID
                $id = bigintval($id);
@@ -96,11 +96,11 @@ if (REQUEST_ISSET_POST(('add_max'))) {
 
        if (isset($TEXT)) {
                // Display message
-               LOAD_TEMPLATE("admin_settings_saved", false, $TEXT);
+               LOAD_TEMPLATE('admin_settings_saved', false, $TEXT);
        }
 } elseif ((REQUEST_ISSET_POST('del')) && (SELECTION_COUNT(REQUEST_POST('sel')) > 0)) {
        // Delete entries
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('sel') as $id => $value)
        {
                // Load data
@@ -127,7 +127,7 @@ if (REQUEST_ISSET_POST(('add_max'))) {
        LOAD_TEMPLATE("admin_config_email_del");
 } elseif ((REQUEST_ISSET_POST('edit')) && (SELECTION_COUNT(REQUEST_POST('sel')) > 0)) {
        // Edit entries
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('sel') as $id => $value) {
                // Load data
                $result = SQL_QUERY_ESC("SELECT value, comment FROM `{!_MYSQL_PREFIX!}_max_receive` WHERE id=%s LIMIT 1",
@@ -156,7 +156,7 @@ if (REQUEST_ISSET_POST(('add_max'))) {
                __FILE__, __LINE__);
        if (SQL_NUMROWS($result) > 0) {
                // List already existing entries for editing
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Prepare data for the row template
                        $content['sw'] = $SW;
index 18f8278ff134b439b696b5f8b9a0d1e30febdcdb..e57f7b82edf035cf35e8e03bf630a4b48454525c 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save configuration
@@ -51,14 +51,14 @@ if (IS_FORM_SENT()) {
 } else {
        // Prepare data
        switch (getConfig('verbose_sql')) {
-               case "Y":
-                       define('__VERBOSE_Y', " checked=\"checked\"");
-                       define('__VERBOSE_N', "");
+               case 'Y':
+                       define('__VERBOSE_Y', ' chkecked="checked"');
+                       define('__VERBOSE_N', '');
                        break;
 
-               case "N":
-                       define('__VERBOSE_Y', "");
-                       define('__VERBOSE_N', " checked=\"checked\"");
+               case 'N':
+                       define('__VERBOSE_Y', '');
+                       define('__VERBOSE_N', ' chkecked="checked"');
                        break;
        }
 
index 2f3f43d0c62fd095e94841bf3ba31c357caad115..e45b6af68540d7f4a26c3a7844cc5f8a5f9f11e5 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT())
 {
@@ -58,13 +58,13 @@ if (IS_FORM_SENT())
 
        switch (getConfig('holiday_mode')) {
        case "RESET":
-               define('__RESET_DEFAULT' , " checked=\"checked\"");
-               define('__DIRECT_DEFAULT', "");
+               define('__RESET_DEFAULT' , ' chkecked="checked"');
+               define('__DIRECT_DEFAULT', '');
                break;
 
        case "DIRECT":
-               define('__RESET_DEFAULT' , "");
-               define('__DIRECT_DEFAULT', " checked=\"checked\"");
+               define('__RESET_DEFAULT' , '');
+               define('__DIRECT_DEFAULT', ' chkecked="checked"');
                break;
        }
 
index 968bcdb2b4f1105520bbd329db0429304d5e8f25..36e63c71b516eb34965375d4a022ba0b936c2e84 100644 (file)
@@ -43,11 +43,11 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
-// Init "sub" value
-$sub = "";
-if (REQUEST_ISSET_GET(('sub'))) $sub = REQUEST_GET('sub');
+// Init 'sub' value
+$sub = '';
+if (REQUEST_ISSET_GET('sub')) $sub = REQUEST_GET('sub');
 
 switch ($sub)
 {
@@ -58,7 +58,7 @@ case "settings": // Settings related to the index page
                OUTPUT_HTML("<a href=\"{!URL!}/modules.php?module=admin&amp;what=config_home&amp;sub=settings\">{--ADMIN_CONTINUE_TO_CONFIG--}</a>");
        } else {
                // Prepare data for the template
-               $content = array_fill(-1, 60, "");
+               $content = array_fill(-1, 60, '');
                $content[getConfig('index_delay')] = " selected=\"selected\"";
 
                define('__INDEX_COOKIE_SELECTION', CREATE_TIME_SELECTIONS(getConfig('index_cookie'), "index_cookie", "YMWD"));
@@ -80,7 +80,7 @@ ORDER BY `sort` ASC", __FILE__, __LINE__);
 
        // Init variables
        $SW = 2;
-       $OUT = "";
+       $OUT = '';
 
        // Process all entries
        while ($content = SQL_FETCHARRAY($result)) {
index 785ab2c30effe1cc4c7f25a93c1d80fe9086264d..a6656538d31de1c38f15909e1961e061bdd385d0 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Test timestamp
@@ -63,7 +63,7 @@ if (IS_FORM_SENT()) {
 
        // Convert some data
        REQUEST_SET_POST('mt_stage', bigintval(REQUEST_POST('mt_stage')));
-       if (REQUEST_POST('mt_stage') <= GET_TOTAL_DATA("CONFIRMED", "user_data", "userid", "status", true)) {
+       if (REQUEST_POST('mt_stage') <= GET_TOTAL_DATA("CONFIRMED", "user_data", 'userid', "status", true)) {
                // Not enougth!
                REQUEST_UNSET_POST('ok');
        }
index 8d6846e117b3bb8b01248f89ec3b944603b92838..bf26f1d6f93b74ee3f992178fb752172348462b5 100644 (file)
 
 // Some security stuff...
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 $SEL = 0;
 if (REQUEST_ISSET_POST('edit')) {
@@ -51,7 +51,7 @@ if (REQUEST_ISSET_POST('edit')) {
        $SEL = SELECTION_COUNT(REQUEST_POST('sel'));
        if ($SEL > 0) {
                // Output header
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
 
                // Edit selected modules
                foreach (REQUEST_POST('sel') as $id => $sel) {
@@ -67,22 +67,22 @@ if (REQUEST_ISSET_POST('edit')) {
                                'mod'    => $mod,
                                'id'     => $id,
                                'title'  => $title,
-                               'locked' => ADD_SELECTION("yn", $locked, "locked", $id),
-                               'hidden' => ADD_SELECTION("yn", $hidden, "hidden", $id),
-                               'admin'  => ADD_SELECTION("yn", $admin , "admin" , $id),
-                               'mem'    => ADD_SELECTION("yn", $mem   , "member", $id),
+                               'locked' => ADD_SELECTION('yn', $locked, 'locked', $id),
+                               'hidden' => ADD_SELECTION('yn', $hidden, 'hidden', $id),
+                               'admin'  => ADD_SELECTION('yn', $admin , 'admin' , $id),
+                               'mem'    => ADD_SELECTION('yn', $mem   , 'member', $id),
                        );
 
                        // Load row template
-                       $OUT .= LOAD_TEMPLATE("admin_mods_edit_row", true, $content);
+                       $OUT .= LOAD_TEMPLATE('admin_mods_edit_row', true, $content);
                }
                define('__MODS_ROWS', $OUT);
 
                // Load main template
-               LOAD_TEMPLATE("admin_mods_edit");
+               LOAD_TEMPLATE('admin_mods_edit');
        } else {
                // Nothing selected
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MODS_NOTHING_SELECTED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MODS_NOTHING_SELECTED'));
 
                // Remove maybe confusing data
                REQUEST_UNSET_POST('edit');
@@ -98,7 +98,7 @@ if (REQUEST_ISSET_POST('edit')) {
                $id = bigintval($id);
 
                // Update module
-               ADD_SQL(SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `title`='%s', `locked`='%s', hidden='%s', admin_only='%s', mem_only='%s' WHERE id=%s LIMIT 1",
+               ADD_SQL(SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `title`='%s', `locked`='%s', `hidden`='%s', `admin_only`='%s', `mem_only`='%s' WHERE id=%s LIMIT 1",
                        array(
                                REQUEST_POST('title', $id),
                                REQUEST_POST('locked', $id),
@@ -113,24 +113,24 @@ if (REQUEST_ISSET_POST('edit')) {
        runFilterChain('run_sqls');
 
        // Remove cache file if version matches
-       if (GET_EXT_VERSION("cache") >= "0.1.2") {
-               if ($GLOBALS['cache_instance']->loadCacheFile("modreg")) $GLOBALS['cache_instance']->destroyCacheFile();
+       if (GET_EXT_VERSION('cache') >= '0.1.2') {
+               if ($GLOBALS['cache_instance']->loadCacheFile('modreg')) $GLOBALS['cache_instance']->destroyCacheFile();
        } // END - if
 
        // Entries updated
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MODS_CHANGED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MODS_CHANGED'));
 }
 
 if ($SEL == 0) {
        // Load module data (We do not need to check if there's at least one...)
-       $result = SQL_QUERY("SELECT id, module, locked, hidden, admin_only, title, mem_only
+       $result = SQL_QUERY('SELECT id, module, locked, hidden, admin_only, title, mem_only
 FROM `{!_MYSQL_PREFIX!}_mod_reg`
-ORDER BY module", __FILE__, __LINE__);
-       $OUT = ""; $SW = 2;
+ORDER BY module', __FILE__, __LINE__);
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Reset title to --- if it is NULL
-               if (empty($content['title'])) $content['title'] = "---";
-               if (($content['module'] == "index") || ($content['module'] == "login")) {
+               if (empty($content['title'])) $content['title'] = '---';
+               if (($content['module'] == 'index') || ($content['module'] == 'login')) {
                        // Add link to detail statistics
                        $content['module'] = "<strong><a href=\"{!URL!}/modules.php?module=admin&amp;what=stats_mods&amp;mod=".$content['module']."\">".$content['module']."</a></strong>";
                }
@@ -149,7 +149,7 @@ ORDER BY module", __FILE__, __LINE__);
                );
 
                // Load row template
-               $OUT .= LOAD_TEMPLATE("admin_mods_list_row", true, $content);
+               $OUT .= LOAD_TEMPLATE('admin_mods_list_row', true, $content);
 
                // Switch colors
                $SW = 3 - $SW;
@@ -162,7 +162,7 @@ ORDER BY module", __FILE__, __LINE__);
        define('__MODS_ROWS', $OUT);
 
        // Load main template
-       LOAD_TEMPLATE("admin_mods_list");
+       LOAD_TEMPLATE('admin_mods_list');
 }
 
 //
index 93750a853c7e53b8cab5142e5f62fa0fc0608742..5a9f5a11c2bb6df9518b4e57932196d735243ce9 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save data
index 54105cd7730ff1fb70ca99b86ac4a58d0d04352a..70c4407e24587c4b9f90bd2cba5bccb5751a23b5 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save data
index 8cf8486eaa505fb4c29235c4fd652e275433d9bb..1efa069938bed44b1f5f6d35b7a759e783c9c896 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save data
@@ -52,14 +52,14 @@ if (IS_FORM_SENT()) {
        // Prepare constants for the template
        switch (getConfig('order_max_full'))
        {
-       case "ORDER":
-               define('__ORDER_DEFAULT', " checked=\"checked\"");
-               define('__MAX_DEFAULT'  , "");
+       case 'ORDER':
+               define('__ORDER_DEFAULT', ' chkecked="checked"');
+               define('__MAX_DEFAULT'  , '');
                break;
 
-       case "MAX":
-               define('__ORDER_DEFAULT', "");
-               define('__MAX_DEFAULT'  , " checked=\"checked\"");
+       case 'MAX':
+               define('__ORDER_DEFAULT', '');
+               define('__MAX_DEFAULT'  , ' chkecked="checked"');
                break;
        }
 
@@ -71,11 +71,11 @@ if (IS_FORM_SENT()) {
        {
        case "ASC":
                define('__ASC_DEFAULT' , " selected=\"selected\"");
-               define('__DESC_DEFAULT', "");
+               define('__DESC_DEFAULT', '');
                break;
 
        case "DESC":
-               define('__ASC_DEFAULT' , "");
+               define('__ASC_DEFAULT' , '');
                define('__DESC_DEFAULT', " selected=\"selected\"");
                break;
        }
@@ -85,47 +85,47 @@ if (IS_FORM_SENT()) {
        define('_CFG_MAX_TLENGTH'   , getConfig('max_tlength'));
 
        if (getConfig('test_text') != "Y") {
-               define('_CFG_TEST_TEXT_N', " checked=\"checked\"");
-               define('_CFG_TEST_TEXT_Y', "");
+               define('_CFG_TEST_TEXT_N', ' chkecked="checked"');
+               define('_CFG_TEST_TEXT_Y', '');
        } else {
-               define('_CFG_TEST_TEXT_N', "");
-               define('_CFG_TEST_TEXT_Y', " checked=\"checked\"");
+               define('_CFG_TEST_TEXT_N', '');
+               define('_CFG_TEST_TEXT_Y', ' chkecked="checked"');
        }
 
        switch (getConfig('repay_deleted_mails')) {
                case "REPAY":
                        define('_CFG_REPAY_POINTS_REPAY'  , " selected=\"selected\"");
-                       define('_CFG_REPAY_POINTS_JACKPOT', "");
-                       define('_CFG_REPAY_POINTS_SHRED'  , "");
+                       define('_CFG_REPAY_POINTS_JACKPOT', '');
+                       define('_CFG_REPAY_POINTS_SHRED'  , '');
                        break;
 
                case "JACKPOT":
-                       define('_CFG_REPAY_POINTS_REPAY'  , "");
+                       define('_CFG_REPAY_POINTS_REPAY'  , '');
                        define('_CFG_REPAY_POINTS_JACKPOT', " selected=\"selected\"");
-                       define('_CFG_REPAY_POINTS_SHRED'  , "");
+                       define('_CFG_REPAY_POINTS_SHRED'  , '');
                        break;
 
                case "SHRED":
-                       define('_CFG_REPAY_POINTS_REPAY'  , "");
-                       define('_CFG_REPAY_POINTS_JACKPOT', "");
+                       define('_CFG_REPAY_POINTS_REPAY'  , '');
+                       define('_CFG_REPAY_POINTS_JACKPOT', '');
                        define('_CFG_REPAY_POINTS_SHRED'  , " selected=\"selected\"");
                        break;
        }
 
        if (getConfig('test_subj') != "Y") {
-               define('_CFG_TEST_SUBJ_N', " checked=\"checked\"");
-               define('_CFG_TEST_SUBJ_Y', "");
+               define('_CFG_TEST_SUBJ_N', ' chkecked="checked"');
+               define('_CFG_TEST_SUBJ_Y', '');
        } else {
-               define('_CFG_TEST_SUBJ_N', "");
-               define('_CFG_TEST_SUBJ_Y', " checked=\"checked\"");
+               define('_CFG_TEST_SUBJ_N', '');
+               define('_CFG_TEST_SUBJ_Y', ' chkecked="checked"');
        }
 
        if (getConfig('url_blacklist') != "Y") {
-               define('_CFG_URL_BLIST_N', " checked=\"checked\"");
-               define('_CFG_URL_BLIST_Y', "");
+               define('_CFG_URL_BLIST_N', ' chkecked="checked"');
+               define('_CFG_URL_BLIST_Y', '');
        } else {
-               define('_CFG_URL_BLIST_N', "");
-               define('_CFG_URL_BLIST_Y', " checked=\"checked\"");
+               define('_CFG_URL_BLIST_N', '');
+               define('_CFG_URL_BLIST_Y', ' chkecked="checked"');
        }
 
        // Selection list
index a524a55df0b473ec958dd581029a7c13c55692aa..a782adfec67f382e41e4898cceb9c59f329492f4 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("other")) {
+} elseif (!EXT_IS_ACTIVE('other')) {
        // Missing extension!
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "other");
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'other');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Stop saving data if one input field is !isset
 if (IS_FORM_SENT()) {
        // Calculate stamps and set calculated stamps
-       REQUEST_POST('online_timeout')        = CREATE_TIMESTAMP_FROM_SELECTIONS("ip_timeout"           , REQUEST_POST_ARRAY());
-       REQUEST_POST('url_tlock')             = CREATE_TIMESTAMP_FROM_SELECTIONS("url_tlock"            , REQUEST_POST_ARRAY());
-       REQUEST_POST('profile_lock')          = CREATE_TIMESTAMP_FROM_SELECTIONS("profile_lock"         , REQUEST_POST_ARRAY());
-       REQUEST_POST('profile_update')        = CREATE_TIMESTAMP_FROM_SELECTIONS("profile_update"       , REQUEST_POST_ARRAY());
-       REQUEST_SET_POST('resend_profile_update', CREATE_TIMESTAMP_FROM_SELECTIONS("resend_profile_update", REQUEST_POST_ARRAY()));
+       REQUEST_POST('online_timeout')        = CREATE_TIMESTAMP_FROM_SELECTIONS('ip_timeout'           , REQUEST_POST_ARRAY());
+       REQUEST_POST('url_tlock')             = CREATE_TIMESTAMP_FROM_SELECTIONS('url_tlock'            , REQUEST_POST_ARRAY());
+       REQUEST_POST('profile_lock')          = CREATE_TIMESTAMP_FROM_SELECTIONS('profile_lock'         , REQUEST_POST_ARRAY());
+       REQUEST_POST('profile_update')        = CREATE_TIMESTAMP_FROM_SELECTIONS('profile_update'       , REQUEST_POST_ARRAY());
+       REQUEST_SET_POST('resend_profile_update', CREATE_TIMESTAMP_FROM_SELECTIONS('resend_profile_update', REQUEST_POST_ARRAY()));
 
        // Online-Timeout shall be > 0 or your database will crow and crow and crow...
        if (!REQUEST_ISSET_POST(('online_timeout')))        { REQUEST_UNSET_POST('ok'); }
@@ -85,98 +85,98 @@ if (IS_FORM_SENT()) {
        define('_CFG_MIN_AGE'    , getConfig('min_age'));
 
        // Time selection boxes
-       define('_CFG_ONLINE_TIMEOUT', CREATE_TIME_SELECTIONS(getConfig('online_timeout'), "ip_timeout"           , "ms"));
-       define('_CFG_URL_TLOCK'     , CREATE_TIME_SELECTIONS(getConfig('url_tlock')     , "url_tlock"            , "WDh"));
-       define('_CFG_PROFILE_LOCK'  , CREATE_TIME_SELECTIONS(getConfig('profile_lock')  , "profile_lock"         , "WDh"));
-       define('_CFG_PROFILE_UPDATE', CREATE_TIME_SELECTIONS(getConfig('profile_update'), "profile_update"       , "YM"));
-       define('_CFG_PROF_REUPDATE' , CREATE_TIME_SELECTIONS(getConfig('resend_profile_update') , "resend_profile_update", "MWD"));
-
-       if (getConfig('order_multi_page') != "Y") {
-               define('_CFG_ORDER_MULTI_N', " checked=\"checked\"");
-               define('_CFG_ORDER_MULTI_Y', "");
+       define('_CFG_ONLINE_TIMEOUT', CREATE_TIME_SELECTIONS(getConfig('online_timeout'), 'ip_timeout'           , 'ms'));
+       define('_CFG_URL_TLOCK'     , CREATE_TIME_SELECTIONS(getConfig('url_tlock')     , 'url_tlock'            , 'WDh'));
+       define('_CFG_PROFILE_LOCK'  , CREATE_TIME_SELECTIONS(getConfig('profile_lock')  , 'profile_lock'         , 'WDh'));
+       define('_CFG_PROFILE_UPDATE', CREATE_TIME_SELECTIONS(getConfig('profile_update'), 'profile_update'       , 'YM'));
+       define('_CFG_PROF_REUPDATE' , CREATE_TIME_SELECTIONS(getConfig('resend_profile_update') , 'resend_profile_update', 'MWD'));
+
+       if (getConfig('order_multi_page') != 'Y') {
+               define('_CFG_ORDER_MULTI_N', ' chkecked="checked"');
+               define('_CFG_ORDER_MULTI_Y', '');
        } else {
-               define('_CFG_ORDER_MULTI_N', "");
-               define('_CFG_ORDER_MULTI_Y', " checked=\"checked\"");
+               define('_CFG_ORDER_MULTI_N', '');
+               define('_CFG_ORDER_MULTI_Y', ' chkecked="checked"');
        }
 
        if (getConfig('autosend_active') != "Y") {
-               define('_CFG_AUTOSEND_ACTIVE_N', " checked=\"checked\"");
-               define('_CFG_AUTOSEND_ACTIVE_Y', "");
+               define('_CFG_AUTOSEND_ACTIVE_N', ' chkecked="checked"');
+               define('_CFG_AUTOSEND_ACTIVE_Y', '');
        } else {
-               define('_CFG_AUTOSEND_ACTIVE_N', "");
-               define('_CFG_AUTOSEND_ACTIVE_Y', " checked=\"checked\"");
+               define('_CFG_AUTOSEND_ACTIVE_N', '');
+               define('_CFG_AUTOSEND_ACTIVE_Y', ' chkecked="checked"');
        }
 
        if (getConfig('send_prof_update') != "Y") {
-               define('_CFG_SEND_UPDATE_N', " checked=\"checked\"");
-               define('_CFG_SEND_UPDATE_Y', "");
+               define('_CFG_SEND_UPDATE_N', ' chkecked="checked"');
+               define('_CFG_SEND_UPDATE_Y', '');
        } else {
-               define('_CFG_SEND_UPDATE_N', "");
-               define('_CFG_SEND_UPDATE_Y', " checked=\"checked\"");
+               define('_CFG_SEND_UPDATE_N', '');
+               define('_CFG_SEND_UPDATE_Y', ' chkecked="checked"');
        }
 
        if (getConfig('admin_notify') != "Y") {
-               define('_CFG_ADMIN_NOTIFY_N', " checked=\"checked\"");
-               define('_CFG_ADMIN_NOTIFY_Y', "");
+               define('_CFG_ADMIN_NOTIFY_N', ' chkecked="checked"');
+               define('_CFG_ADMIN_NOTIFY_Y', '');
        } else {
-               define('_CFG_ADMIN_NOTIFY_N', "");
-               define('_CFG_ADMIN_NOTIFY_Y', " checked=\"checked\"");
+               define('_CFG_ADMIN_NOTIFY_N', '');
+               define('_CFG_ADMIN_NOTIFY_Y', ' chkecked="checked"');
        }
 
        if (getConfig('css_php') == "DIRECT") {
-               define('_CFG_CSS_PHP_DIRECT', " checked=\"checked\"");
-               define('_CFG_CSS_PHP_FILE', "");
+               define('_CFG_CSS_PHP_DIRECT', ' chkecked="checked"');
+               define('_CFG_CSS_PHP_FILE', '');
        } else {
-               define('_CFG_CSS_PHP_DIRECT', "");
-               define('_CFG_CSS_PHP_FILE', " checked=\"checked\"");
+               define('_CFG_CSS_PHP_DIRECT', '');
+               define('_CFG_CSS_PHP_FILE', ' chkecked="checked"');
        }
 
-       if (getConfig('guest_menu') == "Y") {
-               define('_CFG_GUEST_MENU_ACTIVE', " checked=\"checked\"");
-               define('_CFG_GUEST_MENU_INACTIVE', "");
+       if (getConfig('guest_menu') == 'Y') {
+               define('_CFG_GUEST_MENU_ACTIVE', ' chkecked="checked"');
+               define('_CFG_GUEST_MENU_INACTIVE', '');
        } else {
-               define('_CFG_GUEST_MENU_ACTIVE', "");
-               define('_CFG_GUEST_MENU_INACTIVE', " checked=\"checked\"");
+               define('_CFG_GUEST_MENU_ACTIVE', '');
+               define('_CFG_GUEST_MENU_INACTIVE', ' chkecked="checked"');
        }
 
-       if (getConfig('member_menu') == "Y") {
-               define('_CFG_MEMBER_MENU_ACTIVE', " checked=\"checked\"");
-               define('_CFG_MEMBER_MENU_INACTIVE', "");
+       if (getConfig('member_menu') == 'Y') {
+               define('_CFG_MEMBER_MENU_ACTIVE', ' chkecked="checked"');
+               define('_CFG_MEMBER_MENU_INACTIVE', '');
        } else {
-               define('_CFG_MEMBER_MENU_ACTIVE', "");
-               define('_CFG_MEMBER_MENU_INACTIVE', " checked=\"checked\"");
+               define('_CFG_MEMBER_MENU_ACTIVE', '');
+               define('_CFG_MEMBER_MENU_INACTIVE', ' chkecked="checked"');
        }
 
-       if (getConfig('youre_here') == "Y") {
-               define('_CFG_YOURE_HERE_ACTIVE', " checked=\"checked\"");
-               define('_CFG_YOURE_HERE_INACTIVE', "");
+       if (getConfig('youre_here') == 'Y') {
+               define('_CFG_YOURE_HERE_ACTIVE', ' chkecked="checked"');
+               define('_CFG_YOURE_HERE_INACTIVE', '');
        } else {
-               define('_CFG_YOURE_HERE_ACTIVE', "");
-               define('_CFG_YOURE_HERE_INACTIVE', " checked=\"checked\"");
+               define('_CFG_YOURE_HERE_ACTIVE', '');
+               define('_CFG_YOURE_HERE_INACTIVE', ' chkecked="checked"');
        }
 
-       if (getConfig('show_timings') == "Y") {
-               define('_CFG_SHOW_TIMINGS_Y', " checked=\"checked\"");
-               define('_CFG_SHOW_TIMINGS_N', "");
+       if (getConfig('show_timings') == 'Y') {
+               define('_CFG_SHOW_TIMINGS_Y', ' chkecked="checked"');
+               define('_CFG_SHOW_TIMINGS_N', '');
        } else {
-               define('_CFG_SHOW_TIMINGS_Y', "");
-               define('_CFG_SHOW_TIMINGS_N', " checked=\"checked\"");
+               define('_CFG_SHOW_TIMINGS_Y', '');
+               define('_CFG_SHOW_TIMINGS_N', ' chkecked="checked"');
        }
 
-       if (getConfig('show_points_unconfirmed') == "Y") {
-               define('_CFG_SHOW_POINTS_UNCONFIRMED_Y', " checked=\"checked\"");
-               define('_CFG_SHOW_POINTS_UNCONFIRMED_N', "");
+       if (getConfig('show_points_unconfirmed') == 'Y') {
+               define('_CFG_SHOW_POINTS_UNCONFIRMED_Y', ' chkecked="checked"');
+               define('_CFG_SHOW_POINTS_UNCONFIRMED_N', '');
        } else {
-               define('_CFG_SHOW_POINTS_UNCONFIRMED_Y', "");
-               define('_CFG_SHOW_POINTS_UNCONFIRMED_N', " checked=\"checked\"");
+               define('_CFG_SHOW_POINTS_UNCONFIRMED_Y', '');
+               define('_CFG_SHOW_POINTS_UNCONFIRMED_N', ' chkecked="checked"');
        }
 
        if (getConfig('mailid_error_redirect') == 'INDEX') {
-               define('_CFG_MAILID_REDIRECT_INDEX', " checked=\"checked\"");
-               define('_CFG_MAILID_REDIRECT_REJECT', "");
+               define('_CFG_MAILID_REDIRECT_INDEX', ' chkecked="checked"');
+               define('_CFG_MAILID_REDIRECT_REJECT', '');
        } else {
-               define('_CFG_MAILID_REDIRECT_INDEX', "");
-               define('_CFG_MAILID_REDIRECT_REJECT', " checked=\"checked\"");
+               define('_CFG_MAILID_REDIRECT_INDEX', '');
+               define('_CFG_MAILID_REDIRECT_REJECT', ' chkecked="checked"');
        }
 
        for ($i = 0; $i <= 5; $i++) {
index 4ab60ecce6f15350657e39e7612fb4a6da9ab676..337f76dbf7f24a908ee21c884a02551b99d495da 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (REQUEST_ISSET_POST(('rate'))) REQUEST_SET_POST('rate', REVERT_COMMA(REQUEST_POST('rate')));
 
@@ -118,7 +118,7 @@ WHERE id='".$id."' LIMIT 1",
                $msg = getMessage('ADMIN_PAYOUT_ENTRIES_CHANGED');
        } else {
                $display = false; //Suppress any other outputs
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                foreach (REQUEST_POST('sel') as $id => $sel) {
                        // Load data
                        $result = SQL_QUERY_ESC("SELECT type, rate, min_points, allow_url FROM `{!_MYSQL_PREFIX!}_payout_types` WHERE id=%s LIMIT 1",
@@ -166,7 +166,7 @@ WHERE id='".$id."' LIMIT 1",
                $msg = getMessage('ADMIN_PAYOUT_ENTRIES_DELETED');
        } else {
                $display = false; //Suppress any other outputs
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                foreach (REQUEST_POST('sel') as $id => $sel) {
                        // Secure ID number
                        $id = bigintval($id);
@@ -199,7 +199,7 @@ WHERE id='".$id."' LIMIT 1",
 
 if (!empty($msg)) {
        // Output message
-       LOAD_TEMPLATE("admin_settings_saved", false, $msg);
+       LOAD_TEMPLATE('admin_settings_saved', false, $msg);
 }
 
 // Payout types
@@ -207,7 +207,7 @@ $result_type = SQL_QUERY("SELECT id, type, rate, min_points, from_account FROM `
 
 if ((SQL_NUMROWS($result_type) > 0) && ($display)) {
        // List all payout types
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result_type)) {
                // Prepare data for the row template
                $content = array(
@@ -237,10 +237,10 @@ if ((SQL_NUMROWS($result_type) > 0) && ($display)) {
 // Does your members request payouts?
 if ((SQL_NUMROWS($result_mem) > 0) && ($display)) {
        // Members has requested payouts
-       LOAD_TEMPLATE("admin_settings_saved", false, "<a href=\"{!URL!}/modules.php?module=admin&amp;what=list_payouts\">{--ADMIN_PAYOUT_LIST_REQUESTS--}</a></P>");
+       LOAD_TEMPLATE('admin_settings_saved', false, "<a href=\"{!URL!}/modules.php?module=admin&amp;what=list_payouts\">{--ADMIN_PAYOUT_LIST_REQUESTS--}</a></P>");
 } elseif ($display) {
        // No member requests so far
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_PAYOUT_NO_MEMBER_REQUESTS'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_PAYOUT_NO_MEMBER_REQUESTS'));
 }
 
 // Free result
index a29c1790a9a6cf97c3fddb234fd146f92460e1a6..f6fa31bbfa8ec9f7bf1e45c1b6387c47b5fa9926 100644 (file)
@@ -43,13 +43,13 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Init variables
-$message = "";
+$message = '';
 
 // Is the 'sub' parameter set?
-if (REQUEST_ISSET_GET(('sub'))) {
+if (REQUEST_ISSET_GET('sub')) {
        // Yes, then do some sanity-checks
        switch (REQUEST_GET('sub'))
        {
@@ -61,7 +61,7 @@ if (REQUEST_ISSET_GET(('sub'))) {
 
        case "ref":
                if (REQUEST_ISSET_GET('do')) {
-                       if (((!REQUEST_ISSET_POST(('lvl'))) || (!REQUEST_ISSET_POST(('perc')))) && (REQUEST_GET('do') == "add")) {
+                       if (((!REQUEST_ISSET_POST(('lvl'))) || (!REQUEST_ISSET_POST(('perc')))) && (REQUEST_GET('do') == 'add')) {
                                REQUEST_UNSET_POST('ok');
                        }
                }
@@ -83,7 +83,7 @@ if (IS_FORM_SENT()) {
        case "ref":
                switch (REQUEST_GET('do'))
                {
-               case "add":
+               case 'add':
                        ADD_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_refdepths` (level, percents) VALUES ('".REQUEST_POST('lvl')."','".REQUEST_POST('perc')."')");
                        break;
 
@@ -112,7 +112,7 @@ if (IS_FORM_SENT()) {
                }
 
                // Update cache file
-               if (GET_EXT_VERSION("cache") >= "0.1.2") {
+               if (GET_EXT_VERSION('cache') >= '0.1.2') {
                        if ($GLOBALS['cache_instance']->loadCacheFile("refdepths")) $GLOBALS['cache_instance']->destroyCacheFile();
                }
                break;
@@ -169,27 +169,27 @@ WHERE mails_confirmed < %s", $REF, $REF));
        // Shall we display a message?
        if (!empty($message)) {
                // When do so...
-               LOAD_TEMPLATE("admin_settings_saved", false, $message);
+               LOAD_TEMPLATE('admin_settings_saved', false, $message);
        }
 } elseif (REQUEST_GET('sub') == "settings") {
        // Setup some settings like direct pay and so on
        // Including new add-mode for one-time referal bonus
        switch (getConfig('allow_direct_pay')) {
-       case "Y":
-               define('__DIRECT_Y', " checked=\"checked\"");
-               define('__DIRECT_N', "");
+       case 'Y':
+               define('__DIRECT_Y', ' chkecked="checked"');
+               define('__DIRECT_N', '');
                break;
 
-       case "N":
-               define('__DIRECT_Y', "");
-               define('__DIRECT_N', " checked=\"checked\"");
+       case 'N':
+               define('__DIRECT_Y', '');
+               define('__DIRECT_N', ' chkecked="checked"');
                break;
        }
 
        // One-time referal bonus add-mode
        switch (getConfig('reg_points_mode')) {
-               case "ref"   : define('__MODE_REF', " checked=\"checked\""); define('__MODE_DIRECT', "");         break;
-               case "direct": define('__MODE_REF', "");         define('__MODE_DIRECT', " checked=\"checked\""); break;
+               case "ref"   : define('__MODE_REF', ' chkecked="checked"'); define('__MODE_DIRECT', '');         break;
+               case "direct": define('__MODE_REF', '');         define('__MODE_DIRECT', ' chkecked="checked"'); break;
        }
 
        // Referal payout value
@@ -201,7 +201,7 @@ WHERE mails_confirmed < %s", $REF, $REF));
        // 12                  3     32    2                  3     32    2               3            4     43    21
        if ((REQUEST_ISSET_POST('del')) && (REQUEST_ISSET_POST('sel')) && (SELECTION_COUNT(REQUEST_POST('sel')) > 0)) {
                // Delete entries
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                foreach (REQUEST_POST('sel') as $id => $value) {
                        $result = SQL_QUERY_ESC("SELECT level, percents FROM `{!_MYSQL_PREFIX!}_refdepths` WHERE id=%s LIMIT 1",
                                array(bigintval($id)), __FILE__, __LINE__);
@@ -226,7 +226,7 @@ WHERE mails_confirmed < %s", $REF, $REF));
                LOAD_TEMPLATE("admin_points_del");
        } elseif ((REQUEST_ISSET_POST('edit')) && (REQUEST_ISSET_POST('sel')) && (SELECTION_COUNT(REQUEST_POST('sel')) > 0)) {
                // Edit entries
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                foreach (REQUEST_POST('sel') as $id => $value) {
                        $result = SQL_QUERY_ESC("SELECT level, percents FROM `{!_MYSQL_PREFIX!}_refdepths` WHERE id=%s LIMIT 1",
                         array(bigintval($id)), __FILE__, __LINE__);
@@ -254,7 +254,7 @@ WHERE mails_confirmed < %s", $REF, $REF));
                $result = SQL_QUERY("SELECT id, level, percents FROM `{!_MYSQL_PREFIX!}_refdepths` ORDER BY level", __FILE__, __LINE__);
                if (SQL_NUMROWS($result) > 0) {
                        // Make referal levels editable and deletable
-                       $OUT = ""; $SW = 2;
+                       $OUT = ''; $SW = 2;
 
                        // List already existing categories for editing
                        while ($content = SQL_FETCHARRAY($result)) {
index e66269c12a98a025f49a71ef31f258357ae9c377..35ff5c61f71b3c164bd9d69d09628d827431d641 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // First merge temporarily the new API data into the current config
@@ -62,7 +62,7 @@ if (IS_FORM_SENT()) {
                ADMIN_SAVE_SETTINGS_POST();
        } else {
                // Failed to test the API!
-               LOAD_TEMPLATE("admin_settings_saved", false, GET_PRIMERA_ERROR_MESSAGE());
+               LOAD_TEMPLATE('admin_settings_saved', false, GET_PRIMERA_ERROR_MESSAGE());
        }
 }  else {
        // Prepare data for template output
index e69f3a7cc496e8fc43f9419fecc34a86f1ce445c..8faf60b1ef7414bea87e1dd34b3fa115b07490a6 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Test proxy settings
@@ -52,7 +52,7 @@ if (IS_FORM_SENT()) {
                ADMIN_SAVE_SETTINGS_POST();
        } else {
                // Invalid!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_PROXY_SETTINGS_INVALID'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_PROXY_SETTINGS_INVALID'));
        }
 } else {
        // Prepare content
index 95031a59ed85ad16511639d802c22e685a9c0242..31e1b4d1a5ec23a4cf022854e3210514e0033129 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (REQUEST_ISSET_GET(('rallye'))) {
        // Price submitted?
@@ -63,13 +63,13 @@ VALUES ('%s','%s','%s','%s')",
        REQUEST_POST('points'),
        REQUEST_POST('info')
 ), __FILE__, __LINE__);
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('RALLYE_PRICE_LEVEL_SAVED'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('RALLYE_PRICE_LEVEL_SAVED'));
                        } else {
                                // Free memory
                                SQL_FREERESULT($result);
 
                                // Price level found!
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('RALLYE_PRICE_ALREADY_FOUND'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('RALLYE_PRICE_ALREADY_FOUND'));
                        }
                }
        } elseif (REQUEST_ISSET_POST('remove')) {
@@ -83,9 +83,9 @@ VALUES ('%s','%s','%s','%s')",
                        }
 
                        // Output message
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('RALLYE_ENTRIES_DELETED'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('RALLYE_ENTRIES_DELETED'));
                } else {
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('RALLYE_ENTRIES_NOT_DELETED'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('RALLYE_ENTRIES_NOT_DELETED'));
                }
        } elseif (REQUEST_ISSET_POST('change')) {
                // Change entries
@@ -105,7 +105,7 @@ VALUES ('%s','%s','%s','%s')",
                }
 
                // Output message
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('RALLYE_ENTRIES_CHANGED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('RALLYE_ENTRIES_CHANGED'));
        }
 
        if (REQUEST_ISSET_POST('edit')) {
@@ -113,7 +113,7 @@ VALUES ('%s','%s','%s','%s')",
                $SEL = SELECTION_COUNT(REQUEST_POST('sel'));
                if ($SEL > 0) {
                        // Make selected editable
-                       $OUT = ""; $SW = 2;
+                       $OUT = ''; $SW = 2;
                        foreach (REQUEST_POST('sel') as $id => $sel) {
                                // Load data to selected rallye
                                $result = SQL_QUERY_ESC("SELECT rallye_id, price_level, points, info FROM `{!_MYSQL_PREFIX!}_rallye_prices` WHERE id=%s LIMIT 1",
@@ -145,14 +145,14 @@ VALUES ('%s','%s','%s','%s')",
                } else {
                        // Nothing selected
                        $content = sprintf(getMessage('RALLYE_NO_PRICES_SELECTED'), "<a href=\"{!URL!}/modules.php?module=admin&amp;what=config_rallye_prices&amp;rallye=".REQUEST_GET('rallye')."\">", "</a>");
-                       LOAD_TEMPLATE("admin_settings_saved", false, $content);
+                       LOAD_TEMPLATE('admin_settings_saved', false, $content);
                }
        } elseif (REQUEST_ISSET_POST('del')) {
                // Check if at last one line is selected
                $SEL = SELECTION_COUNT(REQUEST_POST('sel'));
                if ($SEL > 0) {
                        // List all prices
-                       $OUT = ""; $SW = 2;
+                       $OUT = ''; $SW = 2;
                        foreach (REQUEST_POST('sel') as $id => $sel) {
                                // Load data to selected rallye
                                $result = SQL_QUERY_ESC("SELECT rallye_id, price_level, points, info FROM `{!_MYSQL_PREFIX!}_rallye_prices` WHERE id=%s LIMIT 1",
@@ -185,7 +185,7 @@ VALUES ('%s','%s','%s','%s')",
                } else {
                        // Nothing selected
                        $content = RALLYE_NO_PRICES_SELECTED_1."<a href=\"{!URL!}/modules.php?module=admin&amp;what=config_rallye_prices&amp;rallye=".REQUEST_GET('rallye')."\">".RALLYE_NO_PRICES_SELECTED_2."</a>".RALLYE_NO_PRICES_SELECTED_3;
-                       LOAD_TEMPLATE("admin_settings_saved", false, $content);
+                       LOAD_TEMPLATE('admin_settings_saved', false, $content);
                }
        } else {
                // a rallye was selected, so check if there are already prices assigned...
@@ -194,7 +194,7 @@ VALUES ('%s','%s','%s','%s')",
 
                if (SQL_NUMROWS($result) > 0) {
                        // Load all prices for the selected rallye
-                       $OUT = ""; $SW = 2;
+                       $OUT = ''; $SW = 2;
                        while ($content = SQL_FETCHARRAY($result)) {
                                // Fix empty info
                                if (empty($content['info'])) $content['info'] = "---";
@@ -239,10 +239,10 @@ FROM `{!_MYSQL_PREFIX!}_rallye_data` AS d, `{!_MYSQL_PREFIX!}_admins` AS a
 WHERE d.admin_id=a.id ORDER BY start_time DESC", __FILE__, __LINE__);
        if (SQL_NUMROWS($result) > 0) {
                // List found rallyes
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result)) {
                        $select = "<input type=\"checkbox\" name=\"sel[".$content['id']."]\" class=\"admin_normal\" value=\"1\">";
-                       if ($content['is_active'] == "Y") $select = "<div class=\"big\">".$content['id']."</div>";
+                       if ($content['is_active'] == 'Y') $select = "<div class=\"big\">".$content['id']."</div>";
 
                        // Prepare data for the row template
                        // @TODO Rewritings: aid->admin_id, alogin->login in template
@@ -271,7 +271,7 @@ WHERE d.admin_id=a.id ORDER BY start_time DESC", __FILE__, __LINE__);
                LOAD_TEMPLATE("admin_list_rallye_prices");
        } else {
                // No rallyes setup so far
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('RALLYE_NO_RALLYES_SETUP'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('RALLYE_NO_RALLYES_SETUP'));
        }
 }
 //
index e885bb8f198a891ba85b5702257816ee4072b8e9..2cd7e393d23ec811665db0a85514b96a501820fc 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save configuration
@@ -57,14 +57,14 @@ if (IS_FORM_SENT()) {
 
        // Add more content
        switch (getConfig('refback_enabled')) {
-               case "Y": // Refback enabled
-                       $content['refback_enabled_y'] = " checked=\"checked\"";
-                       $content['refback_enabled_n'] = "";
+               case 'Y': // Refback enabled
+                       $content['refback_enabled_y'] = ' chkecked="checked"';
+                       $content['refback_enabled_n'] = '';
                        break;
 
-               case "N": // Refback disabled
-                       $content['refback_enabled_y'] = "";
-                       $content['refback_enabled_n'] = " checked=\"checked\"";
+               case 'N': // Refback disabled
+                       $content['refback_enabled_y'] = '';
+                       $content['refback_enabled_n'] = ' chkecked="checked"';
                        break;
        }
 
index bbbbfb02fc1d2dd5d57e4728d74f7740dcdd49d2..423e80f06d6ec453328ae2bf05914825a050f569 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save data
@@ -53,13 +53,13 @@ if (IS_FORM_SENT()) {
        define('__MEMBER_SELECTION', ADD_MEMBER_SELECTION_BOX(getConfig('def_refid'), false, true, true, "def_refid"));
 
        switch (getConfig('refid_target')) {
-               case "index":
+               case 'index':
                        define('__DEF_RT_INDEX'   , " selected=\"selected\"");
-                       define('__DEF_RT_REGISTER', "");
+                       define('__DEF_RT_REGISTER', '');
                        break;
 
-               case "register":
-                       define('__DEF_RT_INDEX'   , "");
+               case 'register':
+                       define('__DEF_RT_INDEX'   , '');
                        define('__DEF_RT_REGISTER', " selected=\"selected\"");
                        break;
 
@@ -69,20 +69,20 @@ if (IS_FORM_SENT()) {
        } // END - switch
 
        switch (getConfig('select_user_zero_refid')) {
-               case "Y":
+               case 'Y':
                        define('__RAND_REFID_Y', " selected=\"selected\"");
-                       define('__RAND_REFID_N', "");
+                       define('__RAND_REFID_N', '');
                        break;
 
-               case "N":
-                       define('__RAND_REFID_Y', "");
+               case 'N':
+                       define('__RAND_REFID_Y', '');
                        define('__RAND_REFID_N', " selected=\"selected\"");
                        break;
 
                default: // Invalid config!
                        DEBUG_LOG(__FILE__, __LINE__, sprintf("Invalid select_user_zero_refid %s detected.", getConfig('select_user_zero_refid')));
-                       define('__RAND_REFID_Y', "");
-                       define('__RAND_REFID_N', "");
+                       define('__RAND_REFID_Y', '');
+                       define('__RAND_REFID_N', '');
                        break;
        } // END - switch
 
index 9c49849aa0755e3bec7e197e8b8e5614e48d06ad..00c8c769984de5262e7b47c2206fbbe8e2491ebe 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Do we want to save changes?
 if (IS_FORM_SENT()) {
@@ -51,12 +51,12 @@ if (IS_FORM_SENT()) {
                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_must_register` SET field_required='%s' WHERE id=%s AND field_required != '%s' LIMIT 1",
                        array($value, bigintval($id), $value),__FILE__, __LINE__);
        }
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('REGISTER_ADMIN_CHANGES_SAVED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('REGISTER_ADMIN_CHANGES_SAVED'));
 }
 
 // List all register values
 $result = SQL_QUERY("SELECT id, field_name, field_required FROM `{!_MYSQL_PREFIX!}_must_register` ORDER BY `id`", __FILE__, __LINE__);
-$OUT = ""; $SW = 2;
+$OUT = ''; $SW = 2;
 while ($content = SQL_FETCHARRAY($result)) {
        // Get language string
        $content['field_name'] =  getMessage(strtoupper($content['field_name']));
index 3356d97c9fdbb19150058f90f88a1e05d6f6b930..171d284a26304e370841f82cc0c0850bf205a4ca 100644 (file)
@@ -38,7 +38,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Calculate timestamp from selections...
index 45346f8facb439dda8ff79b7600d2c4323118e28..2fb3501e65eacc4ceb2434b5c9c494859f1df52f 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save configuration
@@ -51,117 +51,117 @@ if (IS_FORM_SENT()) {
 } else {
        // Prepare data
        switch (getConfig('removeip_anon_ip')) {
-               case "Y":
-                       define('__CFG_REMOVEIP_ANON_IP_Y', " checked=\"checked\"");
-                       define('__CFG_REMOVEIP_ANON_IP_N', "");
+               case 'Y':
+                       define('__CFG_REMOVEIP_ANON_IP_Y', ' chkecked="checked"');
+                       define('__CFG_REMOVEIP_ANON_IP_N', '');
                        break;
 
-               case "N":
-                       define('__CFG_REMOVEIP_ANON_IP_Y', "");
-                       define('__CFG_REMOVEIP_ANON_IP_N', " checked=\"checked\"");
+               case 'N':
+                       define('__CFG_REMOVEIP_ANON_IP_Y', '');
+                       define('__CFG_REMOVEIP_ANON_IP_N', ' chkecked="checked"');
                        break;
        } // END - switch
 
        switch (getConfig('removeip_anon_host')) {
-               case "Y":
-                       define('__CFG_REMOVEIP_ANON_HOST_Y', " checked=\"checked\"");
-                       define('__CFG_REMOVEIP_ANON_HOST_N', "");
+               case 'Y':
+                       define('__CFG_REMOVEIP_ANON_HOST_Y', ' chkecked="checked"');
+                       define('__CFG_REMOVEIP_ANON_HOST_N', '');
                        break;
 
-               case "N":
-                       define('__CFG_REMOVEIP_ANON_HOST_Y', "");
-                       define('__CFG_REMOVEIP_ANON_HOST_N', " checked=\"checked\"");
+               case 'N':
+                       define('__CFG_REMOVEIP_ANON_HOST_Y', '');
+                       define('__CFG_REMOVEIP_ANON_HOST_N', ' chkecked="checked"');
                        break;
        } // END - switch
 
        switch (getConfig('removeip_anon_ua')) {
-               case "Y":
-                       define('__CFG_REMOVEIP_ANON_UA_Y', " checked=\"checked\"");
-                       define('__CFG_REMOVEIP_ANON_UA_N', "");
+               case 'Y':
+                       define('__CFG_REMOVEIP_ANON_UA_Y', ' chkecked="checked"');
+                       define('__CFG_REMOVEIP_ANON_UA_N', '');
                        break;
 
-               case "N":
-                       define('__CFG_REMOVEIP_ANON_UA_Y', "");
-                       define('__CFG_REMOVEIP_ANON_UA_N', " checked=\"checked\"");
+               case 'N':
+                       define('__CFG_REMOVEIP_ANON_UA_Y', '');
+                       define('__CFG_REMOVEIP_ANON_UA_N', ' chkecked="checked"');
                        break;
        } // END - switch
 
        switch (getConfig('removeip_anon_ref')) {
-               case "Y":
-                       define('__CFG_REMOVEIP_ANON_REF_Y', " checked=\"checked\"");
-                       define('__CFG_REMOVEIP_ANON_REF_N', "");
+               case 'Y':
+                       define('__CFG_REMOVEIP_ANON_REF_Y', ' chkecked="checked"');
+                       define('__CFG_REMOVEIP_ANON_REF_N', '');
                        break;
 
-               case "N":
-                       define('__CFG_REMOVEIP_ANON_REF_Y', "");
-                       define('__CFG_REMOVEIP_ANON_REF_N', " checked=\"checked\"");
+               case 'N':
+                       define('__CFG_REMOVEIP_ANON_REF_Y', '');
+                       define('__CFG_REMOVEIP_ANON_REF_N', ' chkecked="checked"');
                        break;
        } // END - switch
 
        switch (getConfig('removeip_admin_show')) {
-               case "Y":
-                       define('__CFG_REMOVEIP_ADMIN_SHOW_Y', " checked=\"checked\"");
-                       define('__CFG_REMOVEIP_ADMIN_SHOW_N', "");
+               case 'Y':
+                       define('__CFG_REMOVEIP_ADMIN_SHOW_Y', ' chkecked="checked"');
+                       define('__CFG_REMOVEIP_ADMIN_SHOW_N', '');
                        break;
 
-               case "N":
-                       define('__CFG_REMOVEIP_ADMIN_SHOW_Y', "");
-                       define('__CFG_REMOVEIP_ADMIN_SHOW_N', " checked=\"checked\"");
+               case 'N':
+                       define('__CFG_REMOVEIP_ADMIN_SHOW_Y', '');
+                       define('__CFG_REMOVEIP_ADMIN_SHOW_N', ' chkecked="checked"');
                        break;
        } // END - switch
 
        switch (getConfig('removeip_guest_show')) {
-               case "Y":
-                       define('__CFG_REMOVEIP_GUEST_SHOW_Y', " checked=\"checked\"");
-                       define('__CFG_REMOVEIP_GUEST_SHOW_N', "");
+               case 'Y':
+                       define('__CFG_REMOVEIP_GUEST_SHOW_Y', ' chkecked="checked"');
+                       define('__CFG_REMOVEIP_GUEST_SHOW_N', '');
                        break;
 
-               case "N":
-                       define('__CFG_REMOVEIP_GUEST_SHOW_Y', "");
-                       define('__CFG_REMOVEIP_GUEST_SHOW_N', " checked=\"checked\"");
+               case 'N':
+                       define('__CFG_REMOVEIP_GUEST_SHOW_Y', '');
+                       define('__CFG_REMOVEIP_GUEST_SHOW_N', ' chkecked="checked"');
                        break;
        } // END - switch
 
        switch (getConfig('removeip_member_show')) {
-               case "Y":
-                       define('__CFG_REMOVEIP_MEMBER_SHOW_Y', " checked=\"checked\"");
-                       define('__CFG_REMOVEIP_MEMBER_SHOW_N', "");
+               case 'Y':
+                       define('__CFG_REMOVEIP_MEMBER_SHOW_Y', ' chkecked="checked"');
+                       define('__CFG_REMOVEIP_MEMBER_SHOW_N', '');
                        break;
 
-               case "N":
-                       define('__CFG_REMOVEIP_MEMBER_SHOW_Y', "");
-                       define('__CFG_REMOVEIP_MEMBER_SHOW_N', " checked=\"checked\"");
+               case 'N':
+                       define('__CFG_REMOVEIP_MEMBER_SHOW_Y', '');
+                       define('__CFG_REMOVEIP_MEMBER_SHOW_N', ' chkecked="checked"');
                        break;
        } // END - switch
 
        switch (getConfig('removeip_sponsor_show')) {
-               case "Y":
-                       define('__CFG_REMOVEIP_SPONSOR_SHOW_Y', " checked=\"checked\"");
-                       define('__CFG_REMOVEIP_SPONSOR_SHOW_N', "");
+               case 'Y':
+                       define('__CFG_REMOVEIP_SPONSOR_SHOW_Y', ' chkecked="checked"');
+                       define('__CFG_REMOVEIP_SPONSOR_SHOW_N', '');
                        break;
 
-               case "N":
-                       define('__CFG_REMOVEIP_SPONSOR_SHOW_Y', "");
-                       define('__CFG_REMOVEIP_SPONSOR_SHOW_N', " checked=\"checked\"");
+               case 'N':
+                       define('__CFG_REMOVEIP_SPONSOR_SHOW_Y', '');
+                       define('__CFG_REMOVEIP_SPONSOR_SHOW_N', ' chkecked="checked"');
                        break;
        } // END - switch
 
        switch (getConfig('anonymous_ip')) {
                case "127.0.0.1":
                        define('__CFG_ANONYMOUS_IP_LOCAL' , " selected=\"selected\"");
-                       define('__CFG_ANONYMOUS_IP_ZERO'  , "");
-                       define('__CFG_ANONYMOUS_IP_RANDOM', "");
+                       define('__CFG_ANONYMOUS_IP_ZERO'  , '');
+                       define('__CFG_ANONYMOUS_IP_RANDOM', '');
                        break;
 
                case "0.0.0.0":
-                       define('__CFG_ANONYMOUS_IP_LOCAL' , "");
+                       define('__CFG_ANONYMOUS_IP_LOCAL' , '');
                        define('__CFG_ANONYMOUS_IP_ZERO'  , " selected=\"selected\"");
-                       define('__CFG_ANONYMOUS_IP_RANDOM', "");
+                       define('__CFG_ANONYMOUS_IP_RANDOM', '');
                        break;
 
                case "RANDOM":
-                       define('__CFG_ANONYMOUS_IP_LOCAL' , "");
-                       define('__CFG_ANONYMOUS_IP_ZERO'  , "");
+                       define('__CFG_ANONYMOUS_IP_LOCAL' , '');
+                       define('__CFG_ANONYMOUS_IP_ZERO'  , '');
                        define('__CFG_ANONYMOUS_IP_RANDOM', " selected=\"selected\"");
                        break;
        } // END - switch
index 59507e33fcf57dbe67655139e19dacf0b936192f..dc38a0da5bd90425dfc6fac889aa4ea643a9e89e 100644 (file)
@@ -43,14 +43,14 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Generate string
        $MODs = array();
        foreach (REQUEST_POST('mod') as $mod => $sel) {
                // Now you can never deselect the admin module, bah!!! ;-)
-               if (($sel == "Y") || ($mod == "admin")) {
+               if (($sel == 'Y') || ($mod == 'admin')) {
                        // Add module to queue
                        $MODs[] = $mod;
                }
@@ -65,7 +65,7 @@ if (IS_FORM_SENT()) {
 } else {
        // Load existing modules and generate TR rows for the template
        $result = SQL_QUERY("SELECT module, title FROM `{!_MYSQL_PREFIX!}_mod_reg` ORDER BY module", __FILE__, __LINE__);
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Set title to three dashes when no title is supplied
                if (empty($content['title'])) $content['title'] = "---";
@@ -73,12 +73,12 @@ if (IS_FORM_SENT()) {
                // Already registered module?
                if (ereg($content['module'], getConfig('rewrite_skip'))) {
                        // Found
-                       $y = " checked=\"checked\"";
-                       $n = "";
+                       $y = ' chkecked="checked"';
+                       $n = '';
                } else {
                        // Not found
-                       $y = "";
-                       $n = " checked=\"checked\"";
+                       $y = '';
+                       $n = ' chkecked="checked"';
                }
 
                // Remember data in array for the dynamic row template
index a5e360206177df5882fe89f852dd4803a5560330..a255238f79917a2c132d93804003d6560ec6f340 100644 (file)
@@ -42,19 +42,19 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        require($INC);
 }
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // If salt length is empty or null then we shall generate new passwords
        if (!REQUEST_ISSET_POST(('salt_length')) || (REQUEST_POST('salt_length') == "0")) {
                // Generate new passwords for all!
-               LOAD_INC("inc/gen_sql_patches.php");
+               LOAD_INC('inc/gen_sql_patches.php');
 
                // Forget the wrong number!
                REQUEST_UNSET_POST(('salt_length'));
 
                // Redirect to logout link
-               LOAD_URL("modules.php?module=admin&logout=1");
+               LOAD_URL('modules.php?module=admin&logout=1');
        } // END - if
 
        // Save settings
@@ -67,7 +67,7 @@ if (IS_FORM_SENT()) {
        define('__SALT_LENGTH', getConfig('salt_length'));
 
        // Load template
-       LOAD_TEMPLATE("admin_config_secure");
+       LOAD_TEMPLATE('admin_config_secure');
 }
 
 //
index efd5167394b7f901e664ce3c004ce74017b855b4..93d02731b729a9e1318b5a098d4aebcd6df7d5db 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Test Path
@@ -52,7 +52,7 @@ if (IS_FORM_SENT()) {
                ADMIN_SAVE_SETTINGS_POST();
        } else {
                // Invalid!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SESSION_SAVE_PATH_INVALID'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SESSION_SAVE_PATH_INVALID'));
        }
 } else {
        // Prepare content
index 4ab67dbaf37dc0efdb0c84d27c739d6ace78608d..cd8571b248c09620654b43a56dbef79c088a2c41 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Allow only direct points (non-floating)
index 2e76f928d2340f98255f3aa24fdd168cf50fe4a1..56cbd20f160e9b8ab9381c88c356b7d9d708b546 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Was the form submitted?
 if (IS_FORM_SENT()) {
@@ -55,19 +55,19 @@ if (IS_FORM_SENT()) {
        {
        case "MEMBERS":
                define('__MEMBERS_RADIO', " selected=\"selected\"");
-               define('__MODULES_RADIO', "");
-               define('__INACTIVE_RADIO', "");
+               define('__MODULES_RADIO', '');
+               define('__INACTIVE_RADIO', '');
                break;
 
        case "MODULES":
-               define('__MEMBERS_RADIO', "");
+               define('__MEMBERS_RADIO', '');
                define('__MODULES_RADIO', " selected=\"selected\"");
-               define('__INACTIVE_RADIO', "");
+               define('__INACTIVE_RADIO', '');
                break;
 
        case "INACTIVE":
-               define('__MEMBERS_RADIO', "");
-               define('__MODULES_RADIO', "");
+               define('__MEMBERS_RADIO', '');
+               define('__MODULES_RADIO', '');
                define('__INACTIVE_RADIO', " selected=\"selected\"");
                break;
        }
index f4136983a7a59b21e96394ec72cd4e3a740d93a1..4ce6fa3f8487154c28ae43d74760d45870efab57 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Was the form submitted?
 if (IS_FORM_SENT()) {
@@ -75,77 +75,77 @@ if (IS_FORM_SENT()) {
        // Prepare payment model for template
        if (getConfig('surfbar_pay_model') == "STATIC") {
                // Static model
-               define('__CONFIG_SURFBAR_PAY_MODEL_STATIC' , " checked=\"checked\"");
-               define('__CONFIG_SURFBAR_PAY_MODEL_DYNAMIC', "");
+               define('__CONFIG_SURFBAR_PAY_MODEL_STATIC' , ' chkecked="checked"');
+               define('__CONFIG_SURFBAR_PAY_MODEL_DYNAMIC', '');
        } else {
                // Dynamic model
-               define('__CONFIG_SURFBAR_PAY_MODEL_STATIC' , "");
-               define('__CONFIG_SURFBAR_PAY_MODEL_DYNAMIC', " checked=\"checked\"");
+               define('__CONFIG_SURFBAR_PAY_MODEL_STATIC' , '');
+               define('__CONFIG_SURFBAR_PAY_MODEL_DYNAMIC', ' chkecked="checked"');
        }
 
        // Prepare auto-sart
-       if (getConfig('surfbar_autostart') == "Y") {
+       if (getConfig('surfbar_autostart') == 'Y') {
                // Yes selected
-               define('__CONFIG_SURFBAR_AUTOSTART_Y', " checked=\"checked\"");
-               define('__CONFIG_SURFBAR_AUTOSTART_N', "");
+               define('__CONFIG_SURFBAR_AUTOSTART_Y', ' chkecked="checked"');
+               define('__CONFIG_SURFBAR_AUTOSTART_N', '');
        } else {
                // No selected
-               define('__CONFIG_SURFBAR_AUTOSTART_Y', "");
-               define('__CONFIG_SURFBAR_AUTOSTART_N', " checked=\"checked\"");
+               define('__CONFIG_SURFBAR_AUTOSTART_Y', '');
+               define('__CONFIG_SURFBAR_AUTOSTART_N', ' chkecked="checked"');
        }
 
        // Prepare notify limits
-       if (getConfig('surfbar_notify_limits') == "Y") {
+       if (getConfig('surfbar_notify_limits') == 'Y') {
                // Yes selected
-               define('__CONFIG_SURFBAR_NOTIFY_LIMITS_Y', " checked=\"checked\"");
-               define('__CONFIG_SURFBAR_NOTIFY_LIMITS_N', "");
+               define('__CONFIG_SURFBAR_NOTIFY_LIMITS_Y', ' chkecked="checked"');
+               define('__CONFIG_SURFBAR_NOTIFY_LIMITS_N', '');
        } else {
                // No selected
-               define('__CONFIG_SURFBAR_NOTIFY_LIMITS_Y', "");
-               define('__CONFIG_SURFBAR_NOTIFY_LIMITS_N', " checked=\"checked\"");
+               define('__CONFIG_SURFBAR_NOTIFY_LIMITS_Y', '');
+               define('__CONFIG_SURFBAR_NOTIFY_LIMITS_N', ' chkecked="checked"');
        }
 
        // Prepare notify admin about unlocked emails
-       if (getConfig('surfbar_notify_admin_unlock') == "Y") {
+       if (getConfig('surfbar_notify_admin_unlock') == 'Y') {
                // Yes selected
-               define('__CONFIG_SURFBAR_NOTIFY_ADMIN_UNLOCK_Y', " checked=\"checked\"");
-               define('__CONFIG_SURFBAR_NOTIFY_ADMIN_UNLOCK_N', "");
+               define('__CONFIG_SURFBAR_NOTIFY_ADMIN_UNLOCK_Y', ' chkecked="checked"');
+               define('__CONFIG_SURFBAR_NOTIFY_ADMIN_UNLOCK_N', '');
        } else {
                // No selected
-               define('__CONFIG_SURFBAR_NOTIFY_ADMIN_UNLOCK_Y', "");
-               define('__CONFIG_SURFBAR_NOTIFY_ADMIN_UNLOCK_N', " checked=\"checked\"");
+               define('__CONFIG_SURFBAR_NOTIFY_ADMIN_UNLOCK_Y', '');
+               define('__CONFIG_SURFBAR_NOTIFY_ADMIN_UNLOCK_N', ' chkecked="checked"');
        }
 
        // Prepare order migration
-       if (getConfig('surfbar_migrate_order') == "Y") {
+       if (getConfig('surfbar_migrate_order') == 'Y') {
                // Yes selected
-               define('__CONFIG_SURFBAR_MIGRATE_ORDER_Y', " checked=\"checked\"");
-               define('__CONFIG_SURFBAR_MIGRATE_ORDER_N', "");
+               define('__CONFIG_SURFBAR_MIGRATE_ORDER_Y', ' chkecked="checked"');
+               define('__CONFIG_SURFBAR_MIGRATE_ORDER_N', '');
        } else {
                // No selected
-               define('__CONFIG_SURFBAR_MIGRATE_ORDER_Y', "");
-               define('__CONFIG_SURFBAR_MIGRATE_ORDER_N', " checked=\"checked\"");
+               define('__CONFIG_SURFBAR_MIGRATE_ORDER_Y', '');
+               define('__CONFIG_SURFBAR_MIGRATE_ORDER_N', ' chkecked="checked"');
        }
 
        // Pause URL mode
        if (getConfig('surfbar_pause_mode') == "INTERNAL") {
                // Internal pause page
-               define('__CONFIG_SURFBAR_PAUSE_MODE_INTERNAL', " checked=\"checked\"");
-               define('__CONFIG_SURFBAR_PAUSE_MODE_EXTERNAL', "");
+               define('__CONFIG_SURFBAR_PAUSE_MODE_INTERNAL', ' chkecked="checked"');
+               define('__CONFIG_SURFBAR_PAUSE_MODE_EXTERNAL', '');
        } else {
                // External pause page (if not empty)
-               define('__CONFIG_SURFBAR_PAUSE_MODE_INTERNAL', "");
-               define('__CONFIG_SURFBAR_PAUSE_MODE_EXTERNAL', " checked=\"checked\"");
+               define('__CONFIG_SURFBAR_PAUSE_MODE_INTERNAL', '');
+               define('__CONFIG_SURFBAR_PAUSE_MODE_EXTERNAL', ' chkecked="checked"');
        }
 
        // Notification mode
        if (getConfig('surfbar_notification_mode') == "INSTANT") {
                // Instant notification
                define('__CONFIG_SURFBAR_NOTIFICATION_MODE_INSTANT', " selected=\"selected\"");
-               define('__CONFIG_SURFBAR_NOTIFICATION_MODE_RESET'  , "");
+               define('__CONFIG_SURFBAR_NOTIFICATION_MODE_RESET'  , '');
        } else {
                // Only daily reset
-               define('__CONFIG_SURFBAR_NOTIFICATION_MODE_INSTANT', "");
+               define('__CONFIG_SURFBAR_NOTIFICATION_MODE_INSTANT', '');
                define('__CONFIG_SURFBAR_NOTIFICATION_MODE_RESET'  , " selected=\"selected\"");
        }
 
index 27ca908c8131b9d0d29a72213a6ecb886486a724..364fc9bd449dadbc5647c0089dda32ad19a896c9 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT())
 {
index 4b2da08a2d5749a02a7ba5720574f482ad6c8cc5..b7a9ea5a017491f18fd95d1f211fdd9faa481858 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT())
 {
index fd16f37cef27bbeecbc9e02d14be3646a125cc44..101f9111a7687f1d05ce1b7e5d2dbf473b8bf4c6 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save settings...
@@ -57,13 +57,13 @@ define('__TRANS_CODE_VALUE'   , getConfig(('transfer_code')));
 
 // Autppurge expired transfer entries?
 switch (getConfig('ap_transfer')) {
-       case "Y":
+       case 'Y':
                define('__YES_AP', " selected=\"selected\"");
-               define('__NO_AP', "");
+               define('__NO_AP', '');
                break;
 
-       case "N":
-               define('__YES_AP', "");
+       case 'N':
+               define('__YES_AP', '');
                define('__NO_AP', " selected=\"selected\"");
                break;
 }
index 8b8a63120f6a5cf64d45712dcb533c836dd656fd..5479e097dbb960c0f805af208ccc8c038907ce5b 100644 (file)
@@ -42,7 +42,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        require($INC);
 }
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // Save settings
index ef6d111b5ebba5056fdda63c144931f225e75571..d68dd42107edb3b064fa2b300a7da5f7ef510f17 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // First merge temporarily the new API data into the current config
@@ -64,7 +64,7 @@ if (IS_FORM_SENT()) {
                ADMIN_SAVE_SETTINGS_POST();
        } else {
                // Failed to test the API!
-               LOAD_TEMPLATE("admin_settings_saved", false, GET_WERNIS_ERROR_MESSAGE());
+               LOAD_TEMPLATE('admin_settings_saved', false, GET_WERNIS_ERROR_MESSAGE());
        }
 }  else {
        // Prepare data for template output
@@ -84,25 +84,25 @@ if (IS_FORM_SENT()) {
        );
 
        // Prepare payout Y/N selection
-       if (getConfig('wernis_payout_active') == "Y") {
+       if (getConfig('wernis_payout_active') == 'Y') {
                // Payout allowed
-               define('__CFG_WERNIS_PAYOUT_ACTIVE_Y', " checked=\"checked\"");
-               define('__CFG_WERNIS_PAYOUT_ACTIVE_N', "");
+               define('__CFG_WERNIS_PAYOUT_ACTIVE_Y', ' chkecked="checked"');
+               define('__CFG_WERNIS_PAYOUT_ACTIVE_N', '');
        } else {
                // Payout disabled
-               define('__CFG_WERNIS_PAYOUT_ACTIVE_Y', "");
-               define('__CFG_WERNIS_PAYOUT_ACTIVE_N', " checked=\"checked\"");
+               define('__CFG_WERNIS_PAYOUT_ACTIVE_Y', '');
+               define('__CFG_WERNIS_PAYOUT_ACTIVE_N', ' chkecked="checked"');
        }
 
        // Prepare withdraw Y/N selection
-       if (getConfig('wernis_withdraw_active') == "Y") {
+       if (getConfig('wernis_withdraw_active') == 'Y') {
                // Payout allowed
-               define('__CFG_WERNIS_WITHDRAW_ACTIVE_Y', " checked=\"checked\"");
-               define('__CFG_WERNIS_WITHDRAW_ACTIVE_N', "");
+               define('__CFG_WERNIS_WITHDRAW_ACTIVE_Y', ' chkecked="checked"');
+               define('__CFG_WERNIS_WITHDRAW_ACTIVE_N', '');
        } else {
                // Payout disabled
-               define('__CFG_WERNIS_WITHDRAW_ACTIVE_Y', "");
-               define('__CFG_WERNIS_WITHDRAW_ACTIVE_N', " checked=\"checked\"");
+               define('__CFG_WERNIS_WITHDRAW_ACTIVE_Y', '');
+               define('__CFG_WERNIS_WITHDRAW_ACTIVE_N', ' chkecked="checked"');
        }
 
        // Load template
index 9a59dd05380d17543b926e46da4b2fd6cdc3a3d7..421d565961ff917b6dd2a4db90461d9d214c75e8 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("yoomedia")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "yoomedia");
+} elseif (!EXT_IS_ACTIVE('yoomedia')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'yoomedia');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Was the form submitted?
 if (IS_FORM_SENT()) {
@@ -56,7 +56,7 @@ if (IS_FORM_SENT()) {
                ADMIN_SAVE_SETTINGS_POST();
        } else {
                // Config not saved
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_CONFIG_YOOMEDIA_TEST_FAILED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_CONFIG_YOOMEDIA_TEST_FAILED'));
        }
 } else {
        // Prepare content
@@ -74,19 +74,19 @@ if (IS_FORM_SENT()) {
        switch (getConfig('yoomedia_erotic_allowed')) {
                case 0: // No erotic at all
                        define('__CFG_YOOMEDIA_EROTIC_NONE'   , " selected=\"selected\"");
-                       define('__CFG_YOOMEDIA_EROTIC_INCLUDE', "");
-                       define('__CFG_YOOMEDIA_EROTIC_ONLY'   , "");
+                       define('__CFG_YOOMEDIA_EROTIC_INCLUDE', '');
+                       define('__CFG_YOOMEDIA_EROTIC_ONLY'   , '');
                        break;
 
                case 1: // Include erotic
-                       define('__CFG_YOOMEDIA_EROTIC_NONE'   , "");
+                       define('__CFG_YOOMEDIA_EROTIC_NONE'   , '');
                        define('__CFG_YOOMEDIA_EROTIC_INCLUDE', " selected=\"selected\"");
-                       define('__CFG_YOOMEDIA_EROTIC_ONLY'   , "");
+                       define('__CFG_YOOMEDIA_EROTIC_ONLY'   , '');
                        break;
 
                case 2: // Erotic only
-                       define('__CFG_YOOMEDIA_EROTIC_NONE'   , "");
-                       define('__CFG_YOOMEDIA_EROTIC_INCLUDE', "");
+                       define('__CFG_YOOMEDIA_EROTIC_NONE'   , '');
+                       define('__CFG_YOOMEDIA_EROTIC_INCLUDE', '');
                        define('__CFG_YOOMEDIA_EROTIC_ONLY'   , " selected=\"selected\"");
                        break;
        }
index e980e2e767462def6484ea9b7ce4ede4627bb089..f402412014f8aa0fb5d26e1fa0aa326b46c1dbc7 100644 (file)
@@ -41,7 +41,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Init counter for deleted mails
 $cnt = 0;
@@ -88,7 +88,7 @@ WHERE s.pool_id=%s LIMIT 1",
                        list($stats_id) = SQL_FETCHROW($result_pool);
 
                        // Get all user links
-                       $links = GET_TOTAL_DATA($stats_id, "user_links", "userid", "stats_id", true);
+                       $links = GET_TOTAL_DATA($stats_id, "user_links", 'userid', "stats_id", true);
 
                        // Reset sent mails for recipient(s)
                        REDUCED_RECIPIENT_RECEIVED_MAILS("stats_id", REQUEST_GET('mid'), $links);
@@ -113,22 +113,22 @@ WHERE s.pool_id=%s LIMIT 1",
                                        // Output message
                                        if (getConfig('repay_deleted_mails') == "REPAY") {
                                                // Repayed
-                                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_POINTS_REPAYED'),
+                                               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_POINTS_REPAYED'),
                                                        TRANSLATE_COMMA($totalPoints)
                                                ));
                                        } else {
                                                // To jackpot
-                                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_POINTS_TO_JACKPOT'),
+                                               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_POINTS_TO_JACKPOT'),
                                                        TRANSLATE_COMMA($totalPoints)
                                                ));
                                        }
                                } else {
                                        // No points repayed!
-                                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NO_POINTS_REPAYED'));
+                                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NO_POINTS_REPAYED'));
                                }
                        } else {
                                // Points shredded!
-                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_POINTS_SHREDDED'), $totalPoints));
+                               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_POINTS_SHREDDED'), $totalPoints));
                        }
 
                        // Remove links from DB
@@ -137,7 +137,7 @@ WHERE s.pool_id=%s LIMIT 1",
                        $cnt += SQL_AFFECTEDROWS();
 
                        // Load template for link
-                       LOAD_TEMPLATE("admin_settings_saved", false, "<a href=\"{!URL!}/modules.php?module=admin&amp;what=del_email&amp;pid=".bigintval(REQUEST_GET('mid'))."\">".ADMIN_REMOVE_STATS_ENTRY."</a>");
+                       LOAD_TEMPLATE('admin_settings_saved', false, "<a href=\"{!URL!}/modules.php?module=admin&amp;what=del_email&amp;pid=".bigintval(REQUEST_GET('mid'))."\">".ADMIN_REMOVE_STATS_ENTRY."</a>");
                } // END - if
 
                // Free the result
@@ -152,7 +152,7 @@ WHERE s.pool_id=%s LIMIT 1",
                OUTPUT_HTML(sprintf(ADMIN_DELETED_MAILS_COUNT, $cnt));
        } else {
                // Mail already deleted!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NORMAL_MAIL_ALREADY_DELETED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NORMAL_MAIL_ALREADY_DELETED'));
        }
 } elseif (REQUEST_ISSET_GET(('pid'))) {
        // Remove stats entries
@@ -160,8 +160,8 @@ WHERE s.pool_id=%s LIMIT 1",
                array(bigintval(REQUEST_GET('pid'))), __FILE__, __LINE__);
 
        // Output message
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_USER_STATS_REMOVED'));
-} elseif ((REQUEST_ISSET_GET(('bid'))) && (EXT_IS_ACTIVE("bonus"))) {
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_USER_STATS_REMOVED'));
+} elseif ((REQUEST_ISSET_GET(('bid'))) && (EXT_IS_ACTIVE('bonus'))) {
        // Load data from bonus mail
        $result = SQL_QUERY_ESC("SELECT id, subject, url, timestamp, mails_sent FROM `{!_MYSQL_PREFIX!}_bonus` WHERE id=%s",
                array(bigintval(REQUEST_GET('bid'))), __FILE__, __LINE__);
@@ -172,7 +172,7 @@ WHERE s.pool_id=%s LIMIT 1",
                list ($id, $subject, $url, $timestamp, $sent) = SQL_FETCHROW($result);
 
                // Reset sent mails for recipient(s)
-               REDUCED_RECIPIENT_RECEIVED_MAILS("bonus_id", REQUEST_GET('bid'), $sent);
+               REDUCED_RECIPIENT_RECEIVED_MAILS('bonus_id', REQUEST_GET('bid'), $sent);
 
                // Init counter for deleted mails
                $cnt = 0;
@@ -196,12 +196,12 @@ WHERE s.pool_id=%s LIMIT 1",
                LOAD_TEMPLATE("admin_del_email_bonus");
        } else {
                // Mail already deleted!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_BONUS_MAIL_ALREADY_DELETED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_BONUS_MAIL_ALREADY_DELETED'));
        }
 
        // Free result
        SQL_FREERESULT($result);
-} elseif ((REQUEST_ISSET_GET(('nid'))) && (GET_EXT_VERSION("bonus") >= "0.8.7")) {
+} elseif ((REQUEST_ISSET_GET(('nid'))) && (GET_EXT_VERSION('bonus') >= '0.8.7')) {
        // Load data from bonus mail
        $result = SQL_QUERY_ESC("SELECT id, subject, url, timestamp FROM `{!_MYSQL_PREFIX!}_bonus` WHERE id=%s",
                array(bigintval(REQUEST_GET('nid'))), __FILE__, __LINE__);
@@ -234,11 +234,11 @@ WHERE s.pool_id=%s LIMIT 1",
                LOAD_TEMPLATE("admin_del_email_notify");
        } else {
                // Mail already deleted!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NOTIFY_MAIL_ALREADY_DELETED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NOTIFY_MAIL_ALREADY_DELETED'));
        }
 } else {
        // No mail orders fond
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_WRONG_CALL'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_WRONG_CALL'));
 }
 
 //
index 0ffaeabb931f10504027e9ec5b427bed79239f4f..dcf74d948996c030ce4646ce6a59c7519f59065f 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Check for selected holidays
 $SUM = 0;
@@ -87,8 +87,8 @@ WHERE id=%s LIMIT 1", array(bigintval($id)), __FILE__, __LINE__);
                        $cnt++;
                }
        }
-       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('HOLIDAY_ADMIN_MULTI_DEL'), $cnt));
-} elseif (REQUEST_ISSET_GET(('uid'))) {
+       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('HOLIDAY_ADMIN_MULTI_DEL'), $cnt));
+} elseif (REQUEST_ISSET_GET('uid')) {
        // Set default message
        $message = getMessage('HOLIDAY_ADMIN_SINGLE_404');
 
@@ -116,10 +116,10 @@ WHERE userid=%s LIMIT 1", array(bigintval(REQUEST_GET('uid'))), __FILE__, __LINE
        SQL_FREERESULT($result_load);
 
        // Output message
-       LOAD_TEMPLATE("admin_settings_saved", false, $message);
+       LOAD_TEMPLATE('admin_settings_saved', false, $message);
 } else {
        // Please call me over other scripts... ;)
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('HOLIDAY_NO_DIRECT_CALL'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('HOLIDAY_NO_DIRECT_CALL'));
 }
 
 //
index 91cc04bc55a281cc7980c1693a02158da3b0cd5c..bf0236f70dee581c75b74546b692297d6d1191e1 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (REQUEST_ISSET_GET(('id'))) {
        // Check for selected sponsor
@@ -76,7 +76,7 @@ if (REQUEST_ISSET_GET(('id'))) {
                                array(bigintval(REQUEST_GET('id'))), __FILE__, __LINE__);
 
                        // Output message
-                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_SPONSOR_DELETED'), bigintval(REQUEST_GET('id'))));
+                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_SPONSOR_DELETED'), bigintval(REQUEST_GET('id'))));
                } elseif (REQUEST_ISSET_POST(('no'))) {
                        // Do not delete him...
                        LOAD_URL("modules.php?module=admin&amp;what=list_sponsor&amp;id=".bigintval(REQUEST_GET('id')));
@@ -96,11 +96,11 @@ if (REQUEST_ISSET_GET(('id'))) {
                }
        } else {
                // Sponsor not found!
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_SPONSOR_404'), bigintval(REQUEST_GET('id'))));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_SPONSOR_404'), bigintval(REQUEST_GET('id'))));
        }
 } else {
        // Not called by what-list_sponsor.php
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_CALL_NOT_DIRECTLY'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_CALL_NOT_DIRECTLY'));
 }
 
 //
index a697ada9cd30a0e23c32bddd38de22203662ec24..00fdb86254599e9a67ffa254322660dc7a916f27 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("task")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "task");
+} elseif (!EXT_IS_ACTIVE('task')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'task');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 //
 ?>
index d72b3778793ea078db80917918db0b1b77dffb06..ba95f2ee378dfc10dbb851cd635f0f8f0bad372d 100644 (file)
@@ -43,7 +43,7 @@ if (ereg(basename(__FILE__), $_SERVER['PHP_SELF']) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (REQUEST_ISSET_POST('del')) {
        // Delete entries from tables
@@ -70,7 +70,7 @@ $result = SQL_QUERY("SELECT userid, to_uid, trans_id, points, reason, time_trans
 $total = 0;
 if (SQL_NUMROWS($result) > 0) {
        // Output rows
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Prepare data for the row template
                // @TODO Rewritings: idx->trans_id in template
@@ -97,7 +97,7 @@ if (SQL_NUMROWS($result) > 0) {
        // Nothing for in and out
        $OUT = "<tr>
   <td colspan=\"6\" align=\"center\" class=\"bottom2\" height=\"70\">
-    ".LOAD_TEMPLATE("admin_settings_saved", true, getMessage('TRANSFER_NO_INOUT_TRANSFERS'))."
+    ".LOAD_TEMPLATE('admin_settings_saved', true, getMessage('TRANSFER_NO_INOUT_TRANSFERS'))."
   </td>
 </tr>";
 }
index 7547661afa54c62bbf9d6ae2ede664f2112235d8..3c72c1e8453650fea6ef6333cb85e037f484ef97 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Display only title when no form was submitted
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // User exists..
 if ((IS_FORM_SENT()) || ((REQUEST_ISSET_POST('del')) && (REQUEST_ISSET_POST(('reason'))))) {
@@ -58,15 +58,15 @@ if ((IS_FORM_SENT()) || ((REQUEST_ISSET_POST('del')) && (REQUEST_ISSET_POST(('re
                DELETE_USER_ACCOUNT(REQUEST_GET('uid'), REQUEST_POST('reason'));
 
                // Output message
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_DEL_COMPLETED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_DEL_COMPLETED'));
        } else {
                // Account does not exists!
-               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
        }
 } elseif (REQUEST_ISSET_POST(('no'))) {
        // Do not delete him...
        LOAD_URL(ADMIN_CREATE_USERID_LINK(REQUEST_GET('uid')));
-} elseif (!REQUEST_ISSET_GET(('uid'))) {
+} elseif (!REQUEST_ISSET_GET('uid')) {
        // Output selection form with all confirmed user accounts listed
        ADD_MEMBER_SELECTION_BOX();
 } else {
@@ -91,7 +91,7 @@ if ((IS_FORM_SENT()) || ((REQUEST_ISSET_POST('del')) && (REQUEST_ISSET_POST(('re
                LOAD_TEMPLATE("admin_del_user", false, $content);
        } else {
                // Account does not exists!
-               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
        }
 }
 
index e087a97c3eb0b4d4343bb98327ca2a9d6b01dac8..00999d91db65f6b17e15719af854fcf95ca94146 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if ((IS_FORM_SENT()) && (!REQUEST_ISSET_POST(('id')))) {
        REQUEST_UNSET_POST('ok');
@@ -86,10 +86,10 @@ WHERE id=%s LIMIT 1",
                }
 
                // Display message
-               LOAD_TEMPLATE("admin_settings_saved", false, $content);
+               LOAD_TEMPLATE('admin_settings_saved', false, $content);
        } else {
                // There are mail orders available
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Prepare data for the row template
                        // @TODO Rewritings: subj->subject in template
@@ -118,7 +118,7 @@ WHERE id=%s LIMIT 1",
        }
 } else {
        // No mail orders left in pool
-       LOAD_TEMPLATE("admin_settings_saved", false, "<span class=\"admin_failed\">{--ADMIN_NO_MAILS_IN_POOL--}</span>");
+       LOAD_TEMPLATE('admin_settings_saved', false, "<span class=\"admin_failed\">{--ADMIN_NO_MAILS_IN_POOL--}</span>");
 }
 
 //
index 09e16257504c32388e9d384657a37dbe4ff2ed64..71832e8043419e6b21700591ee143c860969324c 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if ((REQUEST_ISSET_GET(('id'))) && (REQUEST_ISSET_GET(('mode')))) {
        // Check for selected sponsor
@@ -66,19 +66,19 @@ if ((REQUEST_ISSET_GET(('id'))) && (REQUEST_ISSET_GET(('mode')))) {
                {
                case "M":
                        define('__GENDER_M', " selected=\"selected\"");
-                       define('__GENDER_F', "");
-                       define('__GENDER_C', "");
+                       define('__GENDER_F', '');
+                       define('__GENDER_C', '');
                        break;
 
                case "F":
-                       define('__GENDER_M', "");
+                       define('__GENDER_M', '');
                        define('__GENDER_F', " selected=\"selected\"");
-                       define('__GENDER_C', "");
+                       define('__GENDER_C', '');
                        break;
 
                case "C":
-                       define('__GENDER_M', "");
-                       define('__GENDER_F', "");
+                       define('__GENDER_M', '');
+                       define('__GENDER_F', '');
                        define('__GENDER_C', " selected=\"selected\"");
                        break;
                }
@@ -189,7 +189,7 @@ if ((REQUEST_ISSET_GET(('id'))) && (REQUEST_ISSET_GET(('mode')))) {
 
                        if (!empty($message)) {
                                // Output message
-                               LOAD_TEMPLATE("admin_settings_saved", false, $message);
+                               LOAD_TEMPLATE('admin_settings_saved', false, $message);
                        } // END - if
                } elseif (FILE_READABLE(sprintf("%stemplates/%s/html/admin/%s.tpl", constant('PATH'), GET_LANGUAGE(), $TPL))) {
                        // Create mailto link
@@ -199,15 +199,15 @@ if ((REQUEST_ISSET_GET(('id'))) && (REQUEST_ISSET_GET(('mode')))) {
                        LOAD_TEMPLATE($TPL);
                } else {
                        // Template not found!
-                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_SPONSOR_MODUS_TPL_404'), REQUEST_GET(('mode'))));
+                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_SPONSOR_MODUS_TPL_404'), REQUEST_GET(('mode'))));
                }
        } else {
                // Sponsor not found!
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_SPONSOR_404'), bigintval(REQUEST_GET('id'))));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_SPONSOR_404'), bigintval(REQUEST_GET('id'))));
        }
 } else {
        // Not called by what-list_sponsor.php
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_CALL_NOT_DIRECTLY'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_CALL_NOT_DIRECTLY'));
 }
 
 //
index 06b725b691dce08416b7835f1a8681f5b4492ddd..32b6ceb9b914350b586d35e42ccdaa4ef1ca0bf7 100644 (file)
@@ -43,11 +43,11 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Fix a notice
 $result_main = false;
-if (REQUEST_ISSET_GET(('uid'))) {
+if (REQUEST_ISSET_GET('uid')) {
        //                                    0      1        2         3      4     5      6       7         8          9           10         11
        $result_main = SQL_QUERY_ESC("SELECT gender, surname, family, street_nr, zip, city, country, email, birth_day, birth_month, birth_year, max_mails
 FROM `{!_MYSQL_PREFIX!}_user_data`
@@ -56,10 +56,10 @@ LIMIT 1",
                array(bigintval(REQUEST_GET('uid'))), __FILE__, __LINE__);
 }
 
-if ((SQL_NUMROWS($result_main) == 1) || (!REQUEST_ISSET_GET(('uid'))))
+if ((SQL_NUMROWS($result_main) == 1) || (!REQUEST_ISSET_GET('uid')))
 {
        // User found
-       if (!REQUEST_ISSET_GET(('uid')))
+       if (!REQUEST_ISSET_GET('uid'))
        {
                // Output selection form with all confirmed user accounts listed
                ADD_MEMBER_SELECTION_BOX();
@@ -67,7 +67,7 @@ if ((SQL_NUMROWS($result_main) == 1) || (!REQUEST_ISSET_GET(('uid'))))
         elseif (REQUEST_ISSET_POST('edit'))
        {
                // Ok, change the account...
-               $PASS = false; $add = "";
+               $PASS = false; $add = '';
                if ((!REQUEST_ISSET_POST(('pass1'))) && (!REQUEST_ISSET_POST(('pass2'))))
                {
                        // Don't change the password
@@ -113,7 +113,7 @@ WHERE userid=%s LIMIT 1",
                }
 
                // Load template
-               LOAD_TEMPLATE("admin_settings_saved", false, $content);
+               LOAD_TEMPLATE('admin_settings_saved', false, $content);
        }
         else
        {
@@ -126,19 +126,19 @@ WHERE userid=%s LIMIT 1",
                {
                case "M":
                        define('_GENDER_M', " selected=\"selected\"");
-                       define('_GENDER_F', "");
-                       define('_GENDER_C', "");
+                       define('_GENDER_F', '');
+                       define('_GENDER_C', '');
                        break;
 
                case "F":
-                       define('_GENDER_M', "");
+                       define('_GENDER_M', '');
                        define('_GENDER_F', " selected=\"selected\"");
-                       define('_GENDER_C', "");
+                       define('_GENDER_C', '');
                        break;
 
                case "C":
-                       define('_GENDER_M', "");
-                       define('_GENDER_F', "");
+                       define('_GENDER_M', '');
+                       define('_GENDER_F', '');
                        define('_GENDER_C', " selected=\"selected\"");
                        break;
                }
@@ -152,7 +152,7 @@ WHERE userid=%s LIMIT 1",
        }
 } else {
        // Account does not exists!
-       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
+       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
 }
 
 //
index 324f92dfafafac1f4f5b62b4100c49f518609d57..3e9cf6770b5b0d22148e1262eb018a1fa36d97ac 100644 (file)
@@ -46,7 +46,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 //             0     1        2      3        4          5           6          7      8         9        10
 $sql = "SELECT id, sender, subject, text, receivers, payment_id, data_type, timestamp, url, target_send, cat_id
@@ -83,11 +83,11 @@ if (SQL_NUMROWS($result) > 0)
        }
         else
        {
-               define('__TOP_EMAIL_NAV'   , "");
-               define('__BOTTOM_EMAIL_NAV', "");
+               define('__TOP_EMAIL_NAV'   , '');
+               define('__BOTTOM_EMAIL_NAV', '');
        }
 
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($pool = SQL_FETCHROW($result))
        {
                // Check sent mails and clicks
@@ -113,7 +113,7 @@ if (SQL_NUMROWS($result) > 0)
                        'pay'         => GET_PAYMENT($pool[5]),
                        'cat'         => GET_CATEGORY($pool[10]),
                        'sent'        => $sent,
-                       'ruids'       => str_replace(";", ", ", $pool[4]),
+                       'ruids'       => str_replace(';', ", ", $pool[4]),
                        'unconfirmed' => $unconfirmed,
                        'type'        => TRANSLATE_POOL_TYPE($pool[6]),
                        'tsend'       => $pool[9],
@@ -136,7 +136,7 @@ if (SQL_NUMROWS($result) > 0)
        LOAD_TEMPLATE("admin_email_archiv");
 } else {
        // No mail orders fond
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NO_MAILS_IN_POOL'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NO_MAILS_IN_POOL'));
 }
 //
 ?>
index 9fb44ceaabd744870be10c48bad5e68176e1f4ec..da4610be15534c9ed240c86131edfd97722ca155 100644 (file)
@@ -53,7 +53,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Normal mails ordered by your members
 //              0     1       2       3       4           5          6          7       8        9          10
@@ -63,7 +63,7 @@ WHERE data_type IN('ADMIN','TEMP','NEW','ACTIVE')
 ORDER BY timestamp DESC";
 
 $WHO = _ALL;
-$SQL2 = "";
+$SQL2 = '';
 
 if (REQUEST_ISSET_GET(('mid'))) {
        // Only a specific mail shall be displayed
@@ -73,7 +73,7 @@ if (REQUEST_ISSET_GET(('mid'))) {
         WHERE id='".bigintval(REQUEST_GET('mid'))."'
         LIMIT 1";
        $WHO = MAIL_ID.": ".REQUEST_GET('mid');
-} elseif (REQUEST_ISSET_GET(('uid'))) {
+} elseif (REQUEST_ISSET_GET('uid')) {
        // All mails by a specific member shall be displayed
        //              0     1       2       3       4           5          6          7       8        9          10
        $sql = "SELECT id, sender, subject, text, receivers, payment_id, data_type, timestamp, url, target_send, cat_id
@@ -83,7 +83,7 @@ ORDER by timestamp DESC";
        $WHO = USER_ID.": ".REQUEST_GET('uid');
 }
 
-if ((EXT_IS_ACTIVE("bonus")) && ($WHO == _ALL)) {
+if ((EXT_IS_ACTIVE('bonus')) && ($WHO == _ALL)) {
        // Bonus mails sent by you
        //               0     1       2        3        4      5       6          7       8      9         10          11        12
        $SQL2 = "SELECT id, subject, text, receivers, points, time, data_type, timestamp, url, cat_id, target_send, mails_sent, clicks
@@ -139,7 +139,7 @@ SQL_FREERESULT($result_normal);
 $MAIL = false;
 if (SQL_NUMROWS($result_list) > 0) {
        // Init rows
-       $OUT = ""; $content = array();
+       $OUT = ''; $content = array();
 
        // Walk through all entries
        while ($pool = SQL_FETCHARRAY($result_list)) {
@@ -166,7 +166,7 @@ if (SQL_NUMROWS($result_list) > 0) {
                $content['text']        = COMPILE_CODE($pool['text']);
                $content['payment']     = GET_PAYMENT($pool['payment_id']);
                $content['category']    = GET_CATEGORY($pool['cat_id']);
-               $content['receivers']   = str_replace(";", ", ", $pool['receivers']);
+               $content['receivers']   = str_replace(';', ", ", $pool['receivers']);
                $content['type']        = TRANSLATE_POOL_TYPE($pool['data_type']);
                $content['frametester'] = FRAMETESTER($pool['url']);
                $content['url']         = COMPILE_CODE($pool['url']);
@@ -180,7 +180,7 @@ if (SQL_NUMROWS($result_list) > 0) {
        SQL_FREERESULT($result_list);
 
        // Add navigation (with change box and colspan=3)
-       $content['nav'] = "";
+       $content['nav'] = '';
        if ($PAGES > 1) $content['nav'] = ADD_EMAIL_NAV($PAGES, getConfig('mails_page'), false, "3", true);
 
        // Prepare content
@@ -191,20 +191,20 @@ if (SQL_NUMROWS($result_list) > 0) {
        LOAD_TEMPLATE("admin_list_emails", false, $content);
 
        $MAIL = true;
-       if ((EXT_IS_ACTIVE("bonus")) && ($WHO == _ALL)) {
+       if ((EXT_IS_ACTIVE('bonus')) && ($WHO == _ALL)) {
                // Check only if bonus extension is active
                if (SQL_NUMROWS($result_bonus) > 0) OUTPUT_HTML("<br /><br />");
        }
 }
 
-if ((EXT_IS_ACTIVE("bonus")) && ($WHO == _ALL)) {
+if ((EXT_IS_ACTIVE('bonus')) && ($WHO == _ALL)) {
        // Load bonus mails only when extension is active
        if (SQL_NUMROWS($result_bonus) > 0) {
                // Calculate pages
                $PAGES = round(SQL_NUMROWS($result_bonus) / getConfig('mails_page') + 0.5);
 
                // List emails
-               $OUT = ""; $content = array();
+               $OUT = ''; $content = array();
                while ($bonus = SQL_FETCHARRAY($result_bonus)) {
                        // Calculate unconfirmed emails
                        $bonus['unconfirmed'] = $bonus['mails_sent'] - $bonus['clicks'];
@@ -219,7 +219,7 @@ if ((EXT_IS_ACTIVE("bonus")) && ($WHO == _ALL)) {
                        $content = $bonus;
                        $content['time']        = CREATE_FANCY_TIME($content['time']);
                        $content['category']    = GET_CATEGORY($content['cat_id']);
-                       $content['receivers']   = str_replace(";", ", ", $content['receivers']);
+                       $content['receivers']   = str_replace(';', ", ", $content['receivers']);
                        $content['type']        = TRANSLATE_POOL_TYPE($content['data_type']);
                        $content['frametester'] = FRAMETESTER($content['url']);
                        $content['timestamp']   = MAKE_DATETIME($content['timestamp'], "0");
@@ -229,7 +229,7 @@ if ((EXT_IS_ACTIVE("bonus")) && ($WHO == _ALL)) {
                } // END - while
 
                // Add navigation (without change box but with colspan=3)
-               $content['nav'] = "";
+               $content['nav'] = '';
                if ($PAGES > 1) $content['nav'] = ADD_EMAIL_NAV($PAGES, getConfig('mails_page'), false, "3", true);
 
                // Prepare content
@@ -243,7 +243,7 @@ if ((EXT_IS_ACTIVE("bonus")) && ($WHO == _ALL)) {
 
 if (!$MAIL) {
        // No mail orders fond
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NO_MAILS_IN_POOL'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NO_MAILS_IN_POOL'));
 } // END - if
 
 //
index c000bba6a637bdf4446887a3f3ff71df659e7781..22e7a9f0a3858981e8ab1dbdbe023bee991b20ae 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 //
 ?>
index 43aea000f5c117d08ad20b6f45d98af6a1cc5aaf..a659a9194faf569df980cb53c2cfed877a6b766c 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Normally we want the overview of all registered extensions
 $do = "overview";
@@ -52,18 +52,18 @@ if (REQUEST_ISSET_POST('sel')) $SEL = SELECTION_COUNT(REQUEST_POST('sel'));
 
 if (REQUEST_ISSET_GET(('reg_ext'))) {
        // We are about to register a new extension
-       $do = "register"; $ext_id = bigintval(REQUEST_GET('reg_ext'));
+       $do = 'register'; $ext_id = bigintval(REQUEST_GET('reg_ext'));
        // The ID comes from task management and it is - of course - *not* the extension's name!
 } elseif ((REQUEST_ISSET_POST('change')) && ($SEL > 0) && (!IS_DEMO())) {
        // De-/activate extensions
        foreach (REQUEST_POST('sel') as $ext_id => $active) {
                // Shall we keep the extension always active?
-               if ((isset($GLOBALS['cache_array']['active_extensions'][GET_EXT_NAME($ext_id)])) && ($GLOBALS['cache_array']['active_extensions'][GET_EXT_NAME($ext_id)] == "Y") && ($active == "N")) {
+               if ((isset($GLOBALS['cache_array']['active_extensions'][GET_EXT_NAME($ext_id)])) && ($GLOBALS['cache_array']['active_extensions'][GET_EXT_NAME($ext_id)] == 'Y') && ($active == 'N')) {
                        // Keep this extension active!
                } else {
                        // De/activate extension
-                       $ACT = "N"; $EXT_LOAD_MODE = "deactivate";
-                       if ($active == "N") { $ACT = "Y"; $EXT_LOAD_MODE = "activate"; }
+                       $ACT = "N"; $EXT_LOAD_MODE = 'deactivate';
+                       if ($active == 'N') { $ACT = "Y"; $EXT_LOAD_MODE = 'activate'; }
                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_extensions` SET ext_active='".$ACT."' WHERE id=%s AND ext_active='%s' LIMIT 1",
                                array(bigintval($ext_id), $active), __FILE__, __LINE__);
 
@@ -83,13 +83,13 @@ if (REQUEST_ISSET_GET(('reg_ext'))) {
                        // Change this extension?
                        if ($sel == 1) {
                                // Load mode is modify
-                               $EXT_LOAD_MODE = "modify";
+                               $EXT_LOAD_MODE = 'modify';
 
                                // Get entry for 'active'
                                $active = REQUEST_POST('active', $ext_id);
 
                                // Update extension's record
-                               if (GET_EXT_VERSION("sql_patches") >= "0.0.6") {
+                               if (GET_EXT_VERSION('sql_patches') >= '0.0.6') {
                                        // Update also CSS column when extensions sql_patches is newer or exact v0.0.6
                                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_extensions` SET ext_has_css='%s', ext_active='%s' WHERE id=%s LIMIT 1",
                                                array(REQUEST_POST('css', $ext_id), $active, $ext_id), __FILE__, __LINE__);
@@ -101,8 +101,8 @@ if (REQUEST_ISSET_GET(('reg_ext'))) {
 
                                // Run SQLs on activation / deactivation
                                switch ($active) {
-                                       case "Y": $EXT_LOAD_MODE = "activate";   break;
-                                       case "N": $EXT_LOAD_MODE = "deactivate"; break;
+                                       case 'Y': $EXT_LOAD_MODE = 'activate';   break;
+                                       case 'N': $EXT_LOAD_MODE = 'deactivate'; break;
                                }
 
                                // Run embeded SQL commands
@@ -111,15 +111,15 @@ if (REQUEST_ISSET_GET(('reg_ext'))) {
                }
 
                // Extensions changed
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_EXT_CHANGED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_EXT_CHANGED'));
        } else {
                // Edit selected entries
-               $SW = "2"; $OUT = "";
+               $SW = "2"; $OUT = '';
                foreach (REQUEST_POST('sel') as $ext_id => $sel) {
                        // Edit this extension?
-                       if (($sel == "Y") || ($sel == "N")) {
+                       if (($sel == 'Y') || ($sel == 'N')) {
                                // Load required data
-                               if (GET_EXT_VERSION("sql_patches") >= "0.0.6") {
+                               if (GET_EXT_VERSION('sql_patches') >= '0.0.6') {
                                        $result = SQL_QUERY_ESC("SELECT ext_name, ext_has_css, ext_active FROM `{!_MYSQL_PREFIX!}_extensions` WHERE id=%s LIMIT 1",
                                         array(bigintval($ext_id)), __FILE__, __LINE__);
                                        list($name, $css, $active) = SQL_FETCHROW($result);
@@ -134,14 +134,14 @@ if (REQUEST_ISSET_GET(('reg_ext'))) {
 
                                // Output row
                                $cssSelection = "---";
-                               if (GET_EXT_VERSION("sql_patches") >= "0.0.6") $cssSelection = ADD_SELECTION("yn", $css, "css", $ext_id);
+                               if (GET_EXT_VERSION('sql_patches') >= '0.0.6') $cssSelection = ADD_SELECTION("yn", $css, "css", $ext_id);
 
                                // Prepare data for the row template
                                $content = array(
                                        'sw'     => $SW,
                                        'id'     => $ext_id,
                                        'name'   => $name,
-                                       'active' => ADD_SELECTION("yn", $active, "active", $ext_id),
+                                       'active' => ADD_SELECTION("yn", $active, 'active', $ext_id),
                                        'css'    => $cssSelection,
                                );
 
@@ -160,10 +160,10 @@ if (REQUEST_ISSET_GET(('reg_ext'))) {
        }
 } elseif ((REQUEST_ISSET_POST('delete')) && ($SEL > 0) && (!IS_DEMO())) {
        // List extensions and when verbose is enabled SQL statements which will be executed
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('sel') as $ext_id => $sel) {
                // Init variables
-               $VERBOSE_OUT = "";
+               $VERBOSE_OUT = '';
                INIT_SQLS();
 
                // Secure id number
@@ -172,9 +172,9 @@ if (REQUEST_ISSET_GET(('reg_ext'))) {
                // Get extension name
                $ext_name = GET_EXT_NAME($ext_id);
 
-               if (getConfig('verbose_sql') == "Y") {
+               if (getConfig('verbose_sql') == 'Y') {
                        // Load SQL commands in remove mode
-                       if (LOAD_EXTENSION($ext_name, "remove", "", true)) {
+                       if (LOAD_EXTENSION($ext_name, 'remove', '', true)) {
                                // Generate extra table with loaded SQL commands
                                $VERBOSE_OUT = EXTENSION_VERBOSE_TABLE();
                        } // END - if
@@ -211,7 +211,7 @@ if (REQUEST_ISSET_GET(('reg_ext'))) {
                        runFilterChain('extension_remove', GET_EXT_NAME($ext_id));
 
                        // Run embeded SQL commands
-                       EXTENSION_RUN_SQLS($ext_id, "remove");
+                       EXTENSION_RUN_SQLS($ext_id, 'remove');
                } // END - if
        } // END - foreach
 } elseif ((REQUEST_ISSET_GET('do')) && (!IS_DEMO())) {
@@ -219,11 +219,11 @@ if (REQUEST_ISSET_GET(('reg_ext'))) {
        $do = SQL_ESCAPE(strip_tags(REQUEST_GET('do')));
 } elseif (REQUEST_ISSET_GET('do')) {
        // Demo mode active!
-       $do = "demo";
+       $do = 'demo';
 }
 
 // Shall we display active/inactive extensions?
-$where = "";
+$where = '';
 if (REQUEST_ISSET_GET(('active'))) {
        $where = sprintf("WHERE ext_active = '%s'", SQL_ESCAPE(strip_tags(REQUEST_GET('active'))));
 } // END - if
@@ -231,7 +231,7 @@ if (REQUEST_ISSET_GET(('active'))) {
 // Case selection
 switch ($do) {
 case "overview": // List all registered extensions
-       if (GET_EXT_VERSION("sql_patches") >= "0.0.6") {
+       if (GET_EXT_VERSION('sql_patches') >= '0.0.6') {
                // Load extension data with CSS informations
                $result = SQL_QUERY("SELECT id AS ext_id, ext_name, ext_active, ext_has_css AS ext_css, ext_version
 FROM `{!_MYSQL_PREFIX!}_extensions`
@@ -248,11 +248,11 @@ ORDER BY ext_name", __FILE__, __LINE__);
        // Are there some entries?
        if (SQL_NUMROWS($result) > 0) {
                // Extensions are registered
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Prepare CSS selection output
                        $cssSelection = "---";
-                       if (GET_EXT_VERSION("sql_patches") >= "0.0.6") $cssSelection = TRANSLATE_YESNO($content['ext_css']);
+                       if (GET_EXT_VERSION('sql_patches') >= '0.0.6') $cssSelection = TRANSLATE_YESNO($content['ext_css']);
 
                        // Prepare data for the row template
                        $content = array(
@@ -280,11 +280,11 @@ ORDER BY ext_name", __FILE__, __LINE__);
                LOAD_TEMPLATE("admin_extensions");
        } else {
                // No extensions are registered
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NO_EXTENSION_REGISTERED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NO_EXTENSION_REGISTERED'));
        }
        break;
 
-case "register": // Register new extension
+case 'register': // Register new extension
        $result = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_task_system` WHERE assigned_admin=%s AND task_type='EXTENSION' LIMIT 1",
                array(GET_CURRENT_ADMIN_ID()), __FILE__, __LINE__);
        $task_found = SQL_NUMROWS($result);
@@ -307,17 +307,17 @@ case "register": // Register new extension
                        $ext_name = trim(substr($subj, 1, strpos($subj, ":") - 1));
 
                        // Test the extension for deprecation
-                       LOAD_EXTENSION($ext_name, "test");
+                       LOAD_EXTENSION($ext_name, 'test');
 
                        // Is the extension deprecated?
-                       if (EXT_GET_DEPRECATED() == "N") {
+                       if (EXT_GET_DEPRECATED() == 'N') {
                                // ... so we can finally register and load it in registration mode
                                if (REGISTER_EXTENSION($ext_name, $ext_id)) {
                                        // Extension was found and successfully registered
-                                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_EXTENSION_REGISTERED'));
+                                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_EXTENSION_REGISTERED'));
 
                                        // Show next link
-                                       if (EXT_IS_ACTIVE("task")) {
+                                       if (EXT_IS_ACTIVE('task')) {
                                                LOAD_TEMPLATE("admin_next_link", false, array(
                                                        'url'   => "modules.php?module=admin&amp;what=list_task",
                                                        'title' => getMessage('ADMIN_EXT_REGISTER_NEXT_LINK')
@@ -330,7 +330,7 @@ case "register": // Register new extension
                                        }
 
                                        // Do we need to update cache file?
-                                       if ((EXT_IS_ACTIVE("cache")) && ($GLOBALS['cache_mode'] != "no")) {
+                                       if ((EXT_IS_ACTIVE('cache')) && ($GLOBALS['cache_mode'] != "no")) {
                                                // Remove cache file (will be auto-created again!)
                                                if ($GLOBALS['cache_instance']->loadCacheFile("config")) $GLOBALS['cache_instance']->destroyCacheFile();
                                                if ($GLOBALS['cache_instance']->loadCacheFile("extensions", true)) $GLOBALS['cache_instance']->destroyCacheFile();
@@ -338,30 +338,30 @@ case "register": // Register new extension
                                        } // END - if
                                } elseif (GET_EXT_VERSION($ext_name) != "") {
                                        // Notify the admin that we have a problem here...
-                                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_REG_FAILED_ALREADY'));
+                                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_REG_FAILED_ALREADY'));
                                } else {
                                        // Notify the admin that we have a problem here...
-                                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_REG_FAILED_404'), $ext_name));
+                                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_REG_FAILED_404'), $ext_name));
                                }
                        } else {
                                // Motify the admin that we have a problem here...
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_REG_FAILED_DEPRECATED'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_REG_FAILED_DEPRECATED'));
                        }
                } else {
                        // Extension was not found in task management
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_REG_FAILED_ID_404'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_REG_FAILED_ID_404'));
                }
        } elseif ($task_found == "0") {
                // No longer assigned or old task
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_REG_FAILED_ASSIGED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_REG_FAILED_ASSIGED'));
        } else {
                // ID is invalid
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_REG_FAILED_INVALID'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_REG_FAILED_INVALID'));
        }
        break;
 
-case "demo":
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_NOT_SAVED'));
+case 'demo':
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_NOT_SAVED'));
        break;
 }
 //
index 6cc9d0b23d56b621aa7ec32b8b6a51224988bd7f..840fcb721358d4bb665ca683b4be0446a7546447 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Check if the admin has entered title and what-php file name...
 if (((!REQUEST_ISSET_POST(('title'))) || (!REQUEST_ISSET_POST(('menu')))) && (IS_FORM_SENT())) {
@@ -75,7 +75,7 @@ if (!IS_FORM_SENT()) {
 
                // Remove double eintries
                // @TODO This can be somehow rewritten to a function
-               $prev = ""; $dmy = $menus; $dmy2 = $titles; $dmy3 = $below;
+               $prev = ''; $dmy = $menus; $dmy2 = $titles; $dmy3 = $below;
                foreach ($menus as $key => $value) {
                        if ($value == $prev) {
                                unset($dmy[$key]);
@@ -120,7 +120,7 @@ WHERE `action`='%s' AND `what` != '' AND `what` IS NOT NULL ORDER BY `sort`",
 
                                // Remove double eintries
                                // @TODO This can be somehow rewritten to a function
-                               $prev = ""; $dmy = $menus[$value_main]; $dmy2 = $titles[$value_main]; $dmy3 = $below[$value_main];
+                               $prev = ''; $dmy = $menus[$value_main]; $dmy2 = $titles[$value_main]; $dmy3 = $below[$value_main];
                                foreach ($menus[$value_main] as $key => $value) {
                                        if ($value == $prev) {
                                                unset($dmy[$key]);
@@ -164,8 +164,8 @@ WHERE `action`='%s' AND `what` != '' AND `what` IS NOT NULL ORDER BY `sort`",
        $OUT .= "</select>";
 
        define('__BELOW_SELECTION' , $OUT);
-       define('__WHAT_SELECTION'  , ADMIN_MAKE_MENU_SELECTION("guest", "what", "name"));
-       define('__ACTION_SELECTION', ADMIN_MAKE_MENU_SELECTION("guest", "action", "menu"));
+       define('__WHAT_SELECTION'  , ADMIN_MAKE_MENU_SELECTION('guest', "what", "name"));
+       define('__ACTION_SELECTION', ADMIN_MAKE_MENU_SELECTION('guest', "action", "menu"));
 
        // Display form
        LOAD_TEMPLATE("admin_guest_add");
@@ -191,10 +191,10 @@ WHERE `action`='%s' AND `what` != '' AND `what` IS NOT NULL ORDER BY `sort`",
        REQUEST_POST('active'),
 ), __FILE__, __LINE__);
        }
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_SAVED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_SAVED'));
 } else {
        // Demo mode!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_NOT_SAVED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_NOT_SAVED'));
 }
 
 //
index a0136ee33c7927c561882d8bed4cfed69aa481d3..94b1147629524e4abcc9919fd87f001cb2f032e8 100644 (file)
@@ -43,14 +43,14 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Do we edit/delete/change main menus or sub menus?
-$AND = "(`what` = '' OR `what` IS NULL)"; $SUB = "";
+$AND = "(`what` = '' OR `what` IS NULL)"; $SUB = '';
 
-if (REQUEST_ISSET_GET(('sub'))) {
-       $AND = sprintf("`action`='%s' AND `what` IS NOT NULL", REQUEST_GET(('sub')));
-       $SUB = REQUEST_GET(('sub'));
+if (REQUEST_ISSET_GET('sub')) {
+       $AND = sprintf("`action`='%s' AND `what` IS NOT NULL", REQUEST_GET('sub'));
+       $SUB = REQUEST_GET('sub');
 } // END - if
 
 // Get count of (maybe) selected menu points
@@ -64,7 +64,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO()))
        define('__SUB_VALUE', $SUB);
        define('__CHK_VALUE', $chk);
 
-       $cnt = 0; $OUT = ""; $SW = 2;
+       $cnt = 0; $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('sel') as $sel => $confirm)
        {
                if ($confirm == 1)
@@ -80,8 +80,8 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO()))
                                $DATA = array(
                                        'cnt'    => $cnt,
                                        'sel'    => $sel,
-                                       'action' => ADMIN_MAKE_MENU_SELECTION("guest", "action", "sel_action[".$sel."]", $act),
-                                       'what'   => ADMIN_MAKE_MENU_SELECTION("guest", "what", "sel_what[".$sel."]", $wht),
+                                       'action' => ADMIN_MAKE_MENU_SELECTION('guest', "action", "sel_action[".$sel."]", $act),
+                                       'what'   => ADMIN_MAKE_MENU_SELECTION('guest', "what", "sel_what[".$sel."]", $wht),
                                        'menu'   => $menu,
                                        'sw'     => $SW,
                                );
@@ -109,7 +109,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO()))
        define('__SUB_VALUE', $SUB);
        define('__CHK_VALUE', $chk);
 
-       $cnt = 0; $OUT = ""; $SW = 2;
+       $cnt = 0; $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('sel') as $sel => $confirm) {
                if ($confirm == 1) {
                        $cnt++;
@@ -155,7 +155,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO()))
                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `title`='%s', `action`='%s', `what`='%s' WHERE ".$AND." AND id=%s LIMIT 1",
                                array($menu, REQUEST_POST('sel_action', $sel), REQUEST_POST('sel_what', $sel), $sel),__FILE__, __LINE__);
                }
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_SAVED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_SAVED'));
                break;
 
        case "del": // Delete menu
@@ -164,7 +164,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO()))
                        SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_guest_menu` WHERE ".$AND." AND id=%s LIMIT 1",
                                array(bigintval($sel)), __FILE__, __LINE__);
                }
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_SAVED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_SAVED'));
                break;
 
        case "status": // Change access levels
@@ -176,7 +176,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO()))
                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_guest_menu` SET `visible`='%s', `locked`='%s' WHERE ".$AND." AND id=%s LIMIT 1",
                                array(REQUEST_POST('visible', $sel), REQUEST_POST('locked', $sel), $sel), __FILE__, __LINE__);
                }
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_SAVED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_SAVED'));
                break;
 
        default: // Unexpected action
@@ -191,7 +191,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO()))
        define('__CHK_VALUE', $chk);
 
        // Load template
-       $SW = 2; $cnt = 0; $OUT = "";
+       $SW = 2; $cnt = 0; $OUT = '';
        foreach (REQUEST_POST('sel') as $sel => $confirm)
        {
                if ($confirm == 1)
@@ -287,7 +287,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO()))
                // Init variables
                $SW = 2;
                $cnt = 0;
-               $OUT = "";
+               $OUT = '';
 
                // Process all menu entries
                while ($content = SQL_FETCHARRAY($result)) {
@@ -314,7 +314,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO()))
                                'what'   => $content['what'],
                                'title'  => $content['title'],
                                'navi'   => $NAVI,
-                               'mode'   => "guest"
+                               'mode'   => 'guest'
                        );
                        $OUT .= LOAD_TEMPLATE("admin_menu_overview_row", true, $content);
                        $SW = 3 - $SW;
@@ -328,7 +328,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO()))
                LOAD_TEMPLATE("admin_gmenu_edit");
        } else {
                // Menu entries are missing... (???)
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NO_MENUS_FOUND'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NO_MENUS_FOUND'));
        }
 }
 
index 2d294d24bbdb73a6d15b5bbf7a0289d63fd30ed7..098a4809d5586693de17032ab72c6414e8fcad11 100644 (file)
@@ -42,7 +42,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        require($INC);
 }
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 //
 ?>
index c6e00caea942d0955611337f0c3c3a8cec5e4012..826c8434d88945f20beea2e85482db5089f10a99 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 //
 ?>
index e21138a8b667a65febe83ba49dd9c31fade277ee..58698e656643edd127a3f23d6514a007b7627213 100644 (file)
@@ -43,20 +43,20 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Exclude default referal id if set
-$EXCLUDE_LIST = "";
+$EXCLUDE_LIST = '';
 if (getConfig('def_refid') > 0) {
        $EXCLUDE_LIST = " AND d.userid != ".getConfig('def_refid')."";
 } // END - if
 
 // Check for more extensions
 // @TODO Rewrite those lines to filter
-if (EXT_IS_ACTIVE("beg"))                  $EXCLUDE_LIST .= " AND d.userid != ".getConfig('beg_uid')."";
-if (EXT_IS_ACTIVE("bonus"))                $EXCLUDE_LIST .= " AND d.userid != ".getConfig('bonus_uid')."";
-if (EXT_IS_ACTIVE("doubler"))              $EXCLUDE_LIST .= " AND d.userid != ".getConfig('doubler_uid')."";
-if (GET_EXT_VERSION("holiday") >= "0.1.3") $EXCLUDE_LIST .= " AND d.holiday_active='N'";
+if (EXT_IS_ACTIVE('beg'))                  $EXCLUDE_LIST .= " AND d.userid != ".getConfig('beg_uid')."";
+if (EXT_IS_ACTIVE('bonus'))                $EXCLUDE_LIST .= " AND d.userid != ".getConfig('bonus_uid')."";
+if (EXT_IS_ACTIVE('doubler'))              $EXCLUDE_LIST .= " AND d.userid != ".getConfig('doubler_uid')."";
+if (GET_EXT_VERSION('holiday') >= '0.1.3') $EXCLUDE_LIST .= " AND d.holiday_active='N'";
 
 // Check for all accounts
 $result = SQL_QUERY_ESC("SELECT DISTINCT d.userid, d.gender, d.surname, d.family, d.email, d.joined, d.last_online, d.ap_notified
@@ -72,7 +72,7 @@ ORDER BY d.userid",
 
 if (SQL_NUMROWS($result) > 0) {
        // Ok, we have found some inactive accounts
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Prepare data for the row template
                // @TODO Rewritings: sname->surname,fname->family in templates
@@ -102,7 +102,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("admin_list_autopurge");
 } else {
        // All members are active or you don't have any registered
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_AUTOPURGE_ALL_ACTIVE'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_AUTOPURGE_ALL_ACTIVE'));
 }
 
 //
index c2f6fa63fbbd790fdfa1bafbc52a8a8a014fb956..3f140f33dbbf78bf1df95ee0a907910cbbe990a0 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 } // END - if
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Check if there is enougth selected
 $show = true;
@@ -58,8 +58,8 @@ if ((REQUEST_ISSET_POST(('id'))) && (is_array(REQUEST_POST('id'))) && (count(REQ
                        REQUEST_POST('id'),
                        "bank_packages",
                        array("id", "title", "description", "account_fee", "free_transfers", "transfer_fee", "output_system_mode", "package_active", "free_months_no_fee", "interest_plus", "interest_minus", "first_payment", "free_account_income", "free_account_stuff", "tan_lock"),
-                       array("bigintval", "", "", "TRANSLATE_COMMA", "bigintval", "TRANSLATE_COMMA", "", "", "bigintval", "TRANSLATE_COMMA", "TRANSLATE_COMMA", "TRANSLATE_COMMA", "TRANSLATE_COMMA", "", "bigintval"),
-                       array("", "", "", "", "", "", "", "", "", "", "", "", "", "", "")
+                       array("bigintval", '', '', "TRANSLATE_COMMA", "bigintval", "TRANSLATE_COMMA", '', '', "bigintval", "TRANSLATE_COMMA", "TRANSLATE_COMMA", "TRANSLATE_COMMA", "TRANSLATE_COMMA", '', "bigintval"),
+                       array("", '', '', '', '', '', '', '', '', '', '', '', '', '', '')
                );
                $show = false;
        } elseif (REQUEST_ISSET_POST(('do_edit'))) {
@@ -67,7 +67,7 @@ if ((REQUEST_ISSET_POST(('id'))) && (is_array(REQUEST_POST('id'))) && (count(REQ
                ADMIN_EDIT_ENTRIES_CONFIRM(REQUEST_POST('id'), "bank_packages", array(), array(), array(), true);
        } elseif (REQUEST_ISSET_POST('delete')) {
                // Delete entries (with confirmation)
-               ADMIN_DELETE_ENTRIES_CONFIRM(REQUEST_POST('id'), "bank_packages", array("id", "title", "description", "account_fee"), array("bigintval", "", "", "TRANSLATE_COMMA"), array("", "", "", ""));
+               ADMIN_DELETE_ENTRIES_CONFIRM(REQUEST_POST('id'), "bank_packages", array("id", "title", "description", "account_fee"), array("bigintval", '', '', "TRANSLATE_COMMA"), array("", '', '', ''));
                $show = false;
        } elseif (REQUEST_ISSET_POST('remove')) {
                // Delete entries (with confirmation)
@@ -86,7 +86,7 @@ ORDER BY `id`", __FILE__, __LINE__);
 // Is there at lease one package?
 if (SQL_NUMROWS($result) > 0) {
        // List all packages
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // "Translate" some data
                $content['active'] = TRANSLATE_YESNO($content['active']);
@@ -107,7 +107,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("admin_list_bank_package");
 } else {
        // No packages found!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_BANK_NO_PACKAGES_FOUND'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_BANK_NO_PACKAGES_FOUND'));
 }
 
 // Free the result
index 7bb2df327c1fd13baee35c7198e03b7d9d4f2fa7..a26f7262a4889b93494b8c5a21a71b4b6b1d158f 100644 (file)
@@ -42,21 +42,21 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        require($INC);
 }
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
-if (getConfig('beg_rallye') == "Y") {
+if (getConfig('beg_rallye') == 'Y') {
        // Shall I withdraw now?
        if (REQUEST_ISSET_POST(('withdraw'))) {
                // Okay, let's prepare...
                $curr = date("m", time()) - 1;
                if (strlen($curr) == 1) $curr = "0".$curr;
                UPDATE_CONFIG("last_month", $curr);
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_BEG_WITHDRAW_PREPARED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_BEG_WITHDRAW_PREPARED'));
        } // END - if
 
        // Autopurge installed?
-       $lastOnline = "%s"; $ONLINE = "";
-       if (EXT_IS_ACTIVE("autopurge")) {
+       $lastOnline = "%s"; $ONLINE = '';
+       if (EXT_IS_ACTIVE('autopurge')) {
                // Use last online timestamp to keep inactive members away from here
                $lastOnline   = " AND last_online >= (UNIX_TIMESTAMP() - %s)";
                $ONLINE = getConfig('ap_inactive_since');
@@ -71,10 +71,10 @@ ORDER BY beg_points DESC, last_online DESC, userid",
 
        if (SQL_NUMROWS($result) > 0) {
                // List users
-               $OUT = "";$SW = 2; $cnt = 1; $total = 0;
+               $OUT = '';$SW = 2; $cnt = 1; $total = 0;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Init variables
-                       $WIN1 = ""; $WIN2 = "";
+                       $WIN1 = ''; $WIN2 = '';
                        if ($cnt <= getConfig('beg_ranks')) {
                                // Maybe he can win his active beg?
                                $WIN1 = "<strong>";
@@ -115,21 +115,21 @@ ORDER BY beg_points DESC, last_online DESC, userid",
                }
 
                // Prepare constant for timemark
-               if (EXT_IS_ACTIVE("autopurge")) {
+               if (EXT_IS_ACTIVE('autopurge')) {
                        define('__AUTOPURGE_TIMEOUT', MAKE_DATETIME(time() - getConfig('ap_inactive_since'), "2"));
                } else {
-                       define('__AUTOPURGE_TIMEOUT', sprintf(getMessage('EXTENSION_PROBLEM_NOT_INSTALLED'), "autopurge"));
+                       define('__AUTOPURGE_TIMEOUT', sprintf(getMessage('EXTENSION_PROBLEM_NOT_INSTALLED'), 'autopurge'));
                }
 
                // Load final template
                LOAD_TEMPLATE("admin_list_beg");
        } else {
                // No one has joined the begging rallye...
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_BEG_NO_RALLYE'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_BEG_NO_RALLYE'));
        }
 } else {
        // Rallye deactivated
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_BEG_RALLYE_DEACTIVATED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_BEG_RALLYE_DEACTIVATED'));
 }
 
 //
index 37786312a1a2c900ae8717634c4cd4cbba586ba8..de9ce4083e5ac286353e1a1215722fe016c5a8d4 100644 (file)
@@ -43,26 +43,26 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
-if (getConfig('bonus_active') == "Y") {
+if (getConfig('bonus_active') == 'Y') {
        // Shall I withdraw now?
        if (REQUEST_ISSET_POST(('withdraw'))) {
                // Okay, let's prepare...
                $curr = date("m", time()) - 1;
                if (strlen($curr) == 1) $curr = "0".$curr;
                UPDATE_CONFIG("last_month", $curr);
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_BONUS_WITHDRAW_PREPARED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_BONUS_WITHDRAW_PREPARED'));
        }
 
-       if (GET_EXT_VERSION("bonus") >= "0.6.9") {
+       if (GET_EXT_VERSION('bonus') >= '0.6.9') {
                // Add more bonus points here
                $USE = "(0";
-               if (getConfig('bonus_click_yn') == "Y") $USE .= " + turbo_bonus";
-               if (getConfig('bonus_login_yn') == "Y") $USE .= " + login_bonus";
-               if (getConfig('bonus_order_yn') == "Y") $USE .= " + bonus_order";
-               if (getConfig('bonus_stats_yn') == "Y") $USE .= " + bonus_stats";
-               if (getConfig('bonus_ref_yn')   == "Y") $USE .= " + bonus_ref";
+               if (getConfig('bonus_click_yn') == 'Y') $USE .= " + turbo_bonus";
+               if (getConfig('bonus_login_yn') == 'Y') $USE .= " + login_bonus";
+               if (getConfig('bonus_order_yn') == 'Y') $USE .= " + bonus_order";
+               if (getConfig('bonus_stats_yn') == 'Y') $USE .= " + bonus_stats";
+               if (getConfig('bonus_ref_yn')   == 'Y') $USE .= " + bonus_ref";
                $USE .= ")";
        } else {
                // Old version ???
@@ -70,8 +70,8 @@ if (getConfig('bonus_active') == "Y") {
        }
 
        // Autopurge installed?
-       $lastOnline = "%s"; $ONLINE = "";
-       if (EXT_IS_ACTIVE("autopurge")) {
+       $lastOnline = "%s"; $ONLINE = '';
+       if (EXT_IS_ACTIVE('autopurge')) {
                // Use last online timestamp to keep inactive members away from here
                $lastOnline   = " AND last_online >= (UNIX_TIMESTAMP() - %s)";
                $ONLINE = getConfig('ap_inactive_since');
@@ -86,13 +86,13 @@ ORDER BY points DESC, last_online DESC, userid",
 
        if (SQL_NUMROWS($result) > 0) {
                // List users
-               $OUT = "";$SW = 2; $cnt = 1; $total = 0;
+               $OUT = '';$SW = 2; $cnt = 1; $total = 0;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Add total points
                        $total += $content['points'];
 
                        // Generate array fore the dynamic template
-                       $WIN1 = ""; $WIN2 = "";
+                       $WIN1 = ''; $WIN2 = '';
                        if ($cnt <= getConfig('bonus_ranks')) {
                                // Maybe he can win his active bonus?
                                $WIN1 = "<strong>";
@@ -127,21 +127,21 @@ ORDER BY points DESC, last_online DESC, userid",
                }
 
                // Prepare constant for timemark
-               if (EXT_IS_ACTIVE("autopurge")) {
+               if (EXT_IS_ACTIVE('autopurge')) {
                        define('__AUTOPURGE_TIMEOUT', MAKE_DATETIME(time() - getConfig('ap_inactive_since'), "2"));
                } else {
-                       define('__AUTOPURGE_TIMEOUT', sprintf(getMessage('EXTENSION_PROBLEM_NOT_INSTALLED'), "autopurge"));
+                       define('__AUTOPURGE_TIMEOUT', sprintf(getMessage('EXTENSION_PROBLEM_NOT_INSTALLED'), 'autopurge'));
                }
 
                // Load final template
                LOAD_TEMPLATE("admin_list_bonus");
        } else {
                // No one has become an "activity bonus"...
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_BONUS_NO_ACTIVE_RALLYE'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_BONUS_NO_ACTIVE_RALLYE'));
        }
 } else {
        // Aktive-Rallye not activated
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_BONUS_RALLYE_DEACTIVATED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_BONUS_RALLYE_DEACTIVATED'));
 }
 
 //
index 5eb2e0fc0b2b38d1a73edf2decfa19c3d9ce6696..268998ec45c13728101c9b86aafb34b7286820cf 100644 (file)
@@ -44,9 +44,9 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
-if (REQUEST_ISSET_GET(('uid'))) {
+if (REQUEST_ISSET_GET('uid')) {
        // Check if the user already exists
        $result = SQL_QUERY_ESC("SELECT surname, family, email FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
                array(bigintval(REQUEST_GET('uid'))), __FILE__, __LINE__);
@@ -66,7 +66,7 @@ if (REQUEST_ISSET_GET(('uid'))) {
 
                if (SQL_NUMROWS($result_cats) > 0) {
                        // List categories
-                       $cnt = 1; $OUT = ""; $SW = 2;
+                       $cnt = 1; $OUT = ''; $SW = 2;
                        while ($content = SQL_FETCHARRAY($result_cats)) {
                                // Check user's selection
                                $result_user = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_user_cats` WHERE userid=%s AND cat_id=%s LIMIT 1",
@@ -100,7 +100,7 @@ if (REQUEST_ISSET_GET(('uid'))) {
                }
        } else {
                // User not found
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_MEMBER_404'), constant('__UID')));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_MEMBER_404'), constant('__UID')));
        }
 } else {
        // Output selection form with all confirmed user accounts listed
index 2a151aa1e7351357f8e4ff4c5efcc217dc3a7a29..4c1e30c5438fd73c467984846b4693babcf2a2d9 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Add new code?
 if ((REQUEST_ISSET_POST(('add'))) && (REQUEST_ISSET_POST(('code'))) && (REQUEST_ISSET_POST(('descr')))) {
@@ -70,7 +70,7 @@ if ((REQUEST_ISSET_POST(('add'))) && (REQUEST_ISSET_POST(('code'))) && (REQUEST_
        }
 
        // Display message
-       LOAD_TEMPLATE("admin_settings_saved", false, $message);
+       LOAD_TEMPLATE('admin_settings_saved', false, $message);
 } elseif ((REQUEST_ISSET_POST('change')) && (REQUEST_ISSET_POST(('id')))) {
        // Change all status
        ADMIN_CHANGE_ACTIVATION_STATUS(REQUEST_POST('id'), "countries", "is_active");
@@ -85,7 +85,7 @@ if ((REQUEST_ISSET_POST(('add'))) && (REQUEST_ISSET_POST(('code'))) && (REQUEST_
                if (REQUEST_ISSET_POST('edit')) {
                        // Edit template
                        $row    = "admin_list_country_edit_row";
-                       $post   = "modify";
+                       $post   = 'modify';
                        $class  = "admin_submit";
                        $submit = getMessage('ADMIN_COUNTRY_EDIT_NOW');
                        $title  = getMessage('ADMIN_COUNTRY_EDIT_TITLE');
@@ -93,15 +93,15 @@ if ((REQUEST_ISSET_POST(('add'))) && (REQUEST_ISSET_POST(('code'))) && (REQUEST_
                } else {
                        // Delete template
                        $row    = "admin_list_country_del_row";
-                       $post   = "remove";
+                       $post   = 'remove';
                        $class  = "admin_delete";
                        $submit = getMessage('ADMIN_COUNTRY_DELETE_NOW');
                        $title  = getMessage('ADMIN_COUNTRY_DELETE_TITLE');
-                       $reset  = "";
+                       $reset  = '';
                }
 
                // Edit all selected country codes
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                foreach (REQUEST_POST('id') as $id => $status) {
                        // Load data from DB
                        $result = SQL_QUERY_ESC("SELECT code, descr FROM `{!_MYSQL_PREFIX!}_countries` WHERE id=%s LIMIT 1",
@@ -119,7 +119,7 @@ if ((REQUEST_ISSET_POST(('add'))) && (REQUEST_ISSET_POST(('code'))) && (REQUEST_
                                        'sw'    => $SW,
                                );
 
-                               if ($post == "modify") {
+                               if ($post == 'modify') {
                                        // Generate default selection in edit-mode
                                        $content['status'] = ADD_OPTION_LINES("/ARRAY/", array("Y","N"), array(YES, NO ), $status);
                                } else {
@@ -144,7 +144,7 @@ if ((REQUEST_ISSET_POST(('add'))) && (REQUEST_ISSET_POST(('code'))) && (REQUEST_
        }
 } else {
        // Shall we modify / remove entries now?
-       $message = ""; INIT_SQLS();
+       $message = ''; INIT_SQLS();
        if ((REQUEST_ISSET_POST(('modify'))) && (REQUEST_ISSET_POST(('id')))) {
                // Modify
                foreach (REQUEST_POST('id') as $id => $sel) {
@@ -167,14 +167,14 @@ if ((REQUEST_ISSET_POST(('add'))) && (REQUEST_ISSET_POST(('code'))) && (REQUEST_
                runFilterChain('run_sqls');
 
                // Display message
-               LOAD_TEMPLATE("admin_settings_saved", false, $message);
+               LOAD_TEMPLATE('admin_settings_saved', false, $message);
        }
 
        // Load currenty setup country codes to list
        $result = SQL_QUERY("SELECT id, code, descr, is_active FROM `{!_MYSQL_PREFIX!}_countries` ORDER BY code", __FILE__, __LINE__);
        if (SQL_NUMROWS($result) > 0) {
                // List all countries
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Prepare array for the template
                        // @TODO Rewritings: name->descr,status->is_active in template
index 48b336cdc603ed2608170e6a0958cb6d236999f0..675bc873f902976e1de750887743175a286da0a1 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (!REQUEST_ISSET_GET(('mode'))) {
        // Chosse the overview page as default
index ee14c8978005769e2c8e6993854a924e80ee1ae0..c5e3d8a4ec676fb0c2ed949e3394e9e862243e7e 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Start listing holiday requests
 $result = SQL_QUERY("SELECT h.id, h.userid, h.holiday_start, h.holiday_end, h.comments, d.status, d.last_online
@@ -54,7 +54,7 @@ ORDER BY h.userid", __FILE__, __LINE__);
 
 if (SQL_NUMROWS($result) > 0) {
        // List all holiday requests
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Add three dashes to comment when it is empty
                if (empty($content['comments'])) $content['comments'] = "---";
@@ -86,7 +86,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("admin_list_holiday");
 } else {
        // No holiday requests found
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('HOLIDAY_ADMIN_NOTHING_FOUND'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('HOLIDAY_ADMIN_NOTHING_FOUND'));
 }
 
 //
index 843b9929dd430d722075acd822da0ecad1fdc724..44ff2a426e7f4b35de44a027c0bd2828f3020921 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("mailid")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "mailid");
+} elseif (!EXT_IS_ACTIVE('mailid')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'mailid');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
-if (!REQUEST_ISSET_GET('del')) REQUEST_SET_GET('del', "");
+if (!REQUEST_ISSET_GET('del')) REQUEST_SET_GET('del', '');
 
-if (REQUEST_ISSET_GET(('uid'))) {
+if (REQUEST_ISSET_GET('uid')) {
        // Check if the user already exists
        $result = SQL_QUERY_ESC("SELECT surname, family, email FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
                array(bigintval(REQUEST_GET('uid'))), __FILE__, __LINE__);
@@ -62,7 +62,7 @@ if (REQUEST_ISSET_GET(('uid'))) {
                SQL_FREERESULT($result);
 
                // Grab user's all unconfirmed mails
-               if (EXT_IS_ACTIVE("bonus")) {
+               if (EXT_IS_ACTIVE('bonus')) {
                        // Load bonus ID
                        $result = SQL_QUERY_ESC("SELECT stats_id, bonus_id, link_type FROM `{!_MYSQL_PREFIX!}_user_links` WHERE userid=%s ORDER BY `id`",
                                array(bigintval(REQUEST_GET('uid'))), __FILE__, __LINE__);
@@ -87,17 +87,17 @@ if (REQUEST_ISSET_GET(('uid'))) {
                                SEND_EMAIL($email, getMessage('ADMIN_DEL_LINK_SUBJ'), $msg);
 
                                // Display message
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_LINKS_DELETED'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_LINKS_DELETED'));
                        } else {
                                // Init variables
-                               $OUT = ""; $SW = 2;
+                               $OUT = ''; $SW = 2;
 
                                // List all unconfirmed mails
                                // @TODO Find a way to rewrite this. See some lines above for different queries
                                while (list($id, $id2, $type) = SQL_FETCHROW($result)) {
                                        // Initializes some variables
-                                       $cat = "";
-                                       $DATA = "";
+                                       $cat = '';
+                                       $DATA = '';
                                        $PROBLEM = getMessage('GENERAL_MAIL_PROBLEM');
                                        $result_data = false; // Closes Bug #58
 
@@ -107,14 +107,14 @@ if (REQUEST_ISSET_GET(('uid'))) {
                                        case "NORMAL":
                                                $result_data = SQL_QUERY_ESC("SELECT subject, timestamp_ordered, cat_id FROM `{!_MYSQL_PREFIX!}_user_stats` WHERE id=%s LIMIT 1",
                                                        array(bigintval($id)), __FILE__, __LINE__);
-                                               $type = "mailid"; $DATA = $id; $PROBLEM = getMessage('NORMAL_MAIL_PROBLEM');
+                                               $type = 'mailid'; $DATA = $id; $PROBLEM = getMessage('NORMAL_MAIL_PROBLEM');
                                                $LINK = "<a href=\"{!URL!}/mailid.php?uid=".REQUEST_GET('uid')."&amp;mailid=".$id."\" target=\"_blank\">".$id."</a>";
                                                break;
 
                                        case "BONUS":
                                                $result_data = SQL_QUERY_ESC("SELECT subject, timestamp, cat_id FROM `{!_MYSQL_PREFIX!}_bonus` WHERE id=%s LIMIT 1",
                                                        array(bigintval($id2)), __FILE__, __LINE__);
-                                               $type = "bonusid"; $DATA = $id2; $PROBLEM = getMessage('BONUS_MAIL_PROBLEM');
+                                               $type = 'bonusid'; $DATA = $id2; $PROBLEM = getMessage('BONUS_MAIL_PROBLEM');
                                                $LINK = "<a href=\"{!URL!}/mailid.php?uid=".REQUEST_GET('uid')."&amp;bonusid=".$id2."\" target=\"_blank\">".$id2."</a>";
                                                break;
 
@@ -170,11 +170,11 @@ if (REQUEST_ISSET_GET(('uid'))) {
                        }
                } else {
                        // No mails left to confirm
-                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_MEMBER_LINKS'), REQUEST_GET('uid')));
+                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_MEMBER_LINKS'), REQUEST_GET('uid')));
                }
        } else {
                // User not found
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid')));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid')));
        }
 } else {
        // Output selection form with all confirmed user accounts listed
index 04e0bc279851a49a0001aa65cb348b9ec92132ff..d57e3e0f8596f2e8d59a4e3c65da68a6eb3a6ebf 100644 (file)
@@ -43,9 +43,9 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
-if ((REQUEST_ISSET_POST(('uid'))) && (REQUEST_ISSET_POST(('id')))) {
+if ((REQUEST_ISSET_POST('uid')) && (REQUEST_ISSET_POST(('id')))) {
        // Update database...
        // First user's account
        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET nl_until=(UNIX_TIMESTAMP() + nl_timespan), nl_receive='N', nl_timespan=0 WHERE userid=%s LIMIT 1",
@@ -59,10 +59,10 @@ if ((REQUEST_ISSET_POST(('uid'))) && (REQUEST_ISSET_POST(('id')))) {
        SEND_EMAIL(bigintval(REQUEST_POST('uid')), NL_MEMBER_DONE_SUBJECT, $msg);
 
        // Output message to admin
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NL_MEMBER_DONE'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NL_MEMBER_DONE'));
 } else {
        // @TODO Currently under construction!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('UNDER_CONSTRUCTION'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('UNDER_CONSTRUCTION'));
 }
 
 //
index 15822a2610fbc3bb2efa64591b445bb82e6a053d..80d14ee9bcf8c3f7cf61aaac95b1a0def75f795f 100644 (file)
@@ -43,17 +43,17 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Init variables
 $WHO = _ALL;
-$SQL2 = "";
+$SQL2 = '';
 
 // Set offset an current page to default values
 if (!REQUEST_ISSET_GET(('page')))   REQUEST_GET('page')   = "1";
 if (!REQUEST_ISSET_GET(('offset'))) REQUEST_SET_GET('offset', getConfig('mails_page'));
 
-if ((EXT_IS_ACTIVE("bonus")) && ($WHO == getMessage('_ALL'))) {
+if ((EXT_IS_ACTIVE('bonus')) && ($WHO == getMessage('_ALL'))) {
        // Bonus mails sent by you
        //               0     1       2        3        4      5       6          7       8      9         10          11        12
        $SQL2 = "SELECT id, subject, text, receivers, points, time, data_type, timestamp, url, cat_id, target_send, mails_sent, clicks
@@ -73,7 +73,7 @@ $add = " LIMIT ".(bigintval(REQUEST_GET('offset')) * bigintval(REQUEST_GET('page
 // Add limitation
 if (!empty($SQL2)) $SQL2 .= $add;
 
-if ((EXT_IS_ACTIVE("bonus")) && (SQL_NUMROWS($result_max) > 0) && (!empty($SQL2))) {
+if ((EXT_IS_ACTIVE('bonus')) && (SQL_NUMROWS($result_max) > 0) && (!empty($SQL2))) {
        // Run SQL query for notification mails
        $result_bonus = SQL_QUERY($SQL2, __FILE__, __LINE__);
 
@@ -83,7 +83,7 @@ if ((EXT_IS_ACTIVE("bonus")) && (SQL_NUMROWS($result_max) > 0) && (!empty($SQL2)
                $PAGES = round(SQL_NUMROWS($result_bonus) / getConfig('mails_page') + 0.5);
 
                // List emails
-               $OUT = ""; $content = array();
+               $OUT = ''; $content = array();
                while ($bonus = SQL_FETCHARRAY($result_bonus)) {
                        // Calculate unconfirmed emails
                        $bonus['unconfirmed'] = $bonus['mails_sent'] - $bonus['clicks'];
@@ -98,7 +98,7 @@ if ((EXT_IS_ACTIVE("bonus")) && (SQL_NUMROWS($result_max) > 0) && (!empty($SQL2)
                        $content = $bonus;
                        $content['time']        = CREATE_FANCY_TIME($content['time']);
                        $content['category']    = GET_CATEGORY($content['cat_id']);
-                       $content['receivers']   = str_replace(";", ", ", $content['receivers']);
+                       $content['receivers']   = str_replace(';', ", ", $content['receivers']);
                        $content['type']        = TRANSLATE_POOL_TYPE($content['data_type']);
                        $content['frametester'] = FRAMETESTER($content['url']);
                        $content['timestamp']   = MAKE_DATETIME($content['timestamp'], "0");
@@ -108,7 +108,7 @@ if ((EXT_IS_ACTIVE("bonus")) && (SQL_NUMROWS($result_max) > 0) && (!empty($SQL2)
                }
 
                // Add navigation (without change box but with colspan=3)
-               $content['nav'] = "";
+               $content['nav'] = '';
                if ($PAGES > 1) $content['nav'] = ADD_EMAIL_NAV($PAGES, getConfig('mails_page'), false, "3", true);
 
                // Prepare content
index cb84d4108295ae48d63233ead062b34e1b877408..03cb3d3457edc8d65f65adb9885178b93ec1a8e4 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (REQUEST_ISSET_GET(('pid'))) {
        // First let's get the member's ID
@@ -62,7 +62,7 @@ if (REQUEST_ISSET_GET(('pid'))) {
                if (empty($task)) $task = 0;
        } elseif ((empty($uid)) || ($uid == "0")) {
                // Cannot obtain member ID!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PAYOUT_FAILED_OBTAIN_USERID'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PAYOUT_FAILED_OBTAIN_USERID'));
        } else {
                // Get task ID from URL
                $task = REQUEST_GET('task');
@@ -138,12 +138,12 @@ if (REQUEST_ISSET_GET(('pid'))) {
                                                $msg = LOAD_EMAIL_TEMPLATE("member_payout_accepted", REQUEST_POST('text'), $uid);
 
                                                // Output message
-                                               if ($allow == "Y") {
+                                               if ($allow == 'Y') {
                                                        // Banner / Textlink request
-                                                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PAYOUT_BANNER_ACCEPTED_NOTIFIED'));
+                                                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PAYOUT_BANNER_ACCEPTED_NOTIFIED'));
                                                } else {
                                                        // Normal request
-                                                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PAYOUT_ACCEPTED_NOTIFIED'));
+                                                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PAYOUT_ACCEPTED_NOTIFIED'));
                                                }
 
                                                // Finally send mail
@@ -155,7 +155,7 @@ if (REQUEST_ISSET_GET(('pid'))) {
                                        }
                                } else {
                                        // Cannot load payout id
-                                       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_failed\">{--PAYOUT_FAILED_OBTAIN_PAYOUT_ID--}</div>");
+                                       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_failed\">{--PAYOUT_FAILED_OBTAIN_PAYOUT_ID--}</div>");
                                }
                        } else {
                                // Prepare content
@@ -183,7 +183,7 @@ if (REQUEST_ISSET_GET(('pid'))) {
                                $msg = LOAD_EMAIL_TEMPLATE("member_payout_rejected", REQUEST_POST('text'), $uid);
 
                                // Output message
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PAYOUT_REJECTED_NOTIFIED'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PAYOUT_REJECTED_NOTIFIED'));
 
                                // Finally send mail
                                SEND_EMAIL($email, getMessage('PAYOUT_REJECTED_SUBJECT'), $msg);
@@ -199,14 +199,14 @@ if (REQUEST_ISSET_GET(('pid'))) {
                        }
                } else {
                        // Cannot load user data
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PAYOUT_FAILED_OBTAIN_USERDATA'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PAYOUT_FAILED_OBTAIN_USERDATA'));
                }
        } elseif ((empty($task)) || ($task == "0")) {
                // Failed loading task ID
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PAYOUT_FAILED_OBTAIN_TASK_ID'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PAYOUT_FAILED_OBTAIN_TASK_ID'));
        }
 } else {
-       if (!REQUEST_ISSET_GET('do')) REQUEST_SET_GET('do', "");
+       if (!REQUEST_ISSET_GET('do')) REQUEST_SET_GET('do', '');
 
        if (REQUEST_GET('do') == "delete") {
                // Delete all requests
@@ -221,7 +221,7 @@ ORDER BY p.payout_timestamp DESC", __FILE__, __LINE__);
 
        if (SQL_NUMROWS($result) > 0) {
                // List found payouts
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHROW($result)) {
                        if ($content['status'] == "NEW") {
                                // Generate links for direct accepting and rejecting
@@ -233,7 +233,7 @@ ORDER BY p.payout_timestamp DESC", __FILE__, __LINE__);
                        }
 
                        // Nothing entered must be secured in member/what-payputs.php !
-                       if ($content['allow'] == "Y") {
+                       if ($content['allow'] == 'Y') {
                                // Banner/Textlink views/clicks request
                                if (!empty($content['banner'])) {
                                        // Load template for the banner
@@ -275,7 +275,7 @@ ORDER BY p.payout_timestamp DESC", __FILE__, __LINE__);
                LOAD_TEMPLATE("admin_list_payouts");
        } else {
                // No payout requests are sent so far
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PAYOUT_ADMIN_NO_REQUESTS_FOUND'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PAYOUT_ADMIN_NO_REQUESTS_FOUND'));
        }
 }
 //
index 546071d59db6342f6cc9293c9cad257205dc8fc4..9a21f9aec3c0ec14929ec09f9563400218211a4b 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Check for entries
 $result = SQL_QUERY("SELECT id, userid, primera_account, primera_amount, primera_timestamp, primera_type, primera_api_message, primera_api_status FROM `{!_MYSQL_PREFIX!}_user_primera` ORDER BY primera_timestamp DESC, id DESC",
@@ -52,7 +52,7 @@ $result = SQL_QUERY("SELECT id, userid, primera_account, primera_amount, primera
 // Are there some entries to display?
 if (SQL_NUMROWS($result) > 0) {
        // List all entries
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Translate some data and add color
                $content['sw']                                  = $SW;
@@ -75,7 +75,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("admin_list_primera_main", false, $OUT);
 } else {
        // Nothing to display!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PRIMERA_ADMIN_NO_TRANSFERS'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PRIMERA_ADMIN_NO_TRANSFERS'));
 }
 
 // Free the result
index d00f43c71cfadcbf95ff8c16cb7991ee837fa896..b5e63e9de02d979c62a6e11e1d6c7592dfacc4ea 100644 (file)
@@ -43,10 +43,10 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
-if (!REQUEST_ISSET_GET(('sub'))) REQUEST_SET_GET('sub', "");
-$message = "";
+if (!REQUEST_ISSET_GET('sub')) REQUEST_SET_GET('sub', '');
+$message = '';
 
 // Quick actions on a rallye
 if (REQUEST_ISSET_GET(('rallye'))) {
@@ -171,7 +171,7 @@ if (REQUEST_ISSET_POST('edit')) {
        $SEL = SELECTION_COUNT(REQUEST_POST('sel'));
        if ($SEL > 0) {
                // Make all selected and deactivated rallyes editable
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                foreach (REQUEST_POST('sel') as $id => $selected) {
                        // Load rallye basic data
                        $result = SQL_QUERY_ESC("SELECT title, descr, template, start_time, end_time, min_users, min_prices
@@ -220,14 +220,14 @@ LIMIT 1",
                LOAD_TEMPLATE("admin_edit_rallyes");
        } else {
                // Nothing selected to edit
-               LOAD_TEMPLATE("admin_settings_saved", false, LOAD_TEMPLATE("admin_list_rallye_noselect", true));
+               LOAD_TEMPLATE('admin_settings_saved', false, LOAD_TEMPLATE("admin_list_rallye_noselect", true));
        }
 } elseif ((REQUEST_GET('sub') == "users") && (REQUEST_GET('rallye') > 0)) {
        // List users and their refs before start and current
        $result = SQL_QUERY_ESC("SELECT userid, refs, curr_points FROM `{!_MYSQL_PREFIX!}_rallye_users` WHERE rallye_id=%s ORDER BY userid",
                array(bigintval(REQUEST_GET('rallye'))), __FILE__, __LINE__);
        if (SQL_NUMROWS($result) > 0) {
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                // @TODO Rewrite this constant
                define('__RALLYE_VALUE', REQUEST_GET('rallye'));
                while ($content = SQL_FETCHARRAY($result)) {
@@ -235,8 +235,8 @@ LIMIT 1",
                        $cnt = RALLYE_GET_REFCOUNT($content['userid'], $content['refs']);
 
                        // Init variables
-                       $bl = "";
-                       $br = "";
+                       $bl = '';
+                       $br = '';
 
                        // Output row
                        if (($content['curr_points'] > 0) && ($cnt > 0)) { $bl = "<strong>"; $br = "</strong>"; }
@@ -248,7 +248,7 @@ LIMIT 1",
                        } // END - if
 
                        // Get user points
-                       $points = GET_TOTAL_DATA($content['userid'], "user_points", "points", "userid", false, " AND ref_depth=1 LIMIT 1");
+                       $points = GET_TOTAL_DATA($content['userid'], "user_points", "points", 'userid', false, " AND ref_depth=1 LIMIT 1");
                        //* DEBUG: */ echo basename(__FILE__).":uid={$content['userid']},points={$points},opoints={$content['curr_points']}<br />\n";
 
                        // Prepare content
@@ -276,7 +276,7 @@ LIMIT 1",
                LOAD_TEMPLATE("admin_list_rallye_usr");
        } else {
                // No entries found?
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('RALLYE_ADMIN_USERS_404'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('RALLYE_ADMIN_USERS_404'));
        }
 } else {
        // Start listing rallyes
@@ -286,7 +286,7 @@ ORDER BY start_time DESC",
                __FILE__, __LINE__);
        if (SQL_NUMROWS($result) > 0) {
                // List found rallyes
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Load admin login
                        $content['alogin'] = GET_ADMIN_LOGIN($content['admin_id']);
@@ -332,14 +332,14 @@ ORDER BY start_time DESC",
                        // Is the rallye active or not?
                        switch ($content['is_active'])
                        {
-                       case "Y":
+                       case 'Y':
                                // Rallye is active so do not edit it!
                                $content['select'] = "<div class=\"big\">".$content['id']."</div>";
                                $content['active_title'] = getMessage('RALLYE_DEACTIVATE_NOW');
                                $content['active'] = 0;
                                break;
 
-                       case "N":
+                       case 'N':
                                $content['active_title'] = getMessage('RALLYE_ACTIVATE_NOW');
                                $content['active'] = "1";
                                break;
@@ -348,12 +348,12 @@ ORDER BY start_time DESC",
                        // Notification to members?
                        switch ($content['send_notify'])
                        {
-                       case "Y":
+                       case 'Y':
                                $content['notify_title'] = getMessage('RALLYE_STOP_NOTIFY_NOW');
                                $content['notify'] = 0;
                                break;
 
-                       case "N":
+                       case 'N':
                                $content['notify_title'] = getMessage('RALLYE_START_NOTIFY_NOW');
                                $content['notify'] = "1";
                                break;
@@ -362,12 +362,12 @@ ORDER BY start_time DESC",
                        // Auto-add of new joined members?
                        switch ($content['auto_add_new_user'])
                        {
-                       case "Y":
+                       case 'Y':
                                $content['auto_title'] = getMessage('RALLYE_STOP_AUTO_ADD_NOW');
                                $content['auto'] = 0;
                                break;
 
-                       case "N":
+                       case 'N':
                                $content['auto_title'] = getMessage('RALLYE_START_AUTO_ADD_NOW');
                                $content['auto'] = "1";
                                break;
@@ -386,7 +386,7 @@ ORDER BY start_time DESC",
                LOAD_TEMPLATE("admin_list_rallyes");
        } else {
                // No rallyes setup so far
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('RALLYE_NO_RALLYES_SETUP'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('RALLYE_NO_RALLYES_SETUP'));
        }
 }
 
index ad5d80972773a0a6fa8999385ff804b5a0c51129..a11337704e272c834c39571312b755dd3e163712 100644 (file)
@@ -44,9 +44,9 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
-if (REQUEST_ISSET_GET(('uid'))) {
+if (REQUEST_ISSET_GET('uid')) {
        // Secure userid
        $uid = bigintval(REQUEST_GET('uid'));
 
@@ -57,7 +57,7 @@ if (REQUEST_ISSET_GET(('uid'))) {
        // User found?
        if (SQL_NUMROWS($result_user) == 1) {
                // Is the refback extension installed?
-               if (EXT_IS_ACTIVE("refback")) {
+               if (EXT_IS_ACTIVE('refback')) {
                        // Load all referal levels
                        $result_levels = SQL_QUERY("SELECT level, percents
 FROM `{!_MYSQL_PREFIX!}_refdepths`
@@ -81,19 +81,19 @@ ORDER BY level ASC", __FILE__, __LINE__);
                                array($uid), __FILE__, __LINE__);
 
                        // Output info message
-                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_USER_TOTAL_REFS'), ADMIN_USER_PROFILE_LINK(REQUEST_GET('uid')), $menge, $menge_lck));
+                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_USER_TOTAL_REFS'), ADMIN_USER_PROFILE_LINK(REQUEST_GET('uid')), $menge, $menge_lck));
                }
 
                // Are there some levels (VERY BAD IF NONE!)
                if (SQL_NUMROWS($result_levels) > 0) {
                        // List all ref levels or entries if no refback is installed
-                       $OUT = ""; $SW = 2;
+                       $OUT = ''; $SW = 2;
                        while ($levels = SQL_FETCHARRAY($result_levels)) {
                                // Insert more data
                                $levels['sw']    = $SW;
 
                                // Is the refback still active? ;-)
-                               if (EXT_IS_ACTIVE("refback")) {
+                               if (EXT_IS_ACTIVE('refback')) {
                                        // Load all refs of this user
                                        $result_refs = SQL_QUERY_ESC("SELECT refid FROM `{!_MYSQL_PREFIX!}_user_refs` WHERE userid=%s AND level='%s' ORDER BY refid ASC",
                                                array($uid, $levels['level']), __FILE__, __LINE__);
@@ -117,7 +117,7 @@ ORDER BY level ASC", __FILE__, __LINE__);
                                                $levels['info'] = sprintf(getMessage('ADMIN_USER_TOTAL_REFS'), ADMIN_USER_PROFILE_LINK($uid), $menge, $menge_lck);
 
                                                // Init variables
-                                               $OUT_REFS = ""; $SW = 2;
+                                               $OUT_REFS = ''; $SW = 2;
 
                                                // Load all refs
                                                while ($content = SQL_FETCHARRAY($result_refs)) {
@@ -223,24 +223,24 @@ ORDER BY level ASC", __FILE__, __LINE__);
                        );
 
                        // Load main template
-                       if (EXT_IS_ACTIVE("refback")) {
+                       if (EXT_IS_ACTIVE('refback')) {
                                LOAD_TEMPLATE("admin_list_refs2", false, $content);
                        } else {
                                LOAD_TEMPLATE("admin_list_refs", false, $content);
                        }
-               } elseif (EXT_IS_ACTIVE("refback")) {
+               } elseif (EXT_IS_ACTIVE('refback')) {
                        // No levels found, very bad!
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NO_REF_LEVELS'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NO_REF_LEVELS'));
                } else {
                        // No refs made so far
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('USER_REF_404'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('USER_REF_404'));
                }
 
                // Free result
                SQL_FREERESULT($result_levels);
        } else {
                // User not found
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid')));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid')));
        }
 
        // Free memory
index da871295e986a001b912852207aa81bcae457608..26e13668fc5f99d1c9ad2dbe9a0cf83b14bfbf84 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (REQUEST_ISSET_GET(('id'))) {
        // Show detailed informations to a sponsor
@@ -115,7 +115,7 @@ WHERE id='%s' LIMIT 1",
                LOAD_TEMPLATE("admin_list_sponsor_details");
        } else {
                // Sponsor not found
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_SPONSOR_404'), REQUEST_GET('id')));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_SPONSOR_404'), REQUEST_GET('id')));
        }
 } elseif (REQUEST_ISSET_GET(('rid'))) {
        // Search for sponsor
@@ -137,11 +137,11 @@ WHERE refid='%s' ORDER BY `id`",
                        SQL_FREERESULT($result);
                } else {
                        // No refs made so far
-                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_SPONSOR_REFS_404'), "<a href=\"{!URL!}/modules.php?module=admin&amp;what=list_sponsor&amp;id=".bigintval(REQUEST_GET('rid'))."\">".bigintval(REQUEST_GET('rid'))."</a>"));
+                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_SPONSOR_REFS_404'), "<a href=\"{!URL!}/modules.php?module=admin&amp;what=list_sponsor&amp;id=".bigintval(REQUEST_GET('rid'))."\">".bigintval(REQUEST_GET('rid'))."</a>"));
                }
        } else {
                // Sponsor not found
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_SPONSOR_404'), bigintval(REQUEST_GET('rid'))));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_SPONSOR_404'), bigintval(REQUEST_GET('rid'))));
        }
 } else {
        // List all sponsors
@@ -149,7 +149,7 @@ WHERE refid='%s' ORDER BY `id`",
 FROM `{!_MYSQL_PREFIX!}_sponsor_data` ORDER BY `id`", __FILE__, __LINE__);
        if (SQL_NUMROWS($result_main) > 0) {
                // At least one sponsor found!
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result_main)) {
                        // Transfer data to array
                        // @TODO Rewritings: sname->surname,fname->family,ip->remote_addr in template
@@ -182,7 +182,7 @@ FROM `{!_MYSQL_PREFIX!}_sponsor_data` ORDER BY `id`", __FILE__, __LINE__);
                LOAD_TEMPLATE("admin_list_sponsor");
        } else {
                // No sponsors registered so far
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SPONSOR_NONE_REGISTERED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SPONSOR_NONE_REGISTERED'));
        }
 }
 
index 72e052d3e3eef5084aca002c96f686b10b637183..9642de00b76d57b107b0c79608b23626dc29f874 100644 (file)
@@ -43,9 +43,9 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
-$message = "";
+$message = '';
 
 if (REQUEST_ISSET_POST(('add'))) {
        // Check input variables
@@ -99,7 +99,7 @@ SET pay_name='%s', pay_rate='%s', pay_min_count='%s', pay_currency='%s' WHERE id
 
        if (!empty($message)) {
                // Output message
-               LOAD_TEMPLATE("admin_settings_saved", false, $message);
+               LOAD_TEMPLATE('admin_settings_saved', false, $message);
        }
 }
 
@@ -128,10 +128,10 @@ if (REQUEST_ISSET_POST(('add'))) {
        }
 
        // Output message
-       LOAD_TEMPLATE("admin_settings_saved", false, $message);
+       LOAD_TEMPLATE('admin_settings_saved', false, $message);
 } elseif ((REQUEST_ISSET_POST('edit')) || (REQUEST_ISSET_POST('del'))) {
        // Load all data
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('id') as $id => $sel) {
                // Load entry
                $result = SQL_QUERY_ESC("SELECT pay_name, pay_rate, pay_min_count, pay_currency FROM `{!_MYSQL_PREFIX!}_sponsor_paytypes` WHERE id='%s' LIMIT 1",
@@ -186,7 +186,7 @@ if (REQUEST_ISSET_POST(('add'))) {
        // Do we have some paytypes setup?
        if (SQL_NUMROWS($result) > 0) {
                // Prepare variables for listing
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
 
                // List alle found payment types
                while ($content = SQL_FETCHARRAY($result)) {
@@ -217,7 +217,7 @@ if (REQUEST_ISSET_POST(('add'))) {
                define('__LIST_CONTENT', LOAD_TEMPLATE("admin_list_sponsor_pay", true));
        } else {
                // Noting setup so far!
-               define('__LIST_CONTENT', LOAD_TEMPLATE("admin_settings_saved", true, getMessage('ADMIN_SPONSOR_NO_PAYTYPES')));
+               define('__LIST_CONTENT', LOAD_TEMPLATE('admin_settings_saved', true, getMessage('ADMIN_SPONSOR_NO_PAYTYPES')));
        }
 
        // Add new payment types here
index da13ab930423c54b7c60bae63984a87248c51db2..d82e191a82a8c7bcc6a6c5dbbf537e6c44065e44 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (REQUEST_ISSET_GET(('id'))) {
        // Check for selected sponsor
@@ -55,11 +55,11 @@ if (REQUEST_ISSET_GET(('id'))) {
                SQL_FREERESULT($result);
        } else {
                // Sponsor not found!
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_SPONSOR_404'), bigintval(REQUEST_GET('id'))));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_SPONSOR_404'), bigintval(REQUEST_GET('id'))));
        }
 } else {
        // Not called by what-list_sponsor.php
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_CALL_NOT_DIRECTLY'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_CALL_NOT_DIRECTLY'));
 }
 
 //
index 4e8a2835ab3bc2c0cf6ea8a8ad1533a3c4ced6cd..6fe3cda2ddab5aea91c3e599a200875bf3fc4d88 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!is_admin())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Load all actions
 $result = SQL_QUERY("SELECT `id`,`status`,`action`,`new_status`
@@ -53,7 +53,7 @@ ORDER BY `status` ASC, `action` ASC", __FILE__, __LINE__);
 // Entries found?
 if (SQL_NUMROWS($result) > 0) {
        // List all entries
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // "Translate" some data
                $content['status']     = constant(sprintf("SURFBAR_URL_STATUS_%s", $content['status']));
@@ -82,7 +82,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("admin_list_surfbar_actions", false, $OUT);
 } else {
        // No entries found, very bad!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_NO_ACTIONS'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_NO_ACTIONS'));
 }
 
 // Free result
index a8b9dba6cb4577a7c73d4c11510cf27b31e16dfe..9dd6aefa204481b171a5477776499a54c705a613 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 } // END - if
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // By default show the list...
 $show = true;
@@ -51,7 +51,7 @@ $show = true;
 // Check for 'id' element
 if ((REQUEST_POST_COUNT() > 0) && ((!REQUEST_ISSET_POST(('id'))) || (!is_array(REQUEST_POST('id'))) || (count(REQUEST_POST('id')) == 0))) {
        // Not found so output message
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_NO_SELECTIONS'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_NO_SELECTIONS'));
 
        // Abort here
        return;
@@ -63,9 +63,9 @@ if (REQUEST_ISSET_POST('edit')) {
        ADMIN_EDIT_ENTRIES_CONFIRM(
                REQUEST_POST('id'),
                "surfbar_urls",
-               array("id", "userid", "url"),
-               array("bigintval", "ADD_MEMBER_SELECTION_BOX", ""),
-               array("", array(false, true, true), "")
+               array("id", 'userid', "url"),
+               array("bigintval", "ADD_MEMBER_SELECTION_BOX", ''),
+               array("", array(false, true, true), '')
        );
        $show = false;
 } elseif (REQUEST_ISSET_POST(('do_edit'))) {
@@ -83,9 +83,9 @@ if (REQUEST_ISSET_POST('edit')) {
        ADMIN_DELETE_ENTRIES_CONFIRM(
                REQUEST_POST('id'),
                "surfbar_urls",
-               array("id", "userid", "url", "registered"),
-               array("bigintval", "ADMIN_USER_PROFILE_LINK", "FRAMETESTER", ""),
-               array("", "", "", "")
+               array("id", 'userid', "url", "registered"),
+               array("bigintval", "ADMIN_USER_PROFILE_LINK", "FRAMETESTER", ''),
+               array("", '', '', '')
        );
        $show = false;
 } elseif (REQUEST_ISSET_POST(('do_delete'))) {
@@ -96,9 +96,9 @@ if (REQUEST_ISSET_POST('edit')) {
        ADMIN_LOCK_ENTRIES_CONFIRM(
                REQUEST_POST('id'),
                "surfbar_urls",
-               array("id", "userid", "url", "registered", "status"),
-               array("bigintval", "ADMIN_USER_PROFILE_LINK", "FRAMETESTER", "", "SURFBAR_TRANSLATE_STATUS"),
-               array("", "", "", "", "")
+               array("id", 'userid', "url", "registered", "status"),
+               array("bigintval", "ADMIN_USER_PROFILE_LINK", "FRAMETESTER", '', "SURFBAR_TRANSLATE_STATUS"),
+               array("", '', '', '', '')
        );
        $show = false;
 } elseif (REQUEST_ISSET_POST(('do_lock'))) {
@@ -117,9 +117,9 @@ if (REQUEST_ISSET_POST('edit')) {
        ADMIN_UNDELETE_ENTRIES_CONFIRM(
                REQUEST_POST('id'),
                "surfbar_urls",
-               array("id", "userid", "url", "registered", "status"),
-               array("bigintval", "ADMIN_USER_PROFILE_LINK", "FRAMETESTER", "", "SURFBAR_TRANSLATE_STATUS"),
-               array("", "", "", "", "")
+               array("id", 'userid', "url", "registered", "status"),
+               array("bigintval", "ADMIN_USER_PROFILE_LINK", "FRAMETESTER", '', "SURFBAR_TRANSLATE_STATUS"),
+               array("", '', '', '', '')
        );
        $show = false;
 } elseif (REQUEST_ISSET_POST(('do_undelete'))) {
@@ -146,7 +146,7 @@ ORDER BY `id` ASC", __FILE__, __LINE__);
 // Do we have some URLs left?
 if (SQL_NUMROWS($result) > 0) {
        // List all URLs
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // "Translate"/add content
                $content['sw']          = $SW;
@@ -169,7 +169,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("admin_list_surfbar_urls", false, $OUT);
 } else {
        // No URLs in surfbar
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_NO_URLS_FOUND'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_NO_URLS_FOUND'));
 }
 
 // Free result
index ca6095d48e63b8a4c1e43c6a80fb103f958f0196..d920bba3f123cdf36c660676c1b3de2c7a8402eb 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("task")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "task");
+} elseif (!EXT_IS_ACTIVE('task')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'task');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
-$whereStatement = "";
+$whereStatement = '';
 if (!REQUEST_ISSET_GET(('type'))) REQUEST_SET_GET('type', "your");
 
 switch (REQUEST_GET('type'))
@@ -79,7 +79,7 @@ case "closed": // List all closed
 
 default: // Unknown type
        DEBUG_LOG(__FILE__, __LINE__, sprintf("Unknown task type %s detected.", REQUEST_GET('type')));
-       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_TASK_UNKNOWN_MODE'), REQUEST_GET('type')));
+       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_TASK_UNKNOWN_MODE'), REQUEST_GET('type')));
        break;
 }
 
@@ -90,7 +90,7 @@ if (!empty($whereStatement)) {
        if ((REQUEST_ISSET_POST(('assign'))) && ($SEL > 0)) {
                // Assign / do tasks
                LOAD_INC_ONCE("inc/modules/admin/overview-inc.php");
-               if (empty($dmy)) $dmy = "";
+               if (empty($dmy)) $dmy = '';
                OUTPUT_SELECTED_TASKS(REQUEST_POST_ARRAY(), $dmy);
        } else {
                // Start listing tasks matching selected filter
@@ -131,7 +131,7 @@ ORDER BY userid DESC, task_type DESC, subject, task_created DESC", __FILE__, __L
                        'message' => $type,
                        'type'    => REQUEST_GET('type')
                ));
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result_tasks)) {
                        // Init infos
                        $content['infos'] = "---";
index f25c4c94157f8164926487dd7ee553ba5a00a0d4..7062faf6614e5337afeb42385099826e3ddc4667 100644 (file)
@@ -43,7 +43,7 @@ if (ereg(basename(__FILE__), $_SERVER['PHP_SELF']) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // We only need outgoing transfers
 $result = SQL_QUERY("SELECT userid, to_uid, trans_id, points, reason, time_trans FROM `{!_MYSQL_PREFIX!}_user_transfers_out` ORDER BY trans_id", __FILE__, __LINE__);
@@ -51,7 +51,7 @@ $total = 0;
 if (SQL_NUMROWS($result) > 0)
 {
        // Output rows
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Prepare data for the row template
                $content = array(
@@ -77,7 +77,7 @@ if (SQL_NUMROWS($result) > 0)
        // Nothing for in and out
        $OUT = "<tr>
   <td colspan=\"6\" align=\"center\" class=\"bottom2\" height=\"70\">
-    ".LOAD_TEMPLATE("admin_settings_saved", true, getMessage('TRANSFER_NO_INOUT_TRANSFERS'))."
+    ".LOAD_TEMPLATE('admin_settings_saved', true, getMessage('TRANSFER_NO_INOUT_TRANSFERS'))."
   </td>
 </tr>";
 }
index 7c934c13ec817037b7bd03c72ab9b277ac5da66a..a5731afdc987ab34635cd81d075c2186e24b1a45 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("mailid")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "mailid");
+} elseif (!EXT_IS_ACTIVE('mailid')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'mailid');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Don't load the admin_list_unconfirmed template by default
 $listed = false;
@@ -63,8 +63,8 @@ WHERE p.id='".REQUEST_GET('mid')."' LIMIT 1";
        $col = "stats_id"; $type = "NORMAL"; $ID = "-1";
 
        // Load admin_list_unconfirmed template
-       $listed = true; $DATA = REQUEST_GET('mid'); $LINK = "mailid";
-} elseif ((REQUEST_ISSET_GET(('bid'))) && (EXT_IS_ACTIVE("bonus"))) {
+       $listed = true; $DATA = REQUEST_GET('mid'); $LINK = 'mailid';
+} elseif ((REQUEST_ISSET_GET(('bid'))) && (EXT_IS_ACTIVE('bonus'))) {
        // @TODO This constant might be unused?
        define('__LIST_UNCON_TITLE', getMessage('LIST_UNCONFIRMED_BONUS_LINKS'));
 
@@ -72,13 +72,13 @@ WHERE p.id='".REQUEST_GET('mid')."' LIMIT 1";
        $sql = "SELECT id, id, subject, text, url, timestamp, mails_sent FROM `{!_MYSQL_PREFIX!}_bonus` WHERE id='".REQUEST_GET('bid')."' LIMIT 1";
 
        // Column, type and ID for member's mail
-       $col = "bonus_id"; $type = "BONUS"; $ID = REQUEST_GET('bid');
+       $col = 'bonus_id'; $type = "BONUS"; $ID = REQUEST_GET('bid');
 
        // Load admin_list_unconfirmed template
-       $listed = true; $DATA = $ID; $LINK = "bonusid";
+       $listed = true; $DATA = $ID; $LINK = 'bonusid';
 } else {
        // @TODO "Please do not call me directly." Should be rewritten to a nice selection depending on ext-bonus
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_CALL_NOT_DIRECTLY'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_CALL_NOT_DIRECTLY'));
 }
 
 // Shall I display links or not?
@@ -93,7 +93,7 @@ if ($listed === true) {
 
                // Transfer data to constants for the template
                if (($stats_id > 0) && ($ID == "-1")) $ID = $stats_id;
-               if ($col == "bonus_id") $sender = 0;
+               if ($col == 'bonus_id') $sender = 0;
 
                // Load unconfirmed mail links. Hmmm, this select query is pretty cool
                // but it does only show unconfirmed mail links from existing user
@@ -109,7 +109,8 @@ WHERE l.%s='%s' ORDER BY l.userid LIMIT %s",
 
                if ($unconfirmed > 0) {
                        // At least one link left to confirm
-                       $OUT = ""; $SW = 2;
+
+                       $OUT = ''; $SW = 2;
                        while ($content = SQL_FETCHARRAY($result)) {
                                // Prepare data for the row template
                                // @TODO Rewritings: uid->userid
@@ -135,7 +136,7 @@ WHERE l.%s='%s' ORDER BY l.userid LIMIT %s",
                        SQL_FREERESULT($result);
                } else {
                        // All links are confirmed... strange, you shall normally not get a link to this place in this scenario... hmmm.
-                       $OUT = LOAD_TEMPLATE("admin_settings_saved", true, getMessage('ADMIN_UNCONFIRMED_NO_LINK_LEFT'));
+                       $OUT = LOAD_TEMPLATE('admin_settings_saved', true, getMessage('ADMIN_UNCONFIRMED_NO_LINK_LEFT'));
                }
 
                // Prepare content
@@ -160,13 +161,13 @@ WHERE l.%s='%s' ORDER BY l.userid LIMIT %s",
                        array(bigintval($ID)), __FILE__, __LINE__);
                if (SQL_NUMROWS($result1) == 1) {
                        // pool table
-                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_UNCONFIRMED_POOL_MISSING'), $ID));
+                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_UNCONFIRMED_POOL_MISSING'), $ID));
                } elseif (SQL_NUMROWS($result2) == 1) {
                        // user_stats table
-                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_UNCONFIRMED_STATS_MISSING'), $ID));
+                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_UNCONFIRMED_STATS_MISSING'), $ID));
                } else {
                        // both or link is invalid
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_UNCONFIRMED_INVALID_LINK'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_UNCONFIRMED_INVALID_LINK'));
                }
 
                // Free memory
@@ -174,7 +175,7 @@ WHERE l.%s='%s' ORDER BY l.userid LIMIT %s",
                SQL_FREERESULT($result2);
        } elseif (REQUEST_ISSET_GET(('bid'))) {
                // Data in bonus table not found
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_UNCONFIRMED_INVALID_LINK'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_UNCONFIRMED_INVALID_LINK'));
        }
 }
 
index 1138d1aa7ad8348a56940a2ea3002724da9ca79c..fbd7ada82d83453688b2d74cd76619a6c8acfb1b 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("user")) || (GET_EXT_VERSION("user") == "")) {
+} elseif ((!EXT_IS_ACTIVE('user')) || (GET_EXT_VERSION('user') == "")) {
        // Missing extension!
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "user");
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'user');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Init title with "all accounts"
 $listHeader = getMessage('ADMIN_ALL_ACCOUNTS');
@@ -66,22 +66,22 @@ define('__TITLE', $listHeader);
 $MORE = ", userid"; $colspan = "4";
 
 // Add nickname if extension is found&active
-if (EXT_IS_ACTIVE("nickname")) { $MORE = ", nickname"; }
+if (EXT_IS_ACTIVE('nickname')) { $MORE = ", nickname"; }
 
 // Add random confirmed if extension version matches
-if (GET_EXT_VERSION("user") >= "0.3.4") {
+if (GET_EXT_VERSION('user') >= '0.3.4') {
        // Add it...
        $MORE .= ", rand_confirmed";
 
        // Add lock reason?
-       if (GET_EXT_VERSION("user") >= "0.3.5") {
+       if (GET_EXT_VERSION('user') >= '0.3.5') {
                // Add them...
                $MORE .= ", lock_reason, UNIX_TIMESTAMP(`lock_timestamp`) AS lock_timestamp";
        } // END - if
 } // END - if
 
-// Is the extension "country" installed?
-if (EXT_IS_ACTIVE("country")) {
+// Is the extension 'country' installed?
+if (EXT_IS_ACTIVE('country')) {
        // Add country code
        $MORE .= ", country_code";
 } else {
@@ -91,13 +91,13 @@ if (EXT_IS_ACTIVE("country")) {
 
 // Init unset data (bad that we change $_GET here!)
 if (!REQUEST_ISSET_GET(('letter'))) { REQUEST_SET_GET('letter', getMessage('_ALL2')); }
-if (!REQUEST_ISSET_GET(('sortby'))) { REQUEST_SET_GET('sortby', "userid");            }
+if (!REQUEST_ISSET_GET(('sortby'))) { REQUEST_SET_GET('sortby', 'userid');            }
 if (!REQUEST_ISSET_GET(('page')))   { REQUEST_SET_GET('page'  , "1");                 }
 
 // Set base URL
 $BASE = "[<a href=\"{!URL!}/modules.php?module=admin";
 
-if (REQUEST_ISSET_GET(('uid'))) {
+if (REQUEST_ISSET_GET('uid')) {
        // Secure the user ID
        $uid = bigintval(REQUEST_GET('uid'));
 
@@ -113,8 +113,8 @@ LIMIT 1",
 
                // Get count/sum of refs, selected categories, unconfirmed mails
                $REFS  = GET_TOTAL_DATA($uid, "refsystem", "counter");
-               $CATS  = GET_TOTAL_DATA($uid, "user_cats", "id", "userid", true);
-               $LINKS = GET_TOTAL_DATA($uid, "user_links", "id", "userid", true);
+               $CATS  = GET_TOTAL_DATA($uid, "user_cats", "id", 'userid', true);
+               $LINKS = GET_TOTAL_DATA($uid, "user_links", "id", 'userid', true);
 
                // Add links to the numbers
                if ($LINKS > 0) $LINKS = $BASE."&amp;what=list_links&amp;uid=".$uid."\">".$LINKS."</a>]";
@@ -158,7 +158,7 @@ LIMIT 1",
 
                // Nickname inclusion?
                // @TODO Rewrite these to filters
-               if (EXT_IS_ACTIVE("nickname")) {
+               if (EXT_IS_ACTIVE('nickname')) {
                        // Nickname not set or invalid? Then 
                        if ((empty($DATA['nickname'])) || ($DATA['nickname'] == $uid)) $DATA['nickname'] = "---";
                } else {
@@ -167,7 +167,7 @@ LIMIT 1",
                }
 
                // Is the user extension newer?
-               if (GET_EXT_VERSION("user") >= "0.3.4") {
+               if (GET_EXT_VERSION('user') >= '0.3.4') {
                        // Then "translate" the number
                        $DATA['rand_confirmed'] = TRANSLATE_COMMA($DATA['rand_confirmed']);
                } // END - if
@@ -182,8 +182,8 @@ LIMIT 1",
                $DATA['mails_confirmed'] = TRANSLATE_COMMA($DATA['mails_confirmed']);
                $DATA['emails_received'] = TRANSLATE_COMMA($DATA['emails_received']);
 
-               // Is the extension "country" installed?
-               if (EXT_IS_ACTIVE("country")) {
+               // Is the extension 'country' installed?
+               if (EXT_IS_ACTIVE('country')) {
                        // Then overwrite country information
                        $DATA['country'] = COUNTRY_GENERATE_INFO($DATA['country_code']);
                } elseif ($DATA['country'] == 0) {
@@ -195,13 +195,13 @@ LIMIT 1",
                LOAD_TEMPLATE("admin_user_details", false, $uid);
        } else {
                // Account does not exist!
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_MEMBER_404'), $uid));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_MEMBER_404'), $uid));
        }
 
        // Free the result
        SQL_FREERESULT($result_user);
 } else {
-       $whereStatement = "";
+       $whereStatement = '';
        if ((REQUEST_GET('letter') != getMessage('_ALL2')) && (REQUEST_GET('letter') != getMessage('_OTHERS')) && (REQUEST_ISSET_GET(('letter')))) {
                // List only persons w
                $whereStatement = " WHERE family LIKE '".REQUEST_GET('letter')."%'";
@@ -244,7 +244,7 @@ LIMIT 1",
        // Calculate page count (0.5 fixes a bug with page count)
        if (getConfig('user_limit') == 0) {
                setConfigEntry('user_limit', 100);
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('EXTENSION_WARNING_USER_LIMIT'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('EXTENSION_WARNING_USER_LIMIT'));
        } // END - if
 
        // Activate the extension please!
@@ -278,27 +278,27 @@ LIMIT 1",
                        define('__PAGE_NAV', ADD_PAGENAV($PAGES, getConfig('user_limit'), true, $colspan, true));
                } else {
                        // No page navigation is required
-                       define('__PAGE_NAV', "");
+                       define('__PAGE_NAV', '');
                }
 
                // Column with nickname when nickname extension is present
                // @TODO Rewrite this into a  filter
-               if (EXT_IS_ACTIVE("nickname")) {
+               if (EXT_IS_ACTIVE('nickname')) {
                        // Nickname extension found
                        define('__NICKNAME_TH', "  <td class=\"admin_title bottom2\" align=\"center\">{--NICKNAME--}</td>");
                } else {
                        // Not found
-                       define('__NICKNAME_TH', "");
+                       define('__NICKNAME_TH', '');
                }
 
                // Load all users
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Set refid link
                        if ($content['refid'] > 0) $content['refid'] = ADMIN_USER_PROFILE_LINK($content['refid']);
 
                        // Get number of unconfirmed mails
-                       $LINKS = GET_TOTAL_DATA($content['userid'], "user_links", "id", "userid", true);
+                       $LINKS = GET_TOTAL_DATA($content['userid'], "user_links", "id", 'userid', true);
                        if ($LINKS > 0) $LINKS = $BASE."&amp;what=list_links&amp;uid=".$content['userid']."\">".TRANSLATE_COMMA($LINKS)."</a>]";
 
                        // Set link to sent mails if present
@@ -333,9 +333,9 @@ LIMIT 1",
                        // Is the lock reason not set?
                        if (!isset($content['lock_reason'])) $content['lock_reason'] = "---";
 
-                       // Is the extension "country" installed?
+                       // Is the extension 'country' installed?
                        // @TODO Rewrite this into a filter
-                       if (EXT_IS_ACTIVE("country")) {
+                       if (EXT_IS_ACTIVE('country')) {
                                // Then overwrite country information
                                $content['country'] = COUNTRY_GENERATE_INFO($content['country_code']);
                        } elseif ($content['country'] == "") {
@@ -360,7 +360,7 @@ LIMIT 1",
                SQL_FREERESULT($result_master);
        } else {
                // No one as registered so far! :-(
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NO_NONE_REGISTERED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NO_NONE_REGISTERED'));
        }
 }
 
index 2c1605239ef16d8ac0dbc8cf43685b235ac5628d..e5ccb73af957f8c9663b016911b7cb63b561fddb 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Check for entries
 $result = SQL_QUERY("SELECT id, userid, wernis_account, wernis_amount, wernis_timestamp, wernis_type, wernis_api_message, wernis_api_status FROM `{!_MYSQL_PREFIX!}_user_wernis` ORDER BY wernis_timestamp DESC, id DESC",
@@ -52,7 +52,7 @@ $result = SQL_QUERY("SELECT id, userid, wernis_account, wernis_amount, wernis_ti
 // Are there some entries to display?
 if (SQL_NUMROWS($result) > 0) {
        // List all entries
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Translate some data and add color
                $content['sw']                                  = $SW;
@@ -75,7 +75,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("admin_list_wernis_main", false, $OUT);
 } else {
        // Nothing to display!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('WERNIS_ADMIN_NO_TRANSFERS'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('WERNIS_ADMIN_NO_TRANSFERS'));
 }
 
 // Free the result
index ec846b2e313c9eec3ff4eac6e5f4c6e657240062..b1bda7a96878ee25845297b496ff90953c684ea5 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("yoomedia")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "yoomedia");
+} elseif (!EXT_IS_ACTIVE('yoomedia')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'yoomedia');
        return;
-} elseif (!EXT_IS_ACTIVE("bonus")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "bonus");
+} elseif (!EXT_IS_ACTIVE('bonus')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'bonus');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Do actions here
 if (IS_FORM_SENT()) {
@@ -57,19 +57,19 @@ if (IS_FORM_SENT()) {
        return;
 } elseif (REQUEST_ISSET_POST(('sent'))) {
        // Sent mail
-       YOOMEDIA_SEND_BONUS_MAIL(REQUEST_POST_ARRAY(), "normal");
+       YOOMEDIA_SEND_BONUS_MAIL(REQUEST_POST_ARRAY(), 'normal');
 } elseif (REQUEST_ISSET_POST('remove')) {
        // Add mail to exclude list
-       YOOMEDIA_EXCLUDE_MAIL(REQUEST_POST_ARRAY(), "normal");
+       YOOMEDIA_EXCLUDE_MAIL(REQUEST_POST_ARRAY(), 'normal');
 } elseif (REQUEST_ISSET_POST(('unlist'))) {
        // Remove mail from exclude list
-       YOOMEDIA_UNLIST_MAIL(REQUEST_POST_ARRAY(), "normal");
+       YOOMEDIA_UNLIST_MAIL(REQUEST_POST_ARRAY(), 'normal');
 }
 
 // Enougth queries left?
 if (getConfig('yoomedia_requests_remain') == 0) {
        // Output message
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_YOOMEDIA_REQUESTS_DEPLETED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_YOOMEDIA_REQUESTS_DEPLETED'));
 
        // Abort here!
        return false;
@@ -81,7 +81,7 @@ $result = YOOMEDIA_GET_PARSED_RESULT_TEXTMAILS();
 // Sanity-check on result array
 if ((!is_array($result)) || (count($result) == 0) || (!isset($result[0]['id']))) {
        // Invalid result
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_YOOMEDIA_INVALID_RESULT'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_YOOMEDIA_INVALID_RESULT'));
        return false;
 } elseif (count($result[0]) < 7) {
        // Error received so prepare error code
@@ -91,12 +91,12 @@ if ((!is_array($result)) || (count($result) == 0) || (!isset($result[0]['id'])))
        $code = $code[0];
 
        // Output message
-       LOAD_TEMPLATE("admin_yoomedia_error", false, sprintf("{--ADMIN_YOOMEDIA_ERROR_%s--}", strtoupper(YOOMEDIA_TRANSLATE_ERROR($code))));
+       LOAD_TEMPLATE('admin_yoomedia_error', false, sprintf("{--ADMIN_YOOMEDIA_ERROR_%s--}", strtoupper(YOOMEDIA_TRANSLATE_ERROR($code))));
        return false;
 }
 
 // Prepare all entries
-$OUT = ""; $SW = 2;
+$OUT = ''; $SW = 2;
 foreach ($result as $entry) {
        // Translate some data
        $entry['pay']    = TRANSLATE_COMMA($entry['pay'], true, 5);
@@ -104,7 +104,7 @@ foreach ($result as $entry) {
        $entry['sw']     = $SW;
 
        // Check reload lock
-       $reload = YOOMEDIA_CHECK_RELOAD($entry['id'], $entry['reload'], "textmail");
+       $reload = YOOMEDIA_CHECK_RELOAD($entry['id'], $entry['reload'], 'textmail');
 
        // Is this mail already sent?
        if ($reload !== false) {
@@ -123,17 +123,17 @@ foreach ($result as $entry) {
                        } // END - if
 
                        // Add reload lock
-                       $entry['already'] = sprintf(ADMIN_YOOMEDIA_TEXTMAIL_SEND_AGAIN, CREATE_FANCY_TIME($countdown));
+                       $entry['already'] = sprintf(getMessage('ADMIN_YOOMEDIA_TEXTMAIL_SEND_AGAIN'), CREATE_FANCY_TIME($countdown));
                } else {
                        // Never resentable unless manual removal
-                       $entry['already'] = ADMIN_YOOMEDIA_TEXTMAIL_MANUALLY_LOCKED;
+                       $entry['already'] = getMessage('ADMIN_YOOMEDIA_TEXTMAIL_MANUALLY_LOCKED');
                }
 
                // Load row template for displaying
-               $OUT .= LOAD_TEMPLATE("admin_list_yoomedia_tm_already", true, $entry);
+               $OUT .= LOAD_TEMPLATE('admin_list_yoomedia_tm_already', true, $entry);
        } else {
                // Load row template with buttons
-               $OUT .= LOAD_TEMPLATE("admin_list_yoomedia_tm_row", true, $entry);
+               $OUT .= LOAD_TEMPLATE('admin_list_yoomedia_tm_row', true, $entry);
        }
 
        // Switch color
@@ -141,7 +141,7 @@ foreach ($result as $entry) {
 } // END - if
 
 // Load main template
-LOAD_TEMPLATE("admin_list_yoomedia_tm", false, $OUT);
+LOAD_TEMPLATE('admin_list_yoomedia_tm', false, $OUT);
 
 //
 ?>
index 2c25522331a7a75bbd1797a6dd5e4058edaf30e5..d62a40bc111068640dc01c3766aaae5e7491f13e 100644 (file)
@@ -43,8 +43,8 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
-$message = "";
+ADD_DESCR('admin', __FILE__);
+$message = '';
 
 if (REQUEST_ISSET_GET(('id'))) {
        // Check for selected sponsor
@@ -121,7 +121,7 @@ if (REQUEST_ISSET_GET(('id'))) {
 
 if (!empty($message)) {
        // Output message
-       LOAD_TEMPLATE("admin_settings_saved", false, $message);
+       LOAD_TEMPLATE('admin_settings_saved', false, $message);
 }
 
 //
index b2ad76d35de0d65c37002f6226f321ea75e81c68..70f28f228727cb4c5c450a98a15dd3212396a954 100644 (file)
@@ -43,10 +43,10 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Is a userid set?
-if (REQUEST_ISSET_GET(('uid'))) {
+if (REQUEST_ISSET_GET('uid')) {
        // Load user's data
        $result_user = SQL_QUERY_ESC("SELECT status, gender, surname, family, email FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
         array(bigintval(REQUEST_GET('uid'))), __FILE__, __LINE__);
@@ -61,7 +61,7 @@ if (REQUEST_ISSET_GET(('uid'))) {
                // Is a lock reason set?
                if ((REQUEST_ISSET_POST(('lock'))) && ($status != "LOCKED")) {
                        // Ok, lock the account!
-                       if (GET_EXT_VERSION("user") >= "0.3.5") {
+                       if (GET_EXT_VERSION('user') >= '0.3.5') {
                                // Lock with reason
                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET `status`='LOCKED',lock_reason='%s',lock_timestamp=NOW() WHERE userid=%s LIMIT 1",
                                        array(REQUEST_POST('reason'), bigintval(REQUEST_GET('uid'))), __FILE__, __LINE__);
@@ -85,7 +85,7 @@ if (REQUEST_ISSET_GET(('uid'))) {
                        $ACT = true;
                } elseif ((REQUEST_ISSET_POST(('unlock'))) && ($status == "LOCKED")) {
                        // Ok, unlock the account!
-                       if (GET_EXT_VERSION("user") >= "0.3.5") {
+                       if (GET_EXT_VERSION('user') >= '0.3.5') {
                                // Reset lock reason as well
                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET `status`='CONFIRMED',lock_reason='',lock_timestamp='0000-00-00 00:00' WHERE userid=%s LIMIT 1",
                                        array(bigintval(REQUEST_GET('uid'))), __FILE__, __LINE__);
@@ -102,7 +102,7 @@ if (REQUEST_ISSET_GET(('uid'))) {
 
                                // Send away...
                                SEND_EMAIL(bigintval(REQUEST_GET('uid')), getMessage('ADMIN_UNLOCKED_SUBJ'), $msg);
-                               if (EXT_IS_ACTIVE("rallye")) {
+                               if (EXT_IS_ACTIVE('rallye')) {
                                        RALLYE_AUTOADD_USER(REQUEST_GET('uid'));
                                } // END - if
                        } // END - if
@@ -162,7 +162,7 @@ if (REQUEST_ISSET_GET(('uid'))) {
                                LOAD_TEMPLATE("admin_lock_user");
                        } else {
                                // Account does not exists!
-                               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
+                               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
                        }
                }
 
@@ -173,14 +173,14 @@ if (REQUEST_ISSET_GET(('uid'))) {
                } elseif ($ACT) {
                        // An action was performed...
                        if (!empty($message)) {
-                               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_green\">".$message."</div>");
+                               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_green\">".$message."</div>");
                        } else {
-                               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_green\">".getMessage('ADMIN_USER_UPDATED')."</div>");
+                               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_green\">".getMessage('ADMIN_USER_UPDATED')."</div>");
                        }
                }
        } else {
                // Account does not exists!
-               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
        }
 } else {
        // List all users
index c88090e1714b1293fe69eca592893467f15b989b..2556113fc2539d5a0ed01a677f217141eedd6fe0 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (REQUEST_ISSET_GET(('access'))) {
        // Secure input and construct FQFN
@@ -76,7 +76,7 @@ if (REQUEST_ISSET_GET(('access'))) {
                        OUTPUT_HTML($OUTPUT);
 
                        // Output message
-                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_UNKNOWN_LOGFILE_FORMAT'), $access));
+                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_UNKNOWN_LOGFILE_FORMAT'), $access));
                        return;
                }
 
@@ -85,7 +85,7 @@ if (REQUEST_ISSET_GET(('access'))) {
                shutdown();
        } else {
                // Not readable!
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('LOGFILE_NOT_READABLE'), $access));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('LOGFILE_NOT_READABLE'), $access));
        }
 } else {
        // List access logfiles
@@ -105,7 +105,7 @@ if (REQUEST_ISSET_GET(('access'))) {
                OUTPUT_HTML("</ol>");
        } else {
                // logs directory does not exist
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_LOGS_DIR_404'), getConfig('logs_base')));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_LOGS_DIR_404'), getConfig('logs_base')));
        }
 }
 
index 2eba1879108411283ec8b24d7e065536e3b2d5aa..627f505b0dd05a716759323166f3711f94ac4a1b 100644 (file)
@@ -43,36 +43,36 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        // De- or activate maintenance mode
        switch (getConfig('maintenance'))
        {
-       case "Y":
+       case 'Y':
                $target_mode = "N";
                $out = getMessage('ADMIN_MAINTENANCE_DEACTIVATED');
                break;
 
-       case "N":
+       case 'N':
                $target_mode = "Y";
                $out = getMessage('ADMIN_MAINTENANCE_ACTIVATED');
                break;
        }
 
        // Update config
-       UPDATE_CONFIG("maintenance", $target_mode);
+       UPDATE_CONFIG('maintenance', $target_mode);
 
        // Load template
-       LOAD_TEMPLATE("admin_settings_saved", false, $out);
+       LOAD_TEMPLATE('admin_settings_saved', false, $out);
 } else {
        switch (getConfig('maintenance'))
        {
-       case "Y": // Maintenance mode is active
+       case 'Y': // Maintenance mode is active
                define('ADMIN_MAINTENANCE_MODE', getMessage('ADMIN_MAINTENANCE_MODE_IS_ACTIVE'));
                break;
 
-       case "N": // Maintenance mode is inactive
+       case 'N': // Maintenance mode is inactive
                define('ADMIN_MAINTENANCE_MODE', getMessage('ADMIN_MAINTENANCE_MODE_IS_INACTIVE'));
                break;
        }
index 155609cbdea603f2062ffead846fa3c39e27bd7d..3cfdd7efe7004e4e49e4a5d0622c0feb3aa4a2f7 100644 (file)
@@ -44,7 +44,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add desciption as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Check if the admin has entered title and what-php file name...
 if ((!REQUEST_ISSET_POST(('title'))) && (IS_FORM_SENT())) {
@@ -76,7 +76,7 @@ if (!IS_FORM_SENT()) {
 
                // Remove double eintries
                // @TODO This can be somehow rewritten to a function
-               $prev = ""; $dmy = $menus; $dmy2 = $titles; $dmy3 = $below;
+               $prev = ''; $dmy = $menus; $dmy2 = $titles; $dmy3 = $below;
                foreach ($menus as $key => $value) {
                        if ($value == $prev) {
                                // Remove entries
@@ -118,7 +118,7 @@ if (!IS_FORM_SENT()) {
 
                                // Remove double eintries
                                // @TODO This can be somehow rewritten to a function
-                               $prev = ""; $dmy = $menus[$value_main]; $dmy2 = $titles[$value_main]; $dmy3 = $below[$value_main];
+                               $prev = ''; $dmy = $menus[$value_main]; $dmy2 = $titles[$value_main]; $dmy3 = $below[$value_main];
                                foreach ($menus[$value_main] as $key => $value) {
                                        if ($value == $prev) {
                                                unset($dmy[$key]);
@@ -157,8 +157,8 @@ if (!IS_FORM_SENT()) {
        $OUT .= "</select>";
 
        define('__BELOW_SELECTION' , $OUT);
-       define('__WHAT_SELECTION'  , ADMIN_MAKE_MENU_SELECTION("member", "what", "name"));
-       define('__ACTION_SELECTION', ADMIN_MAKE_MENU_SELECTION("member", "action", "menu"));
+       define('__WHAT_SELECTION'  , ADMIN_MAKE_MENU_SELECTION('member', "what", "name"));
+       define('__ACTION_SELECTION', ADMIN_MAKE_MENU_SELECTION('member', "action", "menu"));
 
        // Display form
        LOAD_TEMPLATE("admin_member_add");
@@ -184,10 +184,10 @@ if (!IS_FORM_SENT()) {
                                bigintval(REQUEST_POST('sort')),
                        ), __FILE__, __LINE__);
        }
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_SAVED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_SAVED'));
 } else {
        // Demo mode!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_NOT_SAVED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_NOT_SAVED'));
 }
 
 //
index 72c27ee5f85c694fc3e01542f81483e805258c17..ad1fadd6ff5921d560e44435a053eb1bdcc24a98 100644 (file)
@@ -43,14 +43,14 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Do we edit/delete/change main menus or sub menus?
-$AND = "(`what` = '' OR `what` IS NULL)"; $SUB = "";
+$AND = "(`what` = '' OR `what` IS NULL)"; $SUB = '';
 
-if (REQUEST_ISSET_GET(('sub'))) {
-       $AND = sprintf("`action`='%s' AND `what` IS NOT NULL", REQUEST_GET(('sub')));
-       $SUB = REQUEST_GET(('sub'));
+if (REQUEST_ISSET_GET('sub')) {
+       $AND = sprintf("`action`='%s' AND `what` IS NOT NULL", REQUEST_GET('sub'));
+       $SUB = REQUEST_GET('sub');
 }
 
 // Get count of (maybe) selected menu points
@@ -62,7 +62,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO())) {
        // Edit menu entries
        define('__SUB_VALUE', $SUB);
        define('__CHK_VALUE', $chk);
-       $SW = 2; $cnt = 0; $OUT = "";
+       $SW = 2; $cnt = 0; $OUT = '';
        foreach (REQUEST_POST('sel') as $sel => $confirm) {
                if ($confirm == 1) {
                        $cnt++;
@@ -77,8 +77,8 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO())) {
                                        'sel'    => $sel,
                                        'menu'   => $menu,
                                        'sw'     => $SW,
-                                       'act'    => ADMIN_MAKE_MENU_SELECTION("member", "act", "sel_act[".$sel."]", $act),
-                                       'what'   => ADMIN_MAKE_MENU_SELECTION("member", "what", "sel_what[".$sel."]", $wht),
+                                       'act'    => ADMIN_MAKE_MENU_SELECTION('member', "act", "sel_act[".$sel."]", $act),
+                                       'what'   => ADMIN_MAKE_MENU_SELECTION('member', "what", "sel_what[".$sel."]", $wht),
                                );
                                // Load template
                                $OUT .= LOAD_TEMPLATE("admin_mmenu_edit_row", true, $content);
@@ -102,7 +102,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO())) {
        // Del menu entries with or without confirmation
        define('__SUB_VALUE', $SUB);
        define('__CHK_VALUE', $chk);
-       $SW = 2; $cnt = 0; $OUT = "";
+       $SW = 2; $cnt = 0; $OUT = '';
        foreach (REQUEST_POST('sel') as $sel => $confirm) {
                if ($confirm == 1) {
                        $cnt++;
@@ -140,7 +140,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO())) {
        // Change status (visible / locked)
        define('__SUB_VALUE', $SUB);
        define('__CHK_VALUE', $chk);
-       $SW = 2; $cnt = 0; $OUT = "";
+       $SW = 2; $cnt = 0; $OUT = '';
        foreach (REQUEST_POST('sel') as $sel => $confirm) {
                if ($confirm == 1) {
                        $cnt++;
@@ -205,11 +205,11 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO())) {
        }
 
        // Load template
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SETTINGS_SAVED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SETTINGS_SAVED'));
 } else {
        if ((REQUEST_ISSET_GET(('act'))) && (REQUEST_ISSET_GET(('tid'))) && (REQUEST_ISSET_GET(('fid')))) {
                // Init
-               $tid = ""; $fid = "";
+               $tid = ''; $fid = '';
 
                // Get IDs
                if (REQUEST_ISSET_GET(('w'))) {
@@ -255,10 +255,10 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO())) {
                // @TODO Rewrite this constant
                define('__SUB_VALUE', $SUB);
 
-               $SW = 2; $cnt = 0; $OUT = "";
+               $SW = 2; $cnt = 0; $OUT = '';
                while ($content = SQL_FETCHARRAY($result)) {
                        // Init navigation
-                       $content['navi'] = "";
+                       $content['navi'] = '';
                        $cnt++;
                        if (($content['sort'] == 0) || (($content['sort'] == 1) && (!empty($SUB)))) {
                                // Is highest position
@@ -295,7 +295,7 @@ if ((REQUEST_ISSET_POST('edit')) && ($chk > 0) && (!IS_DEMO())) {
                LOAD_TEMPLATE("admin_mmenu_overview");
        } else {
                // Menu entries are missing... (???)
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NO_MENUS_FOUND'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NO_MENUS_FOUND'));
        }
 }
 
index 683a78586461e23da1b1a611aa968efa7a621151..cca85728081af7ca612df4ab9d29652d865c9952 100644 (file)
@@ -43,17 +43,17 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Optimize and repair database and return the result as a multi-dimensional array
 $DATA = REPAIR_OPTIMIZE_DB();
 
 // Output rows
-$SW = 2; $gain_tabs = 0; $OUT = "";
+$SW = 2; $gain_tabs = 0; $OUT = '';
 foreach ($DATA['tables'] as $row_array)
 {
        // Init variables
-       $B1 = ""; $B2 = "";
+       $B1 = ''; $B2 = '';
 
        // Fixes a bug which causes a parser error on eval'd code
        if (empty($row_array[1])) $row_array[1] = "NONE";
index 7678500b9cbe9643c9190b2f8003cdae84b24c94..04e67c7c3a7dab5b2ce3478527cb6dabdd884507 100644 (file)
@@ -43,17 +43,17 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-// In Opera browsers the menu is being displayed double: ADD_DESCR("admin", __FILE__);
+// In Opera browsers the menu is being displayed double: ADD_DESCR('admin', __FILE__);
 
 // Otherwise load include file 'overview-inc' (old standard overview page)
 LOAD_INC_ONCE("inc/modules/admin/overview-inc.php");
 
 $jobsDone = true;
-$taskExt = false; // Default is that "task" is not installed
+$taskExt = false; // Default is that 'task' is not installed
 
 // When the admin is logging in check several things first (new jobs to complete and so on)
 if ($GLOBALS['action'] == "login") {
-       if (EXT_IS_ACTIVE("task")) {
+       if (EXT_IS_ACTIVE('task')) {
                // When task extension is registered output advanced overview page
                $jobsDone = OUTPUT_ADVANCED_OVERVIEW($result_tasks); // This function is provided by the extension 'task'
                $taskExt = true;
@@ -66,11 +66,11 @@ if ($GLOBALS['action'] == "login") {
 // Are we in 'welcome' page and are there jobs to be done?
 if (!ifAdminMenuHasEntries($GLOBALS['action'])) {
        // This menu is empty and so no content is displayed
-       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_MENU_IS_EMPTY'), $GLOBALS['action']));
+       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_MENU_IS_EMPTY'), $GLOBALS['action']));
 } elseif ($jobsDone === true) {
        // Generate overview of all main menus
        if ((is_array($GLOBALS['menu']['description'])) && (count($GLOBALS['menu']['description']) > 0)) {
-               $OUT = "";
+               $OUT = '';
                foreach ($GLOBALS['menu']['description'] as $key => $value) {
                        // Prepare content
                        $content = array(
@@ -86,9 +86,9 @@ if (!ifAdminMenuHasEntries($GLOBALS['action'])) {
                LOAD_TEMPLATE("admin_menu_hints", false, $OUT);
        }
 } elseif (!$taskExt) {
-       if (EXT_IS_ACTIVE("task")) {
+       if (EXT_IS_ACTIVE('task')) {
                // Output warning message
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('EXTENSION_WARNING_EXT_INACTIVE'), "task"));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('EXTENSION_WARNING_EXT_INACTIVE'), 'task'));
        }
 
        // List selected tasks on overview when task management is not active
index f3f6eb75590ebf195de6953f65dc58ebfeb5f5e2..c57a2cfb2efde7516424e14ab9cbe4eae20219d4 100644 (file)
@@ -43,15 +43,15 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
-if (((!REQUEST_ISSET_POST(('t_wait'))) || (!REQUEST_ISSET_POST(('payment')))) && (REQUEST_ISSET_GET('do')) && (REQUEST_GET('do') == "add")) {
+if (((!REQUEST_ISSET_POST(('t_wait'))) || (!REQUEST_ISSET_POST(('payment')))) && (REQUEST_ISSET_GET('do')) && (REQUEST_GET('do') == 'add')) {
        REQUEST_UNSET_POST('ok');
 }
 
 if (IS_FORM_SENT()) {
        switch (REQUEST_GET('do')) {
-       case "add":
+       case 'add':
                ADD_SQL("INSERT INTO `{!_MYSQL_PREFIX!}_payments` (time, payment, mail_title, price) VALUES ('".REQUEST_POST('t_wait')."','".REQUEST_POST('payment')."','".REQUEST_POST('title')."','".REQUEST_POST('price')."')");
                $result = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_payments` WHERE time='%s' LIMIT 1",
                        array(REQUEST_POST('t_wait')), __FILE__, __LINE__);
@@ -88,10 +88,10 @@ if (IS_FORM_SENT()) {
        }
 
        // Output template
-       LOAD_TEMPLATE("admin_settings_saved", false, $content);
+       LOAD_TEMPLATE('admin_settings_saved', false, $content);
 } elseif ((REQUEST_ISSET_POST('del')) && (SELECTION_COUNT(REQUEST_POST('sel')) > 0)) {
        // Delete entries here
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('sel') as $id => $value) {
                $result = SQL_QUERY_ESC("SELECT time, mail_title FROM `{!_MYSQL_PREFIX!}_payments` WHERE id=%s LIMIT 1",
                        array(bigintval($id)), __FILE__, __LINE__);
@@ -116,7 +116,7 @@ if (IS_FORM_SENT()) {
        LOAD_TEMPLATE("admin_del_payments");
 } elseif ((REQUEST_ISSET_POST('edit')) && (SELECTION_COUNT(REQUEST_POST('sel')) > 0)) {
        // Edit entries
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach (REQUEST_POST('sel') as $id => $value) {
                $result = SQL_QUERY_ESC("SELECT time, payment, mail_title, price FROM `{!_MYSQL_PREFIX!}_payments` WHERE id=%s LIMIT 1",
                 array(bigintval($id)), __FILE__, __LINE__);
@@ -146,7 +146,7 @@ if (IS_FORM_SENT()) {
        $result = SQL_QUERY("SELECT id, time, payment, mail_title, price FROM `{!_MYSQL_PREFIX!}_payments` ORDER BY time", __FILE__, __LINE__);
        if (SQL_NUMROWS($result) > 0) {
                // Make referal levels editable and deletable
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
 
                // List already existing categories for editing
                while ($content = SQL_FETCHARRAY($result)) {
index a9236b0c508fa7541e62908a046c5178e7901325..2e64fa299931a217e1266b06d1bd57099d43a7d8 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Init variable
 $SEL = 0;
@@ -58,11 +58,11 @@ if (REQUEST_ISSET_POST('sel')) $SEL = SELECTION_COUNT(REQUEST_POST('sel'));
 
 if (IS_FORM_SENT()) {
        // Fix older calls from add-new-banner-form
-       if (!REQUEST_ISSET_GET(('mode'))) REQUEST_SET_GET('mode', "add");
-       $sql = "";
+       if (!REQUEST_ISSET_GET(('mode'))) REQUEST_SET_GET('mode', 'add');
+       $sql = '';
        switch (REQUEST_GET('mode'))
        {
-       case "add":
+       case 'add':
                // Check if banner is already added
                $result = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_refbanner` WHERE url='%s' LIMIT 1",
                        array(REQUEST_POST('url')), __FILE__, __LINE__);
@@ -99,10 +99,10 @@ VALUES ('%s','%s','%s')",
        } else {
                $content = "<span class=\"admin_failed\">{--SETTINGS_NOT_SAVED--}</span>";
        }
-       LOAD_TEMPLATE("admin_settings_saved", false, $content);
+       LOAD_TEMPLATE('admin_settings_saved', false, $content);
 } elseif (($SEL > 0) && (REQUEST_ISSET_POST('edit'))) {
        // Edit banner
-       $SW = ""; $OUT = "";
+       $SW = ''; $OUT = '';
        foreach (REQUEST_POST('sel') as $id => $sel) {
                // Load data
                $result = SQL_QUERY_ESC("SELECT url, alternate, visible FROM `{!_MYSQL_PREFIX!}_refbanner` WHERE id=%s LIMIT 1",
@@ -143,7 +143,7 @@ VALUES ('%s','%s','%s')",
                __FILE__, __LINE__);
        if (SQL_NUMROWS($result) > 0) {
                // Make referal banner editable and deletable
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Preapre data for the row
                        // @TODO Rewritings: alt->alternate,cnt->counter,clx->clicks in template
index 6c4348548ac4d1c8e5a1bc5d2633848ff6ceb4f1..c384d21609a2cfa2ffcbf6c2e34e3a99a3db3808 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 $ACTIONS = array();
 
@@ -93,7 +93,7 @@ if ($REP > 0) {
 }
 
 // Output message
-LOAD_TEMPLATE("admin_settings_saved", false, $message);
+LOAD_TEMPLATE('admin_settings_saved', false, $message);
 
 //
 ?>
index 047df9b1bb3fd329d29ef0b4b309bf8fac3be4c2..9c1639799368fcb8c0d327045a92ab44291886af 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 $result = SQL_QUERY("SELECT userid FROM `{!_MYSQL_PREFIX!}_user_cats` ORDER BY userid", __FILE__, __LINE__);
 if (SQL_NUMROWS($result) > 0) {
@@ -79,7 +79,7 @@ if (SQL_NUMROWS($result) > 0) {
 }
 
 // Load template
-LOAD_TEMPLATE("admin_settings_saved", false, $content);
+LOAD_TEMPLATE('admin_settings_saved', false, $content);
 
 //
 ?>
index 916cc08e5dc04bb129174f8a6bbc43f28bc1943f..0caa5b2cdaccaa1fe9b839f796fe91ee38866d3b 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 $ACTIONS = array();
 // First fix all main menus (what="")...
@@ -87,7 +87,7 @@ if ($REP > 0) {
 }
 
 // Output message
-LOAD_TEMPLATE("admin_settings_saved", false, $message);
+LOAD_TEMPLATE('admin_settings_saved', false, $message);
 
 //
 ?>
index efcdd59a488fbf780899547c6ac28959beb5f515..5a6bb423480bc84cdd58831ca44ed633fcd84af3 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 $ACTIONS = array();
 
@@ -90,7 +90,7 @@ if ($REP > 0) {
 }
 
 // Output message
-LOAD_TEMPLATE("admin_settings_saved", false, $message);
+LOAD_TEMPLATE('admin_settings_saved', false, $message);
 
 //
 ?>
index 33b154d632cbc2fd2f2c6746b5e3f6760c57ef94..271210de6e5f91ce0403973d21a605cb1a7a670a 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("order")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "order");
+} elseif (!EXT_IS_ACTIVE('order')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'order');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Set empty mode to "select"
 if (!REQUEST_ISSET_GET('mode')) REQUEST_SET_GET('mode', "select");
@@ -64,18 +64,18 @@ if (IS_FORM_SENT()) {
        // Store send mode
        define('__MODE', REQUEST_GET(('mode')));
 
-       if (EXT_IS_ACTIVE("html_mail")) {
+       if (EXT_IS_ACTIVE('html_mail')) {
                // If HTML extension is active
                define('__HTML_SELECT',  LOAD_TEMPLATE("admin_send_bonus_html", true));
        } else {
                // And if not
-               define('__HTML_SELECT', "");
+               define('__HTML_SELECT', '');
        }
 
        // Select template
        switch(REQUEST_GET('mode')) {
-               case "html":   // HTML mails
-               case "normal": // Normal mails
+               case 'html':   // HTML mails
+               case 'normal': // Normal mails
                        $template = "admin_send_bonus_form";
                        break;
 
index d63e71c103e58c6c64c82d8637a21ddb7a2c4150..285fc0f0592fae93d72367f5ccd3090008bf5bdd 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 if (IS_FORM_SENT()) {
        $result = SQL_QUERY("SELECT userid, email
@@ -54,13 +54,13 @@ ORDER BY userid ASC", __FILE__, __LINE__);
                // Members are available so we can send out the newsletter!
                while ($content = SQL_FETCHARRAY($result)) {
                        // Construct mail...
-                       $template = "newsletter";
+                       $template = 'newsletter';
 
                        // Check for extension and sending-mode
-                       if (!EXT_IS_ACTIVE("html_mail", true) && (REQUEST_POST('mode') == "html")) {
+                       if (!EXT_IS_ACTIVE('html_mail', true) && (REQUEST_POST('mode') == 'html')) {
                                // Set mode to text mode
                                REQUEST_POST('mode') == "text";
-                       } elseif (REQUEST_POST('mode') == "html") {
+                       } elseif (REQUEST_POST('mode') == 'html') {
                                // Set HTML templates
                                $template = "newsletter_html";
                        }
@@ -79,13 +79,13 @@ ORDER BY userid ASC", __FILE__, __LINE__);
                SQL_FREERESULT($result);
 
                // Output message
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NL_SEND_DONE'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NL_SEND_DONE'));
        }
 } else {
        // Copy data into constants for the template and load it
        // @TODO Rewrite this constant
        define('_DATESTAMP', MAKE_DATETIME(time(), "3"));
-       if (EXT_IS_ACTIVE("html_mail")) {
+       if (EXT_IS_ACTIVE('html_mail')) {
                // Load template with HTML mode
                LOAD_TEMPLATE("admin_newsletter");
        } else {
index 9df9dd2561a6e00eeef66641b8c583907b897713..35c27142665b38015a6f7bdd9408a83c92972c78 100644 (file)
 
 // Some security stuff...
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // If var is empty set it to empty
-if (!REQUEST_ISSET_GET('mod')) REQUEST_SET_GET('mod', "");
+if (!REQUEST_ISSET_GET('mod')) REQUEST_SET_GET('mod', '');
 
 // Check if module was selected
-if ((REQUEST_GET('mod') == "index") || (REQUEST_GET('mod') == "login")) {
+if ((REQUEST_GET('mod') == 'index') || (REQUEST_GET('mod') == 'login')) {
        // Select menu system
-       $mod = "";
+       $mod = '';
        switch (REQUEST_GET('mod')) {
-               case "index": $mod = "guest" ; break;
-               case "login": $mod = "member"; break;
+               case 'index': $mod = 'guest' ; break;
+               case 'login': $mod = 'member'; break;
                default: // Unknown
                        DEBUG_LOG(__FILE__, __LINE__, sprintf("Unknown mod %s detected.", REQUEST_GET('mod')));
                        break;
@@ -63,13 +63,13 @@ if ((REQUEST_GET('mod') == "index") || (REQUEST_GET('mod') == "login")) {
        // Load module's detail statistic
        $result = SQL_QUERY_ESC("SELECT action, title, counter FROM `{!_MYSQL_PREFIX!}_%s_menu` WHERE `what` != '' AND `what` IS NOT NULL ORDER BY counter DESC",
                array($mod), __FILE__, __LINE__);
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Add color switch
                $content['sw'] = $SW;
 
                // Load row template
-               $OUT .= LOAD_TEMPLATE("admin_mods_stats2_row", true, $content);
+               $OUT .= LOAD_TEMPLATE('admin_mods_stats2_row', true, $content);
 
                // Switch colors
                $SW = 3 - $SW;
@@ -80,15 +80,15 @@ if ((REQUEST_GET('mod') == "index") || (REQUEST_GET('mod') == "login")) {
        define('__MODS_ROWS', $OUT);
 
        // Load final template
-       LOAD_TEMPLATE("admin_mods_stats2");
+       LOAD_TEMPLATE('admin_mods_stats2');
 } else {
        // Load module statics
        $result = SQL_QUERY("SELECT module, title, clicks FROM `{!_MYSQL_PREFIX!}_mod_reg` ORDER BY clicks DESC, module", __FILE__, __LINE__);
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
-               if (empty($content['title'])) $content['title'] = "---";
+               if (empty($content['title'])) $content['title'] = '---';
 
-               if (($content['module'] == "index") || ($content['module'] == "login")) {
+               if (($content['module'] == 'index') || ($content['module'] == 'login')) {
                        // Add link to detail statistics
                        $content['module'] = "<strong><a href=\"{!URL!}/modules.php?module=admin&amp;what=stats_mods&amp;mod=".$content['module']."\">".$content['module']."</a></strong>";
                } // END - if
@@ -97,7 +97,7 @@ if ((REQUEST_GET('mod') == "index") || (REQUEST_GET('mod') == "login")) {
                $content['sw'] = $SW;
 
                // Load row template
-               $OUT .= LOAD_TEMPLATE("admin_mods_stats_row", true, $content);
+               $OUT .= LOAD_TEMPLATE('admin_mods_stats_row', true, $content);
        } // END - while
 
        // Free memory
@@ -105,7 +105,7 @@ if ((REQUEST_GET('mod') == "index") || (REQUEST_GET('mod') == "login")) {
        define('__MODS_ROWS', $OUT);
 
        // Load final template
-       LOAD_TEMPLATE("admin_mods_stats");
+       LOAD_TEMPLATE('admin_mods_stats');
 }
 
 //
index 3e8f3b33da42b4bc315e9173acafc5551bea0dbe..6652c11631330f5302f350e49c2b7d880d6bdd5d 100644 (file)
@@ -43,10 +43,10 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Fix a notice
-if (!REQUEST_ISSET_GET(('uid'))) REQUEST_SET_GET('uid', "");
+if (!REQUEST_ISSET_GET('uid')) REQUEST_SET_GET('uid', '');
 
 if (REQUEST_GET('uid') == "all") {
        // Add points to all accounts
@@ -74,12 +74,12 @@ if (REQUEST_GET('uid') == "all") {
                SQL_FREERESULT($result_main);
 
                // Output message
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_ALL_POINTS_SUBTRACTED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_ALL_POINTS_SUBTRACTED'));
        } else {
                // Display form add points
                LOAD_TEMPLATE("admin_sub_points_all");
        }
-} elseif (REQUEST_ISSET_GET(('uid'))) {
+} elseif (REQUEST_ISSET_GET('uid')) {
        // User ID found in URL so we use this give him some credits
        $result = SQL_QUERY_ESC("SELECT surname, family, email FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s AND `status`='CONFIRMED' LIMIT 1",
                array(bigintval(REQUEST_GET('uid'))),__FILE__, __LINE__);
@@ -100,7 +100,7 @@ if (REQUEST_GET('uid') == "all") {
                        SEND_EMAIL($content['email'], getMessage('ADMIN_SUB_SUBJ'), $msg);
 
                        // Output message
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_POINTS_SUBTRACTED'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_POINTS_SUBTRACTED'));
                } else {
                        // @TODO Rewrite these constants
                        define('__USER_VALUE', "<a href=\"".CREATE_EMAIL_LINK($content['email'], "user_data")."\">".$content['surname']." ".$content['family']."</a>");
@@ -111,7 +111,7 @@ if (REQUEST_GET('uid') == "all") {
                }
        } else {
                // User not found!
-               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_failed\">".sprintf(getMessage('ADMIN_MEMBER_404'), REQUEST_GET('uid'))."</div>");
        }
 
        // Free result
index cd6d292a494956df3dc8fcd8e859377cf1d29779..0fd034bf7a4903ba6990fa2a56fba54f4c2e7d83 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Is the 'url_id' set?
 if (REQUEST_ISSET_GET(('url_id'))) {
@@ -57,7 +57,7 @@ ORDER BY `userid` ASC",
        // Entries found?
        if (SQL_NUMROWS($result) > 0) {
                // Get all rows
-               $OUT = ""; $SW = 2; $cnt = 0; $visits = 0;
+               $OUT = ''; $SW = 2; $cnt = 0; $visits = 0;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Count totals
                        $visits += $content['total_visits'];
@@ -85,7 +85,7 @@ ORDER BY `userid` ASC",
                LOAD_TEMPLATE("admin_surfbar_url_stats", false, $content);
        } else {
                // No statistics so far
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_NO_URL_STATS'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_NO_URL_STATS'));
        }
 } else {
        // Generate general statistics
@@ -97,7 +97,7 @@ ORDER BY `userid` ASC", __FILE__, __LINE__);
        // Entries found?
        if (SQL_NUMROWS($result) > 0) {
                // Get all rows
-               $OUT = ""; $SW = 2; $urls = 0; $visits = 0;
+               $OUT = ''; $SW = 2; $urls = 0; $visits = 0;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Count totals
                        $urls   += $content['visited_urls'];
@@ -126,7 +126,7 @@ ORDER BY `userid` ASC", __FILE__, __LINE__);
                LOAD_TEMPLATE("admin_surfbar_stats", false, $content);
        } else {
                // No statistics so far
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_NO_STATS'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_NO_STATS'));
        }
 }
 
index cda1cf32a3617421018fc8b54a221c4d6c462e75..3dbc718fde84be4126db5f030230e2c2ecac2970 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Normally we want the overview of all registered theme_check
 $mode = "overview";
@@ -67,7 +67,7 @@ if (($response[count($response) - 1] == "[EOF]") && ($response[0] != "[EOF]")) {
        // Get count of theme_check for validation
        $count = trim($response[count($response) - 2]);
        foreach ($response as $idx => $value) {
-               $value = str_replace("\n", "", $value); $ver = "";
+               $value = str_replace("\n", '', $value); $ver = '';
 
                // Leave loop when data is invalid or EOF?
                if ((substr($value, 0, 6) == "theme-") && (substr($value, -4) == ".zip")) {
@@ -118,7 +118,7 @@ if (($response[count($response) - 1] == "[EOF]") && ($response[0] != "[EOF]")) {
                array_pk_sort($THEMES, array("cver", "fname"), 0, 1);
 
                // Extensions where found which are not downloaded and installed
-               $OUT = ""; $SW = 2; $TSIZE = 0;
+               $OUT = ''; $SW = 2; $TSIZE = 0;
                foreach ($THEMES['fname'] as $idx => $name) {
                        // Generate download link
                        $LINK = SERVER_URL."/themes/theme-".$name.".zip";
@@ -152,7 +152,7 @@ if (($response[count($response) - 1] == "[EOF]") && ($response[0] != "[EOF]")) {
        }
 } else {
        // No theme where found
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_THEME_NOTHING_FOUND'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_THEME_NOTHING_FOUND'));
 }
 
 //
index 1aab5bbd916219c730a7c70f3da8fd842730fcbb..0db3702c6f3d0b57b2cd83c8d672c2004656007c 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("theme")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "theme");
+} elseif (!EXT_IS_ACTIVE('theme')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'theme');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Check for selected themes
 $SEL = 0;
 if (REQUEST_ISSET_POST('sel')) $SEL = SELECTION_COUNT(REQUEST_POST('sel'));
 if ($SEL > 0) {
-       $OUT = "";
+       $OUT = '';
        foreach (REQUEST_POST('sel') as $id => $sel) {
-               $sql = "";
+               $sql = '';
                // Shall I de-/activate or delete themes?
                if (REQUEST_ISSET_POST(('status'))) {
                        // Change status
-                       if (REQUEST_POST('active', $id) == "Y") {
+                       if (REQUEST_POST('active', $id) == 'Y') {
                                $sql = "UPDATE `{!_MYSQL_PREFIX!}_themes` SET theme_active='N' WHERE id='".$id."' LIMIT 1";
                        } else {
                                $sql = "UPDATE `{!_MYSQL_PREFIX!}_themes` SET theme_active='Y' WHERE id='".$id."' LIMIT 1";
@@ -98,10 +98,10 @@ if ($SEL > 0) {
 }
 
 // Switch to testing mode
-$GLOBALS['theme_mode'] = "test";
+$GLOBALS['theme_mode'] = 'test';
 
 // Generate output lines for the template
-$OUT = ""; $SW = 2;
+$OUT = ''; $SW = 2;
 $result = SQL_QUERY("SELECT id, theme_path, theme_active, theme_ver, theme_name FROM `{!_MYSQL_PREFIX!}_themes` ORDER BY theme_path", __FILE__, __LINE__);
 if (SQL_NUMROWS($result) > 0) {
        while ($content = SQL_FETCHARRAY($result)) {
@@ -140,7 +140,7 @@ if (SQL_NUMROWS($result) > 0) {
                // No themes found???
        $OUT .= "<tr>
   <td colspan=\"7\" class=\"bottom2\" height=\"60\">
-    ".LOAD_TEMPLATE("admin_settings_saved", true, getMessage('ADMIN_NO_THEMES_FOUND'))."
+    ".LOAD_TEMPLATE('admin_settings_saved', true, getMessage('ADMIN_NO_THEMES_FOUND'))."
   </td>
 </tr>\n";
 }
index 6d27c505d7c2dd2b1e8a1d3f1609aae91f1c7987..e3b86ad2ec95f14e81f78cf0cdbd7c8010329529 100644 (file)
 if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("theme")) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "theme");
+} elseif (!EXT_IS_ACTIVE('theme')) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'theme');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Switch to testing mode
-$GLOBALS['theme_mode'] = "test";
+$GLOBALS['theme_mode'] = 'test';
 
 // Import selected theme if not present
 if (REQUEST_ISSET_POST(('theme'))) {
@@ -81,7 +81,7 @@ VALUES ('%s','N','%s','%s')",
        }
 
        // Output message
-       LOAD_TEMPLATE("admin_settings_saved", false, $msg);
+       LOAD_TEMPLATE('admin_settings_saved', false, $msg);
 } // END - if
 
 // Initialize array
@@ -122,7 +122,7 @@ closedir($handle);
 array_pk_sort($THEMES, array("theme_name"));
 
 // Generate output lines for the template
-$OUT = ""; $SW = 2;
+$OUT = ''; $SW = 2;
 foreach ($THEMES['theme_unix'] as $key => $unix) {
        // Already installed is default
        $FOUND = "<div class=\"admin_note\">{--ADMIN_THEME_ALREADY_INSTALLED--}</div>";
@@ -155,7 +155,7 @@ foreach ($THEMES['theme_unix'] as $key => $unix) {
 
 if (empty($OUT)) {
        // No themes found???
-       $OUT .= LOAD_TEMPLATE("admin_theme_import_none", true, LOAD_TEMPLATE("admin_settings_saved", true, getMessage('ADMIN_NO_THEMES_FOUND')));
+       $OUT .= LOAD_TEMPLATE("admin_theme_import_none", true, LOAD_TEMPLATE('admin_settings_saved', true, getMessage('ADMIN_NO_THEMES_FOUND')));
 } // END - if
 
 // Set the generated list
index a55a9aab893ded6bc7f0e33fd5b3fcc9c86d0f8f..8372ab522810ec14bb247c9f324ee5f7c77c1914 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Define some variables
 global $DATA;
@@ -90,13 +90,13 @@ LIMIT 1",
                                        SQL_FREERESULT($result);
 
                                        // Is the surfbar installed?
-                                       if ((EXT_IS_ACTIVE("surfbar")) && (getConfig('surfbar_migrate_order') == "Y")) {
+                                       if ((EXT_IS_ACTIVE('surfbar')) && (getConfig('surfbar_migrate_order') == 'Y')) {
                                                // Then "migrate" the URL to the surfbar
                                                SURFBAR_ADMIN_MIGRATE_URL($DATA['url'], $DATA['sender']);
                                        } // END - if
 
                                        // Check for bonus extension version >= 0.4.4 for the order bonus
-                                       if ((GET_EXT_VERSION("bonus") >= "0.4.4") && (getConfig('bonus_active') == "Y")) {
+                                       if ((GET_EXT_VERSION('bonus') >= '0.4.4') && (getConfig('bonus_active') == 'Y')) {
                                                // Add points directly
                                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET bonus_order=bonus_order+".getConfig('bonus_order')." WHERE userid=%s LIMIT 1",
                                                        array(bigintval($DATA['sender'])), __FILE__, __LINE__);
@@ -125,11 +125,11 @@ LIMIT 1",
                }
 
                // Mails unlocked for mail delivery
-               LOAD_TEMPLATE("admin_settings_saved", false, $message);
+               LOAD_TEMPLATE('admin_settings_saved', false, $message);
        } elseif (REQUEST_ISSET_POST(('reject'))) {
                if ($SEL > 0) {
                        // Reject mail orders
-                       $OUT = ""; $SW = 2;
+                       $OUT = ''; $SW = 2;
                        foreach (REQUEST_POST('sel') as $id => $value) {
                                // Secure ID number
                                $id = bigintval($id);
@@ -172,9 +172,9 @@ LIMIT 1",
                        LOAD_TEMPLATE("admin_unlock_emails_redir");
                } else {
                        // Nothing selected
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_MAILS_NOTHING_CHECKED'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_MAILS_NOTHING_CHECKED'));
                }
-       } elseif ((REQUEST_ISSET_POST(('lock'))) && ($SEL > 0) && (getConfig('url_blacklist') == "Y")) {
+       } elseif ((REQUEST_ISSET_POST(('lock'))) && ($SEL > 0) && (getConfig('url_blacklist') == 'Y')) {
                // Lock URLs
                foreach (REQUEST_POST('sel') as $id => $url) {
                        // Secure id number
@@ -194,10 +194,10 @@ LIMIT 1",
                } // END - foreach
 
                // Output message
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_URLS_BLOCKED'));
-       } elseif ((!REQUEST_ISSET_POST(('lock'))) && (!REQUEST_ISSET_POST(('accept'))) && (!REQUEST_ISSET_POST(('reject'))) && (getConfig('url_blacklist') == "Y")) {
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_URLS_BLOCKED'));
+       } elseif ((!REQUEST_ISSET_POST(('lock'))) && (!REQUEST_ISSET_POST(('accept'))) && (!REQUEST_ISSET_POST(('reject'))) && (getConfig('url_blacklist') == 'Y')) {
                // Mail orders are in pool so we can display them
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result_main)) {
                        // Prepare data for the template
                        $content = array(
@@ -227,21 +227,21 @@ LIMIT 1",
 
                // Prepare rejection URL
                $REJECT = "http://";
-               if (GET_EXT_VERSION("other") >= "0.1.6") $REJECT = getConfig('reject_url');
+               if (GET_EXT_VERSION('other') >= '0.1.6') $REJECT = getConfig('reject_url');
                define('__REJECT_URL', $REJECT);
 
                // Load main template
                LOAD_TEMPLATE("admin_unlock_emails");
        } elseif ((REQUEST_ISSET_POST(('lock'))) && (getConfig('url_blacklist') != "Y")) {
                // URL blacklist not activated
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_URL_BLACKLIST_DISABLED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_URL_BLACKLIST_DISABLED'));
        } else {
                // Wrong call!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_WRONG_CALL'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_WRONG_CALL'));
        }
 } else {
        // No mail orders fond
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_NO_MAILS_IN_POOL'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_NO_MAILS_IN_POOL'));
 }
 
 //
index 226cf206b377e7d97fcd70a4344ac9ad919d1cf8..7b90daf6fe65b494c0728ba6d4106a631ed1473d 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Check if admin has submitted form
 if (IS_FORM_SENT()) {
@@ -136,7 +136,7 @@ WHERE id='%s' LIMIT 1",
                                        $REFERRAL = SQL_FETCHARRAY($result);
 
                                        // Send warnings out?
-                                       if ($REFERRAL['receive_warnings'] == "Y") {
+                                       if ($REFERRAL['receive_warnings'] == 'Y') {
                                                // Translate some data
                                                $REFERRAL['points']     = TRANSLATE_COMMA($REFERRAL['points']);
                                                $REFERRAL['ref_points'] = TRANSLATE_COMMA(getConfig('sponsor_ref_points'));
@@ -163,7 +163,7 @@ WHERE id='%s' LIMIT 1",
                }
        } else {
                // Nothing selected
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SPONSOR_NONE_SELECTED_UNLOCK'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SPONSOR_NONE_SELECTED_UNLOCK'));
        }
 
        // Add seperator
@@ -182,7 +182,7 @@ ORDER BY
 
 if (SQL_NUMROWS($result) > 0) {
        // Entries found so let's list them!
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // Transfer data to array
                // @TODO Rewritings: remote->remote_addr, created->sponsor_created in template
@@ -207,7 +207,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("admin_unlock_sponsor");
 } else {
        // No pending accounts found
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SPONSOR_NONE_PENDING'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SPONSOR_NONE_PENDING'));
 }
 
 // Free memory
index 44dbce23a9db56b54bcf1668fd94ae17083bed82..b65b1895f113548ce4259035f26f2534301f5a9b 100644 (file)
@@ -43,26 +43,26 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 } // END - if
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Is the form sent?
 if ((REQUEST_ISSET_POST(('unlock'))) && (is_array(REQUEST_POST('id'))) && (count(REQUEST_POST('id')) > 0)) {
        // Unlock selected URLs
        if (SURFBAR_ADMIN_UNLOCK_URL_IDS(REQUEST_POST('id'))) {
                // Unlock done! :-)
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_UNLOCK_DONE'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_UNLOCK_DONE'));
        } else {
                // Unlock failed!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_UNLOCK_FAILED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_UNLOCK_FAILED'));
        }
 } elseif ((REQUEST_ISSET_POST(('reject'))) && (is_array(REQUEST_POST('id'))) && (count(REQUEST_POST('id')) > 0)) {
        // Reject selected URLs
        if (SURFBAR_ADMIN_REJECT_URL_IDS(REQUEST_POST('id'))) {
                // Unlock done! :-)
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_UNLOCK_DONE'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_UNLOCK_DONE'));
        } else {
                // Unlock failed!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_UNLOCK_FAILED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_UNLOCK_FAILED'));
        }
 }
 
@@ -75,7 +75,7 @@ ORDER BY `id` ASC", __FILE__, __LINE__);
 // Do we have some URLs left?
 if (SQL_NUMROWS($result) > 0) {
        // List all URLs
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                // "Translate"/add content
                $content['sw']          = $SW;
@@ -94,7 +94,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("admin_unlock_surfbar_urls", false, $OUT);
 } else {
        // No URLs in surfbar
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_SURFBAR_NO_URLS_FOUND'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_SURFBAR_NO_URLS_FOUND'));
 }
 
 // Free result
index 2c666437b1bf2ac47fe780b182f5210ab7327102..835ede7ef24f6e9edd2c31f79fc9c9562b321a38 100644 (file)
@@ -43,7 +43,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Init array
 $ONLINE['code'] = "???";
@@ -53,7 +53,7 @@ $response = GET_URL("check-updates3.php");
 
 if (empty($response[0]) && empty($response[1]) && empty($response[2]) && empty($response[3])) {
        // Error!
-       $response = array("", "", "");
+       $response = array("", '', '');
 } else {
        // Analyse header for response code
        if (eregi("200 OK", $response[0])) {
@@ -76,9 +76,9 @@ if (empty($response[0]) && empty($response[1]) && empty($response[2]) && empty($
 
                // Which is the latest version on server?
                $ONLINE = array(
-                       'version'  => str_replace("\n", "", $response[0]),
-                       'changed'  => str_replace("\n", "", $response[1]),
-                       'revision' => str_replace("\n", "", $response[2]),
+                       'version'  => str_replace("\n", '', $response[0]),
+                       'changed'  => str_replace("\n", '', $response[1]),
+                       'revision' => str_replace("\n", '', $response[2]),
                );
 
                // Array for available patches
@@ -90,23 +90,23 @@ if (empty($response[0]) && empty($response[1]) && empty($response[2]) && empty($
 
                if (($response[3] != "[EOF]") && ($ONLINE['version'] == constant('FULL_VERSION'))) {
                        // We have found new patches (newer than FULL_VERSION)
-                       $max = str_replace("\n", "", $response[count($response) - 2]); $totalSize = 0;
+                       $max = str_replace("\n", '', $response[count($response) - 2]); $totalSize = 0;
 
                        // Maximum of available pacthes extracted (above). Now we can get all informations
                        for ($idx = 0; $idx < $max; $idx++) {
                                // List only newer patches
-                               $TEST = substr(str_replace("\n", "", $response[$idx * 5 + 2]), 0, strlen(getConfig('patch_level')));
+                               $TEST = substr(str_replace("\n", '', $response[$idx * 5 + 2]), 0, strlen(getConfig('patch_level')));
 
                                // I have removed the addional test for the stored timemark in database or you cannot find
                                // new updates on my server when you haven't installed it before I upload a patch... :-(
                                if (bigintval($TEST) > getConfig(('patch_level'))) {
                                        // Copy every data from the response array
-                                       $PATCHES['fname'][] = str_replace("\n", "", $response[$idx * 5 + 2]);
-                                       $PATCHES['fsize'][] = str_replace("\n", "", $response[$idx * 5 + 3]);
-                                       $PATCHES['ctime'][] = str_replace("\n", "", $response[$idx * 5 + 4]);
+                                       $PATCHES['fname'][] = str_replace("\n", '', $response[$idx * 5 + 2]);
+                                       $PATCHES['fsize'][] = str_replace("\n", '', $response[$idx * 5 + 3]);
+                                       $PATCHES['ctime'][] = str_replace("\n", '', $response[$idx * 5 + 4]);
                                        switch (GET_LANGUAGE()) {
-                                               case "de": $PATCHES['descr'][] = str_replace("\n", "", $response[$idx * 5 + 5]); break; // Load german description
-                                               default  : $PATCHES['descr'][] = str_replace("\n", "", $response[$idx * 5 + 6]); break; // Load english description as default
+                                               case "de": $PATCHES['descr'][] = str_replace("\n", '', $response[$idx * 5 + 5]); break; // Load german description
+                                               default  : $PATCHES['descr'][] = str_replace("\n", '', $response[$idx * 5 + 6]); break; // Load english description as default
                                        }
 
                                        // Add patch's size to total
@@ -128,7 +128,7 @@ if (empty($response[0]) && empty($response[1]) && empty($response[2]) && empty($
 // Is a newer version available?
 if (empty($ONLINE['version'])) {
        // Disconnected?
-       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"admin_failed\">{--ADMIN_CANNOT_CHECK_VERSION--} (".$ONLINE['code'].")</div>");
+       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"admin_failed\">{--ADMIN_CANNOT_CHECK_VERSION--} (".$ONLINE['code'].")</div>");
 } elseif (($ONLINE['version'] != constant('FULL_VERSION')) || ($ONLINE['revision'] != constant('CURR_SVN_REVISION'))) {
        // New full-version available (all previous released patches are included in this version!)
        define('__ONLINE_VERSION', $ONLINE['version']);
@@ -139,7 +139,7 @@ if (empty($ONLINE['version'])) {
        LOAD_TEMPLATE("admin_update_download");
 } else {
        // You have the latest version!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('NO_UPDATES_AVAILABLE'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('NO_UPDATES_AVAILABLE'));
 }
 
 //
index a43d17ce659f6796527d4ffc1c6810d43c967ef0..2714604717be46b7c8bbb6d974684acfab568dfa 100644 (file)
@@ -43,13 +43,13 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Base directory (should be moved to database)
 $usage = getConfig('usage_base')."/";
 
 if (REQUEST_ISSET_GET(('image'))) {
-       if (REQUEST_GET('type') == "usage") {
+       if (REQUEST_GET('type') == 'usage') {
                $FQFN = sprintf("%s%s/usage.png",
                        constant('PATH'),
                        getConfig('usage_base')
@@ -97,7 +97,7 @@ if ((!empty($FQFN)) && (FILE_READABLE($FQFN))) {
        $content = str_replace("daily_usage_", "{!URL!}/modules.php?module=admin&amp;what=".$GLOBALS['what']."&type=daily&image=", $content);
        $content = str_replace("hourly_usage_", "{!URL!}/modules.php?module=admin&amp;what=".$GLOBALS['what']."&type=hourly&image=", $content);
        $content = str_replace("ctry_usage_", "{!URL!}/modules.php?module=admin&amp;what=".$GLOBALS['what']."&type=ctry&image=", $content);
-       $content = str_replace("usage_", "{!URL!}/modules.php?module=admin&amp;what=".$GLOBALS['what']."&usage=", str_replace(".html", "", $content));
+       $content = str_replace("usage_", "{!URL!}/modules.php?module=admin&amp;what=".$GLOBALS['what']."&usage=", str_replace(".html", '', $content));
 
        // Disabled due to too much trouble
        //$content = str_replace("HREF=\"http://", "href=\"{!URL!}/modules.php?module=loader&amp;url=http://", $content);
@@ -115,8 +115,8 @@ if ((!empty($FQFN)) && (FILE_READABLE($FQFN))) {
   ".$content."
 </div>");
 } else {
-       // Nothing to load, then we have no directory "usage"
-       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('ADMIN_USAGE_DIRECTORY_404'), getConfig('usage_base')));
+       // Nothing to load, then we have no directory 'usage'
+       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('ADMIN_USAGE_DIRECTORY_404'), getConfig('usage_base')));
 }
 
 //
index 8be804d5c21fe6f29282ec444461201fd97b7678..14c018a7c138d6552948a670f789a2da071646eb 100644 (file)
@@ -43,10 +43,10 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Is a user id given?
-if ((REQUEST_ISSET_GET(('uid'))) && (bigintval(REQUEST_GET('uid')) > 0)) {
+if ((REQUEST_ISSET_GET('uid')) && (bigintval(REQUEST_GET('uid')) > 0)) {
        // Load user data and display it
        $result = SQL_QUERY_ESC("SELECT surname, family, email FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
                array(bigintval(REQUEST_GET('uid'))), __FILE__, __LINE__);
@@ -67,14 +67,14 @@ if ((REQUEST_ISSET_GET(('uid'))) && (bigintval(REQUEST_GET('uid')) > 0)) {
                        // Send contact form out
                        $msg = LOAD_EMAIL_TEMPLATE("member_contct", $content);
                        SEND_EMAIL($content['email'], getMessage('ADMIN_CONTACT_USER_SUBJECT'), $msg);
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_USER_CONTACTED'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_USER_CONTACTED'));
                } else {
                        // Load contact form template
                        LOAD_TEMPLATE("admin_contct_user_form", false, $content);
                }
        } else {
                // Not found?
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(USER_ACCOUNT_404, bigintval(REQUEST_GET('uid'))));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(USER_ACCOUNT_404, bigintval(REQUEST_GET('uid'))));
        }
 
        // Free result
index 49cfbc878b132cd3cfb44a8adc602c635a0122de..c6b71d0673275d55f5dd260c7b73a0a356e3dc16 100644 (file)
@@ -43,16 +43,16 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 }
 
 // Add description as navigation point
-ADD_DESCR("admin", __FILE__);
+ADD_DESCR('admin', __FILE__);
 
 // Online stats are only working if extension ext-online is installed
-if (EXT_IS_ACTIVE("online")) {
+if (EXT_IS_ACTIVE('online')) {
        // Count guests, members and admins
        // @TODO Rewrite these constants
        // @TODO Add a filter for sponsor
-       define('_GUESTS_ONLINE' , GET_TOTAL_DATA("N", "online", "id", "is_admin", true, " AND is_member='N'"));
-       define('_ADMINS_ONLINE' , GET_TOTAL_DATA("N", "online", "id", "is_admin", true, " AND is_member='Y'"));
-       define('_MEMBERS_ONLINE', GET_TOTAL_DATA("N", "online", "id", "is_admin", true));
+       define('_GUESTS_ONLINE' , GET_TOTAL_DATA("N", 'online', "id", "is_admin", true, " AND is_member='N'"));
+       define('_ADMINS_ONLINE' , GET_TOTAL_DATA("N", 'online', "id", "is_admin", true, " AND is_member='Y'"));
+       define('_MEMBERS_ONLINE', GET_TOTAL_DATA("N", 'online', "id", "is_admin", true));
 
        // Load template
        LOAD_TEMPLATE("admin_mini_online");
@@ -71,10 +71,10 @@ if (EXT_IS_ACTIVE("online")) {
                        if (empty($content['action'])) $content['action'] = "---";
                        if (empty($content['what']))   $content['what']   = "---";
 
-                       if ($content['is_admin'] == "Y") {
+                       if ($content['is_admin'] == 'Y') {
                                // Is an administrator
                                $content['userid'] = getMessage('_IS_ADMIN');
-                       } elseif (($content['is_member'] == "N") && ($content['is_admin'] == "N")) {
+                       } elseif (($content['is_member'] == 'N') && ($content['is_admin'] == 'N')) {
                                // Is a guest
                                $content['userid'] = getMessage('_IS_GUEST');
                        } elseif ($content['userid'] > 0) {
@@ -112,7 +112,7 @@ if (EXT_IS_ACTIVE("online")) {
        } // END - if
 } else {
        // Online statistics deactivated!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ONLINE_STATISTICS_DEACTIVATED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ONLINE_STATISTICS_DEACTIVATED'));
 }
 
 //
index 3dc66760420cf8085ae033e5a7c3c0ac4aa192bb..8d46fd5d7d3f50a34748ce48d45e0009cd887dd4 100644 (file)
@@ -48,8 +48,8 @@ $message = "<strong>{--VALIDATING_LOGIN--}</strong>";
 if (isUserIdSet() && (isSessionVariableSet('u_hash'))) {
        // Login failures are supported since 0.4.7
        // Do we have 0.4.7 of sql_patches or later?
-       $add = "";
-       if (GET_EXT_VERSION("sql_patches") >= "0.6.1") {
+       $add = '';
+       if (GET_EXT_VERSION('sql_patches') >= '0.6.1') {
                // Load them here
                $add = ", login_failures, UNIX_TIMESTAMP(last_failure) AS last_failure";
        } // END - if
@@ -68,7 +68,7 @@ if (isUserIdSet() && (isSessionVariableSet('u_hash'))) {
        set_session('mxchange_theme', $data['curr_theme']);
 
        // Remmeber login failures if available
-       if (GET_EXT_VERSION("sql_patches") >= "0.6.1") {
+       if (GET_EXT_VERSION('sql_patches') >= '0.6.1') {
                // Reset login failures
                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data`
 SET login_failures=0, last_failure='0000-00-00 00:00:00'
@@ -83,7 +83,7 @@ LIMIT 1",
 
        // Bonus is not given by default ;-)
        $bonus = false;
-       if ((GET_EXT_VERSION("sql_patches") >= "0.2.8") && (GET_EXT_VERSION("bonus") >= "0.2.1") && (getConfig('bonus_login_yn') == "Y")) {
+       if ((GET_EXT_VERSION('sql_patches') >= '0.2.8') && (GET_EXT_VERSION('bonus') >= '0.2.1') && (getConfig('bonus_login_yn') == 'Y')) {
                // Update last login if far enougth away
                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data`
 SET last_login=UNIX_TIMESTAMP()
@@ -97,12 +97,12 @@ LIMIT 1",
                if (SQL_AFFECTEDROWS() == 1) $bonus = true;
        } // END - if
 
-       if (($bonus) && (REQUEST_GET('mode') == "bonus") && (EXT_IS_ACTIVE("bonus"))) {
+       if (($bonus) && (REQUEST_GET('mode') == 'bonus') && (EXT_IS_ACTIVE('bonus'))) {
                // Output message with added points
                $message .= "<div class=\"tiny\">
   ".sprintf(getMessage('BONUS_LOGIN_BONUS_ADDED'), TRANSLATE_COMMA(getConfig('login_bonus')))."
 </div>";
-       } elseif (EXT_IS_ACTIVE("bonus")) {
+       } elseif (EXT_IS_ACTIVE('bonus')) {
                // No login bonus added!
                $message .= "<div class=\"member_failed\">{--BONUS_LOGIN_BONUS_NOT_ADDED--}</div>";
        }
@@ -115,7 +115,7 @@ LIMIT 1",
 }
 
 // Output final message
-LOAD_TEMPLATE("admin_settings_saved", false, $message);
+LOAD_TEMPLATE('admin_settings_saved', false, $message);
 
 //
 ?>
index 83e71cab9c5dda9cd28f36860cc315fcae9e6307..0aaff8376ee67ff118fa0f34a352915d6370a457 100644 (file)
@@ -42,7 +42,7 @@ if (!defined('__SECURITY')) {
        require($INC);
 }
 
-$MODE = "guest";
+$MODE = 'guest';
 
 if (REQUEST_ISSET_GET(('order'))) {
        // Order number placed, is he also logged in?
@@ -60,7 +60,7 @@ if (REQUEST_ISSET_GET(('order'))) {
                        REQUEST_SET_POST('url', $url);
 
                        // Mode is member
-                       $MODE = "member";
+                       $MODE = 'member';
                } else {
                        // Matching line not found!
                        LOAD_URL("modules.php?module=index&amp;what=login");
@@ -85,21 +85,21 @@ if ((REQUEST_ISSET_POST(('url'))) || (REQUEST_ISSET_GET(('url'))) || (REQUEST_IS
        if (REQUEST_ISSET_POST(('url'))) $url = REQUEST_POST('url');
 
        // Add missing element
-       $frame = "";
+       $frame = '';
        if (REQUEST_ISSET_GET(('frame'))) $frame = REQUEST_GET(('frame'));
        switch ($frame)
        {
        case "":
                switch ($MODE)
                {
-               case "member":
+               case 'member':
                        // Build frameset
                        define('__ORDER_VALUE', bigintval(REQUEST_GET('order')));
                        define('__URL_VALUE'  , DEREFERER($url));
                        LOAD_TEMPLATE("member_order_frametester");
                        break;
 
-               case "guest":
+               case 'guest':
                        define('__URL_VALUE'  , DEREFERER($url));
                        LOAD_TEMPLATE("guest_frametester");
                        break;
@@ -107,7 +107,7 @@ if ((REQUEST_ISSET_POST(('url'))) || (REQUEST_ISSET_GET(('url'))) || (REQUEST_IS
                break;
 
        case "test_top":
-               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"guest_done\">{--GUEST_FRAMETESTER_TOP--}</span>");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"guest_done\">{--GUEST_FRAMETESTER_TOP--}</span>");
                break;
 
        case "back": // Back buttom
index 522ae20067107ac1810c91bf8d96418d351ae5b8..6b2b663a99477a37fe0f38b1ce831fd029c467bd 100644 (file)
@@ -49,7 +49,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/guest/what-%s.php", $GLOBALS['what']);
index a04f127f236e46e35aa662851623ef134c1974de..7e10580e9a30c9003dd661def749508f5b0feb23 100644 (file)
@@ -46,7 +46,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/guest/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 9737e3d9babf707a78667f44d88f0b3ca78dae96..6a3562f94f08d0f9e8051b4669941f045ddbf596 100644 (file)
@@ -46,7 +46,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/guest/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index b398f9f035cb3fda7814c3318a18aae5d6956eb3..c9eae3ed2e8576341ffe49cc67028231e743fe22 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("online")) && (!IS_ADMIN())) {
+} elseif ((!EXT_IS_ACTIVE('online')) && (!IS_ADMIN())) {
        // Just skip this extension
        return;
 }
 
 // Total visitors online
-$total = GET_TOTAL_DATA("", "online", "id", "userid", true);
+$total = GET_TOTAL_DATA("", 'online', "id", 'userid', true);
 
 if (getConfig('mad_count') < $total) {
        // Update counter
@@ -55,9 +55,9 @@ if (getConfig('mad_count') < $total) {
 
 // Prepare content
 $content = array(
-       'guests'  => TRANSLATE_COMMA(GET_TOTAL_DATA("N", "online", "id", "is_admin", true, " AND is_member='N'")),
-       'members' => TRANSLATE_COMMA(GET_TOTAL_DATA("N", "online", "id", "is_admin", true, " AND is_member='Y'")),
-       'admins'  => TRANSLATE_COMMA(GET_TOTAL_DATA("Y", "online", "id", "is_admin", true)),
+       'guests'  => TRANSLATE_COMMA(GET_TOTAL_DATA("N", 'online', "id", "is_admin", true, " AND is_member='N'")),
+       'members' => TRANSLATE_COMMA(GET_TOTAL_DATA("N", 'online', "id", "is_admin", true, " AND is_member='Y'")),
+       'admins'  => TRANSLATE_COMMA(GET_TOTAL_DATA("Y", 'online', "id", "is_admin", true)),
        'total'   => TRANSLATE_COMMA($total)
 );
 
index 09855e1943a72b1890588c7779cc1d93822e26cb..fd6cec7c5ad34967bce6ad56b7be8c944178a943 100644 (file)
@@ -39,8 +39,8 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("sponsor")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "sponsor");
+} elseif ((!EXT_IS_ACTIVE('sponsor')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'sponsor');
        return;
 } elseif ($GLOBALS['block_mode']) {
        // Block mode detected
@@ -48,7 +48,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/guest/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 21bb26bd160d5e887379411ba1a312b5592bcf96..3c9a09c57351cba6bf1d6cf9f9dce99f878a6e96 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("theme")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "theme");
+} elseif ((!EXT_IS_ACTIVE('theme')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'theme');
        return;
 }
 
 // Load all active designs (or all if admin)
-$whereStatement = ""; $OUT = "";
+$whereStatement = ''; $OUT = '';
 if (!IS_ADMIN()) $whereStatement = " WHERE theme_active='Y'";
 $result_themes = SQL_QUERY("SELECT theme_path FROM `{!_MYSQL_PREFIX!}_themes`".$whereStatement, __FILE__, __LINE__);
 $num_themes = SQL_NUMROWS($result_themes);
 
 if ($num_themes > 1) {
        // If more than 1 is installed output selection box
-       $act = "";
+       $act = '';
        if (!empty($GLOBALS['action'])) $act = SQL_ESCAPE($GLOBALS['action']);
-       $OUT = THEME_SELECTION_BOX("index", $act, $GLOBALS['what'], $result_themes);
+       $OUT = THEME_SELECTION_BOX('index', $act, $GLOBALS['what'], $result_themes);
 } elseif (($num_themes == 1) || ((!IS_ADMIN()) && ($num_themes == 0))) {
        // If there's only one just print it's name
        define('__THEME_NAME', GET_CURR_THEME_NAME());
        $OUT = LOAD_TEMPLATE("theme_one", true);
 } elseif (IS_ADMIN()) {
        // If there is no theme installed and there's an admin notify him!
-       $OUT = LOAD_TEMPLATE("admin_settings_saved", true, "<div class=\"admin_note\">{--ADMIN_NO_THEME_INSTALLED_WARNING--}</div>");
+       $OUT = LOAD_TEMPLATE('admin_settings_saved', true, "<div class=\"admin_note\">{--ADMIN_NO_THEME_INSTALLED_WARNING--}</div>");
 }
 
 // Free memory
index 6419247938cd8c47d84584aded7354cdb50329d1..2a65f889222d6f50d832e1f61c2a3ca12e1c00a4 100644 (file)
@@ -43,7 +43,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Load default template
 LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));
index 4aff32af452894acc55eb39c7113e370649b1d30..10d5537eb303e539c8ed9f23a4ca9efe93aad500 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("active")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "active");
+} elseif ((!EXT_IS_ACTIVE('active')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'active');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Extra field to include is by default uid
-$add = "userid";
+$add = 'userid';
 
 // If nickname is installed the extra field is the nickname of the user
-if (EXT_IS_ACTIVE("nickname")) $add = "nickname";
+if (EXT_IS_ACTIVE('nickname')) $add = 'nickname';
 
 // Check for members who were active only this day
 $result = SQL_QUERY_ESC("SELECT userid, ".$add.", last_online
@@ -64,7 +64,7 @@ ORDER BY last_online DESC LIMIT %s",
 // Entries found?
 if (SQL_NUMROWS($result) > 0) {
        // At least one member was online so let's load them all
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while (list($uid, $nick, $last) = SQL_FETCHROW($result)) {
                $nick2 = "---";
                if (($nick != $uid) && (!empty($nick))) $nick2 = $nick;
index 618f29678fe6524c625a5842a0455fab8f0fd08d..c37d63b9bd27452181d862b53d098d2ffbe2a80c 100644 (file)
@@ -43,7 +43,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR ("guest", basename(__FILE__));
+ADD_DESCR ('guest', basename(__FILE__));
 
 // Load default template
 LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));
index fca40096cfad3ab3da7934f08c7521d322957132..413f0240099e178ee6802f371abb726003f986b8 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("beg")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "beg");
+} elseif ((!EXT_IS_ACTIVE('beg')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'beg');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Prepare constants
 define('__BEG_POINTS'    , TRANSLATE_COMMA(getConfig('beg_points')));
index 5ef60b9c4e89752adb59d785319481e1ece677b0..052eea42e1aefb8537e91eed933f89aa514bc2c4 100644 (file)
@@ -43,7 +43,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 if (REQUEST_ISSET_GET(('hash'))) {
        // Initialize the user ID
@@ -87,7 +87,7 @@ if (REQUEST_ISSET_GET(('hash'))) {
                                        }
 
                                        // If version matches add ref bonus to refid's account
-                                       if ((GET_EXT_VERSION("bonus") >= "0.4.4") && (getConfig('bonus_active') == "Y")) {
+                                       if ((GET_EXT_VERSION('bonus') >= '0.4.4') && (getConfig('bonus_active') == 'Y')) {
                                                // Add points (directly only!)
                                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET bonus_ref=bonus_ref+%s WHERE userid=%s LIMIT 1",
                                                        array(getConfig('bonus_ref'), bigintval($rid)), __FILE__, __LINE__);
@@ -102,7 +102,7 @@ if (REQUEST_ISSET_GET(('hash'))) {
                                } // END - if
                        } // END - if
 
-                       if (EXT_IS_ACTIVE("rallye")) {
+                       if (EXT_IS_ACTIVE('rallye')) {
                                // Add user to rallye (or not?)
                                RALLYE_AUTOADD_USER(bigintval($uid));
                        } // END - if
index cdad4cf365684154f8758e1953027450d5dfc7b6..1df171d1cc62367c9a8cb15146d3f2eed23a4e4a 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("doubler")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "doubler");
+} elseif ((!EXT_IS_ACTIVE('doubler')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'doubler');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Percent values etc.
 define('__CHARGE_VALUE', TRANSLATE_COMMA(getConfig('doubler_charge') * 100));
index 02c8b5f26a371e969846bb31228dc499842b3a9b..d6ef1a33187ba3ca0cd140bc11e071c39b925e12 100644 (file)
@@ -43,7 +43,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Load template template
 LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));
index 519117de978f80122a2c3b42140190279c29e40d..1ecf6fbd2ae16e93c354d2bcaf7c4ff4d96ba183 100644 (file)
@@ -43,7 +43,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Load default template
 LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));
index bcea77ddb74a573b2211d33112a8967fad3c92f7..822a6f6f5a92f52d30d5210c49756fe7e4492400 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("user")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "user");
+} elseif ((!EXT_IS_ACTIVE('user')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'user');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 global $DATA;
 
@@ -55,9 +55,9 @@ global $DATA;
 $errorCode = 0;
 $probe_nickname = false;
 $uid = false;
-$hash = "";
-$URL = "";
-$add = "";
+$hash = '';
+$URL = '';
+$add = '';
 
 // Already logged in?
 if ((isUserIdSet()) && (isSessionVariableSet('u_hash'))) {
@@ -65,7 +65,7 @@ if ((isUserIdSet()) && (isSessionVariableSet('u_hash'))) {
        $uid = getUserId();
 } elseif ((REQUEST_ISSET_POST(('id'))) && (REQUEST_ISSET_POST(('password'))) && (IS_FORM_SENT())) {
        // Set userid and crypt password when login data was submitted
-       if ((EXT_IS_ACTIVE("nickname")) && (NICKNAME_PROBE_ON_USERID(REQUEST_POST('id')))) {
+       if ((EXT_IS_ACTIVE('nickname')) && (NICKNAME_PROBE_ON_USERID(REQUEST_POST('id')))) {
                // Nickname entered
                $uid = SQL_ESCAPE(REQUEST_POST('id'));
        } else {
@@ -78,12 +78,12 @@ if ((isUserIdSet()) && (isSessionVariableSet('u_hash'))) {
        if (REQUEST_ISSET_POST(('id'))) $uid = REQUEST_POST('id');
 } else {
        // Not logged in
-       $uid = 0; $hash = "";
+       $uid = 0; $hash = '';
 }
 
 // Set unset variables
-if (!REQUEST_ISSET_POST(('new_pass'))) REQUEST_SET_POST('new_pass', "");
-if (!REQUEST_ISSET_GET(('login')))     REQUEST_SET_GET('login'    , "");
+if (!REQUEST_ISSET_POST(('new_pass'))) REQUEST_SET_POST('new_pass', '');
+if (!REQUEST_ISSET_GET(('login')))     REQUEST_SET_GET('login'    , '');
 
 if (IS_MEMBER()) {
        // Login immidiately...
@@ -136,7 +136,7 @@ if (!empty($errorCode)) {
 
                case getCode('EXTENSION_PROBLEM'):
                        if (IS_ADMIN()) {
-                               $message .= sprintf(getMessage('EXTENSION_PROBLEM_NOT_INSTALLED'), "nickname");
+                               $message .= sprintf(getMessage('EXTENSION_PROBLEM_NOT_INSTALLED'), 'nickname');
                        } else {
                                $message .= getMessage('LOGIN_WRONG_ID');
                        }
@@ -154,11 +154,11 @@ if (!empty($errorCode)) {
                define('LOGIN_FAILURE_MSG', $message);
 } else {
        // No problems, no output
-       define('LOGIN_FAILURE_MSG', "");
+       define('LOGIN_FAILURE_MSG', '');
 }
 
 // Display login form with resend-password form
-if (EXT_IS_ACTIVE("nickname")) {
+if (EXT_IS_ACTIVE('nickname')) {
        LOAD_TEMPLATE("guest_nickname_login");
 } else {
        LOAD_TEMPLATE("guest_login");
index a78e3af01da9f19c70315045d30041ff9aa0f023..821d2b507ceae5dd742ed28b0d36ade31ab5e768 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("mediadata")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "mediadata");
+} elseif ((!EXT_IS_ACTIVE('mediadata')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'mediadata');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // @TODO Rewrite all constants
 define('value', "value");
@@ -52,9 +52,9 @@ define('lang', "lang");
 define('rows', "rows");
 
 // Get total confirmed user IDs...
-define('user_confirmed'  , round(GET_TOTAL_DATA("CONFIRMED"  , "user_data", "userid", "status", true)));
-define('user_unconfirmed', round(GET_TOTAL_DATA("UNCONFIRMED", "user_data", "userid", "status", true)));
-define('user_locked'     , round(GET_TOTAL_DATA("LOCKED"     , "user_data", "userid", "status", true)));
+define('user_confirmed'  , round(GET_TOTAL_DATA("CONFIRMED"  , "user_data", 'userid', "status", true)));
+define('user_unconfirmed', round(GET_TOTAL_DATA("UNCONFIRMED", "user_data", 'userid', "status", true)));
+define('user_locked'     , round(GET_TOTAL_DATA("LOCKED"     , "user_data", 'userid', "status", true)));
 define('user_count'      , (constant('user_confirmed') + constant('user_unconfirmed') + constant('user_locked')));
 
 // Start of this exchange
@@ -111,7 +111,7 @@ if (empty($sent))   $sent   = 0;
 if (empty($clicks)) $clicks = 0;
 
 // Bonus mails
-if (EXT_IS_ACTIVE("bonus")) {
+if (EXT_IS_ACTIVE('bonus')) {
        $bmails = MEDIA_GET_ENTRY("bonus_orders");
        if (empty($bmails)) $bmails = 0;
 
@@ -147,7 +147,7 @@ list($ref, $logins) = SQL_FETCHROW($result);
 SQL_FREERESULT($result);
 
 // Get total points
-$points = MEDIA_GET_ENTRY("total_points");
+$points = MEDIA_GET_ENTRY('total_points');
 
 if (empty($points)) $points = 0;
 if (empty($ref))    $ref    = 0;
@@ -178,13 +178,13 @@ define('__REF_CLICKS', $clicks);
 //
 
 // Initialize Variables
-$OUT_EXTRA   = ""; $ROWS_EXTRA   = 2;
-$OUT_POINTS  = ""; $ROWS_POINTS  = 2;
-$OUT_USER    = ""; $ROWS_USER    = 6;
-$OUT_SPECIAL = ""; // We don't need row count here
+$OUT_EXTRA   = ''; $ROWS_EXTRA   = 2;
+$OUT_POINTS  = ''; $ROWS_POINTS  = 2;
+$OUT_USER    = ''; $ROWS_USER    = 6;
+$OUT_SPECIAL = ''; // We don't need row count here
 
 // @TODO Rewrite these all if-blocks to filters
-if (EXT_IS_ACTIVE("beg")) {
+if (EXT_IS_ACTIVE('beg')) {
        // Clicks on beg links
        $result = SQL_QUERY("SELECT SUM(beg_clicks) FROM `{!_MYSQL_PREFIX!}_user_data` WHERE beg_clicks>0", __FILE__, __LINE__);
        list($extra) = SQL_FETCHROW($result);
@@ -198,7 +198,7 @@ if (EXT_IS_ACTIVE("beg")) {
        $ROWS_EXTRA++;
 }
 
-if (EXT_IS_ACTIVE("doubler")) {
+if (EXT_IS_ACTIVE('doubler')) {
        // Total payed points
        $result = SQL_QUERY("SELECT COUNT(id), SUM(points) FROM `{!_MYSQL_PREFIX!}_doubler` WHERE completed='Y' AND points > 0", __FILE__, __LINE__);
        list($count1, $points1) = SQL_FETCHROW($result);
@@ -240,7 +240,7 @@ if (EXT_IS_ACTIVE("doubler")) {
        $OUT_SPECIAL .= LOAD_TEMPLATE("mediadata_extra_row", true, $content);
 }
 
-if (EXT_IS_ACTIVE("holiday")) {
+if (EXT_IS_ACTIVE('holiday')) {
        // Total holiday requests
        $result = SQL_QUERY("SELECT DISTINCT COUNT(h.userid)
 FROM `{!_MYSQL_PREFIX!}_user_holidays` AS h
@@ -258,7 +258,7 @@ WHERE d.holiday_active='Y'",
        $ROWS_USER++;
 }
 
-if (EXT_IS_ACTIVE("transfer")) {
+if (EXT_IS_ACTIVE('transfer')) {
        // Statistics for points transfers
        $result = SQL_QUERY("SELECT DISTINCT COUNT(t.id), SUM(t.points)
 FROM `{!_MYSQL_PREFIX!}_user_transfers_in` AS t
@@ -316,7 +316,7 @@ define('__PATCH_LEVEL', getConfig('patch_level'));
 define('__PATCH_CTIME', MAKE_DATETIME(getConfig('patch_ctime'), "2"));
 
 // Load template
-LOAD_TEMPLATE("mediadata");
+LOAD_TEMPLATE('mediadata');
 
 //
 ?>
index 7d26188eef3a59b664d82a56e6bc65cf5b9fcab1..ea92de1ef1e394982a7b86aa9419fd5e53e4e76b 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("rallye")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "rallye");
+} elseif ((!EXT_IS_ACTIVE('rallye')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'rallye');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 OUTPUT_HTML("<div align=\"center\">");
 
 // Check for possible running rallyes
 $ADMIN = " AND d.is_active='Y'";
-if (IS_ADMIN()) $ADMIN = "";
+if (IS_ADMIN()) $ADMIN = '';
 
 $result = SQL_QUERY("SELECT DISTINCT d.id, d.admin_id, a.login, d.title, d.descr, d.template, d.start_time, d.end_time, d.min_users, d.min_prices
 FROM `{!_MYSQL_PREFIX!}_rallye_data` AS d, `{!_MYSQL_PREFIX!}_admins` AS a
@@ -115,7 +115,7 @@ if (SQL_NUMROWS($result) == 1)
                define('__RALLYE_TOP_USERS', "<div align=\"center\" class=\"big\">".__RALLYE_EXTRAS."</div>");
                define('__RALLYE_CAN_WIN_THIS', RALLYE_OUR_WINNERS_ARE);
        } else {
-               define('__RALLYE_PRICES', RALLYE_ADD_PRICES($id, "html"));
+               define('__RALLYE_PRICES', RALLYE_ADD_PRICES($id, 'html'));
                define('__RALLYE_TOP_USERS', RALLYE_ADD_TOPUSERS($id, getUserId()));
                define('__RALLYE_CAN_WIN_THIS', RALLYE_YOU_CAN_WIN);
        }
index ac19ef31fa39731c4e7130c89c7c773080528e71..d6f386ba95df86746e609b4caf0ed421d45d2b88 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("register"))) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "register");
+} elseif ((!EXT_IS_ACTIVE('register'))) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'register');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 global $DATA;
 
@@ -55,20 +55,20 @@ $FAILED = false; $SHORT_PASS = false; $cats = 0; $IP_TIMEOUT = false;
 
 if (!IS_FORM_SENT()) REQUEST_UNSET_POST('ok');
 
-if (!REQUEST_ISSET_POST(('agree')))        REQUEST_SET_POST('agree'       , "");
-if (!REQUEST_ISSET_POST(('addy')))         REQUEST_SET_POST('addy'        , "");
-if (!REQUEST_ISSET_POST(('surname')))      REQUEST_SET_POST('surname'     , "");
-if (!REQUEST_ISSET_POST(('family')))       REQUEST_SET_POST('family'      , "");
-if (!REQUEST_ISSET_POST(('pass1')))        REQUEST_SET_POST('pass1'       , "");
-if (!REQUEST_ISSET_POST(('pass2')))        REQUEST_SET_POST('pass2'       , "");
-if (!REQUEST_ISSET_POST(('day')))          REQUEST_SET_POST('day'         , "");
-if (!REQUEST_ISSET_POST(('month')))        REQUEST_SET_POST('month'       , "");
-if (!REQUEST_ISSET_POST(('year')))         REQUEST_SET_POST('year'        , "");
-if (!REQUEST_ISSET_POST(('max_mails')))    REQUEST_SET_POST('max_mails'   , "");
-if (!REQUEST_ISSET_POST(('street_nr')))    REQUEST_SET_POST('street_nr'   , "");
-if (!REQUEST_ISSET_POST(('zip')))          REQUEST_SET_POST('zip'         , "");
-if (!REQUEST_ISSET_POST(('city')))         REQUEST_SET_POST('city'        , "");
-if (!REQUEST_ISSET_POST(('cntry')))        REQUEST_SET_POST('cntry'       , "");
+if (!REQUEST_ISSET_POST(('agree')))        REQUEST_SET_POST('agree'       , '');
+if (!REQUEST_ISSET_POST(('addy')))         REQUEST_SET_POST('addy'        , '');
+if (!REQUEST_ISSET_POST(('surname')))      REQUEST_SET_POST('surname'     , '');
+if (!REQUEST_ISSET_POST(('family')))       REQUEST_SET_POST('family'      , '');
+if (!REQUEST_ISSET_POST(('pass1')))        REQUEST_SET_POST('pass1'       , '');
+if (!REQUEST_ISSET_POST(('pass2')))        REQUEST_SET_POST('pass2'       , '');
+if (!REQUEST_ISSET_POST(('day')))          REQUEST_SET_POST('day'         , '');
+if (!REQUEST_ISSET_POST(('month')))        REQUEST_SET_POST('month'       , '');
+if (!REQUEST_ISSET_POST(('year')))         REQUEST_SET_POST('year'        , '');
+if (!REQUEST_ISSET_POST(('max_mails')))    REQUEST_SET_POST('max_mails'   , '');
+if (!REQUEST_ISSET_POST(('street_nr')))    REQUEST_SET_POST('street_nr'   , '');
+if (!REQUEST_ISSET_POST('zip'))          REQUEST_SET_POST('zip'         , '');
+if (!REQUEST_ISSET_POST(('city')))         REQUEST_SET_POST('city'        , '');
+if (!REQUEST_ISSET_POST(('cntry')))        REQUEST_SET_POST('cntry'       , '');
 if (!REQUEST_ISSET_POST(('country_code'))) REQUEST_SET_POST('country_code', "1");
 
 // Default refid is zero
@@ -125,8 +125,8 @@ if (IS_FORM_SENT()) {
                        REQUEST_SET_POST('pass1', "!");
                        REQUEST_SET_POST('pass2', "!");
                } else {
-                       if (!REQUEST_ISSET_POST(('pass1'))) { REQUEST_SET_POST('pass1', "!"); } else { REQUEST_SET_POST('pass1', ""); }
-                       if (!REQUEST_ISSET_POST(('pass2'))) { REQUEST_SET_POST('pass2', "!"); } else { REQUEST_SET_POST('pass2', ""); }
+                       if (!REQUEST_ISSET_POST(('pass1'))) { REQUEST_SET_POST('pass1', "!"); } else { REQUEST_SET_POST('pass1', ''); }
+                       if (!REQUEST_ISSET_POST(('pass2'))) { REQUEST_SET_POST('pass2', "!"); } else { REQUEST_SET_POST('pass2', ''); }
                }
                $FAILED = true;
        } // END - if
@@ -141,7 +141,7 @@ if (IS_FORM_SENT()) {
        if (!IS_ADMIN()) {
                // Do this check only when no admin is logged in
                foreach (REQUEST_POST('cat') as $id => $answer) {
-                       if ($answer == "Y") $cats++;
+                       if ($answer == 'Y') $cats++;
                } // END - foreach
 
                if ($cats < getConfig('least_cats')) {
@@ -150,7 +150,7 @@ if (IS_FORM_SENT()) {
                } // END - if
        } // END - if
 
-       if ((REQUEST_POST('addy') != "!") && (getConfig('check_double_email') == "Y")) {
+       if ((REQUEST_POST('addy') != "!") && (getConfig('check_double_email') == 'Y')) {
                // Does the email address already exists in our database?
                $CHK = SEARCH_EMAIL_USERTAB(REQUEST_POST('addy'));
                if ($CHK) { REQUEST_SET_POST('addy', "?"); $FAILED = true; }
@@ -180,18 +180,18 @@ if ((IS_FORM_SENT()) && ((!$FAILED) || (IS_ADMIN()))) {
 
        // Get total ...
        // ... confirmed, ...
-       $confirmedUsers   = GET_TOTAL_DATA("CONFIRMED", "user_data", "userid", "status", true);
+       $confirmedUsers   = GET_TOTAL_DATA("CONFIRMED", "user_data", 'userid', "status", true);
        // ... unconfirmed ...
-       $unconfirmedUsers = GET_TOTAL_DATA("UNCONFIRMED", "user_data", "userid", "status", true);
+       $unconfirmedUsers = GET_TOTAL_DATA("UNCONFIRMED", "user_data", 'userid', "status", true);
        // ... and locked users!
-       $lockedUsers      = GET_TOTAL_DATA("LOCKED", "user_data", "userid", "status", true);
+       $lockedUsers      = GET_TOTAL_DATA("LOCKED", "user_data", 'userid', "status", true);
 
        // Generate hash which will be inserted into confirmation mail
        $hash = generateHash(sha1($confirmedUsers.":".$unconfirmedUsers.":".$lockedUsers.":".REQUEST_POST('month')."-".REQUEST_POST('day')."-".REQUEST_POST('year').":".getenv('SERVER_NAME').":".GET_REMOTE_ADDR().":".GET_USER_AGENT()."/".constant('SITE_KEY')."/".constant('DATE_KEY')."/".constant('RAND_NUMBER')));
 
        // Add design when extension sql_patches is v0.2.7 or greater
-       $ADD1 = ""; $ADD2 = "";
-       if (GET_EXT_VERSION("sql_patches") >= "0.2.7") {
+       $ADD1 = ''; $ADD2 = '';
+       if (GET_EXT_VERSION('sql_patches') >= '0.2.7') {
                // Okay, add design here
                $ADD1 = ", curr_theme";
                $ADD2 = ", '".GET_CURR_THEME()."'";
@@ -201,7 +201,7 @@ if ((IS_FORM_SENT()) && ((!$FAILED) || (IS_ADMIN()))) {
        // @TODO Rewrite this to a single filter
        //
        // First comes first: begging rallye
-       if (GET_EXT_VERSION("beg") >= "0.1.7") {
+       if (GET_EXT_VERSION('beg') >= '0.1.7') {
                // Okay, shall I disable now?
                if (getConfig('beg_new_mem_notify') != "Y") {
                        $ADD1 .= ", beg_ral_notify, beg_ral_en_notify";
@@ -210,7 +210,7 @@ if ((IS_FORM_SENT()) && ((!$FAILED) || (IS_ADMIN()))) {
        } // END - if
 
        // Second: active rallye
-       if (GET_EXT_VERSION("bonus") >= "0.7.7") {
+       if (GET_EXT_VERSION('bonus') >= '0.7.7') {
                // Okay, shall I disable now?
                if (getConfig('bonus_new_mem_notify') != "Y") {
                        $ADD1 .= ", bonus_ral_notify, bonus_ral_en_notify";
@@ -219,13 +219,13 @@ if ((IS_FORM_SENT()) && ((!$FAILED) || (IS_ADMIN()))) {
        } // END - if
 
        // Write user data to table
-       if (EXT_IS_ACTIVE("country")) {
+       if (EXT_IS_ACTIVE('country')) {
                // Save with new selectable country code
                $countryRow = "country_code";
                $countryData = bigintval(REQUEST_POST('country_code'));
        } else {
                // Old way with enterable two-char-code
-               $countryRow = "country";
+               $countryRow = 'country';
                $countryData = substr(REQUEST_POST('cntry'), 0, 2);
        }
 
@@ -262,19 +262,20 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
        // Did this work?
        if ($userid == 0) {
                // Something bad happened!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('USER_NOT_REGISTERED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('USER_NOT_REGISTERED'));
                return;
        } // END - if
 
        // Is the refback extension there?
-       if (EXT_IS_ACTIVE("refback")) {
+       // @TODO Rewrite this to a filter
+       if (EXT_IS_ACTIVE('refback')) {
                // Update refback table
                UPDATE_REFBACK_TABLE($userid);
        } // END - if
 
        // Write his welcome-points
        $result = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_user_points` WHERE userid=%s AND ref_depth=0 LIMIT 1",
-        array(bigintval($userid)), __FILE__, __LINE__);
+               array(bigintval($userid)), __FILE__, __LINE__);
        if (SQL_NUMROWS($result) == 0) {
                // Add only when the line was not found (maybe some more secure?)
                $locked = "points";
@@ -283,16 +284,16 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
                 array(bigintval($userid), getConfig('points_register')), __FILE__, __LINE__);
 
                // Update mediadata as well
-               if ((GET_EXT_VERSION("mediadata") >= "0.0.4") && ($locked == "points")) {
+               if ((GET_EXT_VERSION('mediadata') >= '0.0.4') && ($locked == "points")) {
                        // Update database
-                       MEDIA_UPDATE_ENTRY(array("total_points"), "add", getConfig('points_register'));
+                       MEDIA_UPDATE_ENTRY(array('total_points'), 'add', getConfig('points_register'));
                } // END - if
        } // END - if
 
        // Write catgories
        if ((is_array(REQUEST_POST('cat'))) && (count(REQUEST_POST('cat')))) {
                foreach (REQUEST_POST('cat') as $cat => $joined) {
-                       if ($joined == "Y") {
+                       if ($joined == 'Y') {
                                // Insert category entry
                                SQL_QUERY_ESC("INSERT INTO `{!_MYSQL_PREFIX!}_user_cats` (userid, cat_id) VALUES (%s, %s)",
                                 array(bigintval($userid), bigintval($cat)), __FILE__, __LINE__);
@@ -307,7 +308,7 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
        if (REQUEST_POST('refid') == "0") REQUEST_SET_POST('refid', constant('MAIN_TITLE'));
 
        // Is ZIP code set?
-       if (REQUEST_ISSET_POST(('zip'))) {
+       if (REQUEST_ISSET_POST('zip')) {
                // Prepare data array for the email template
                // Start with the gender...
                $DATA = array(
@@ -366,7 +367,7 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
        SEND_ADMIN_NOTIFICATION(getMessage('ADMIN_NEW_ACCOUNT'), "register-admin", $DATA, $userid);
 
        // Output success registration
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('REGISTRATION_DONE'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('REGISTRATION_DONE'));
 } else {
        if (REQUEST_POST('agree') == "!") {
                OUTPUT_HTML("<div class=\"register_failed\">{--HAVE_TO_AGREE--}</div>");
@@ -374,20 +375,20 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
 
        if (REQUEST_POST('addy') == "!") {
                OUTPUT_HTML("<div class=\"register_failed\">{--ENTER_EMAIL--}</div>");
-               REQUEST_SET_POST('addy', "");
+               REQUEST_SET_POST('addy', '');
        } elseif (REQUEST_POST('addy') == "?") {
                OUTPUT_HTML("<div class=\"register_failed\">{--EMAIL_ALREADY_DB--}</div>");
-               REQUEST_SET_POST('addy', "");
+               REQUEST_SET_POST('addy', '');
        }
 
        if (REQUEST_POST('surname') == "!") {
                OUTPUT_HTML("<div class=\"register_failed\">{--ENTER_SURNAME--}</div>");
-               REQUEST_SET_POST('surname', "");
+               REQUEST_SET_POST('surname', '');
        } // END - if
 
        if (REQUEST_POST('family') == "!") {
                OUTPUT_HTML("<div class=\"register_failed\">{--ENTER_FAMILY--}</div>");
-               REQUEST_SET_POST('family', "");
+               REQUEST_SET_POST('family', '');
        } // END - if
 
        if ((REQUEST_POST('pass1') == "!") && (REQUEST_POST('pass2') == "!")) {
@@ -423,13 +424,13 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
        }
 
        // Adds a table for the guests with all visible categories
-       define('CATEGORY_SELECTION', REGISTER_ADD_CATEGORY_TABLE("guest", true));
+       define('CATEGORY_SELECTION', REGISTER_ADD_CATEGORY_TABLE('guest', true));
 
        // Adds maximum receiveable mails list... :)
-       define('MAX_RECEIVE_LIST', ADD_MAX_RECEIVE_LIST("guest", "", true));
+       define('MAX_RECEIVE_LIST', ADD_MAX_RECEIVE_LIST('guest', '', true));
 
        // Shall I display the refid or shall I make it editable?
-       if (getConfig('display_refid') == "Y") {
+       if (getConfig('display_refid') == 'Y') {
                // Load "hide" form template
                define('REFID_CONTENT', LOAD_TEMPLATE("guest_register_refid_hide", true, $GLOBALS['refid']));
        } else {
@@ -448,20 +449,20 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
        define('__FAMILY',  SQL_ESCAPE(REQUEST_POST('family')));
        define('__STREET',  SQL_ESCAPE(REQUEST_POST('street_nr')));
        define('__COUNTRY', SQL_ESCAPE(REQUEST_POST('cntry')));
-       if (REQUEST_ISSET_POST(('zip'))) {
+       if (REQUEST_ISSET_POST('zip')) {
                define('__ZIP', bigintval(REQUEST_POST('zip')));
        } else {
-               define('__ZIP', "");
+               define('__ZIP', '');
        }
        define('__CITY',    SQL_ESCAPE(REQUEST_POST('city')));
        define('__ADDY',    SQL_ESCAPE(REQUEST_POST('addy')));
 
        // Shall I add a counrty selection box or the old input box?
-       if (EXT_IS_ACTIVE("country")) {
+       if (EXT_IS_ACTIVE('country')) {
                // New variant, good!
                $OUT  = "<select name=\"country_code\" class=\"guest_select\" size=\"1\">\n";
                $whereStatement = "WHERE is_active='Y'";
-               if (IS_ADMIN()) $whereStatement = "";
+               if (IS_ADMIN()) $whereStatement = '';
                $OUT .= ADD_OPTION_LINES("countries", "id", "descr", REQUEST_POST('country_code'), "code", $whereStatement);
                $OUT .= "</select>";
                define('__COUNTRY_CONTENT', $OUT);
@@ -471,7 +472,7 @@ VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONF
        }
 
        // Set MUST_??? constants
-       if ((EXT_IS_ACTIVE("register")) && (GET_EXT_VERSION("register") > "0.0")) REGISTER_FILL_MUST_CONSTANTS();
+       if ((EXT_IS_ACTIVE('register')) && (GET_EXT_VERSION('register') > '0.0')) REGISTER_FILL_MUST_CONSTANTS();
 
        // Display registration form
        LOAD_TEMPLATE("guest_register");
index d4edd318fa1b5041c2c4febca85f2b3834e72228..4d2868a6233ecd402818547d720b17efb490f8ab 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("sponsor"))) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "sponsor");
+} elseif ((!EXT_IS_ACTIVE('sponsor'))) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'sponsor');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 //
 ?>
index a651cee891d65a887e2fc4dba67e5547776c814c..1cc9636916bcf7b829ed80568b6576e1c61d8935 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("sponsor"))) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "sponsor");
+} elseif ((!EXT_IS_ACTIVE('sponsor'))) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'sponsor');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Init both results (see footer of this file)
 $result_act = false;
@@ -61,7 +61,7 @@ ORDER BY m.sort ASC", __FILE__, __LINE__);
 
 if (SQL_NUMROWS($result_act) > 0) {
        // Load all actions
-       $OUT_ACT = ""; $SW = 2;
+       $OUT_ACT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result_act)) {
                // Prepare data for the row template
                // @TODO Rewritings: conv->conv_rate,name->conv_name in template
@@ -81,7 +81,7 @@ if (SQL_NUMROWS($result_act) > 0) {
        $result_pay = SQL_QUERY("SELECT pay_name, pay_rate, pay_min_count, pay_currency FROM `{!_MYSQL_PREFIX!}_sponsor_paytypes` ORDER BY pay_name", __FILE__, __LINE__);
        if (SQL_NUMROWS($result_pay) > 0) {
                // Load all pay types
-               $OUT_PAY = ""; $SW = 2;
+               $OUT_PAY = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result_pay)) {
                        // Prepare data for the row template
                        // @TODO Rewritings: name->pay_name,min->pay_min_count,min->pay_min_count,curr->pay_currency
@@ -100,12 +100,12 @@ if (SQL_NUMROWS($result_act) > 0) {
                }
        } else {
                // No pay types setuped so far!
-               $OUT_PAY = LOAD_TEMPLATE("guest_sponsor_infos_none_row", LOAD_TEMPLATE("admin_settings_saved", true, getMessage('SPONSOR_NO_ACTIONS_ACTIVATED')));
+               $OUT_PAY = LOAD_TEMPLATE("guest_sponsor_infos_none_row", LOAD_TEMPLATE('admin_settings_saved', true, getMessage('SPONSOR_NO_ACTIONS_ACTIVATED')));
        }
 } else {
        // No actions activated so far!
-       $OUT_ACT = LOAD_TEMPLATE("guest_sponsor_infos_none_row", LOAD_TEMPLATE("admin_settings_saved", true, getMessage('SPONSOR_NO_ACTIONS_ACTIVATED')));
-       $OUT_PAY = LOAD_TEMPLATE("guest_sponsor_infos_none_row", LOAD_TEMPLATE("admin_settings_saved", true, getMessage('SPONSOR_NO_ACTIONS_ACTIVATED')));
+       $OUT_ACT = LOAD_TEMPLATE("guest_sponsor_infos_none_row", LOAD_TEMPLATE('admin_settings_saved', true, getMessage('SPONSOR_NO_ACTIONS_ACTIVATED')));
+       $OUT_PAY = LOAD_TEMPLATE("guest_sponsor_infos_none_row", LOAD_TEMPLATE('admin_settings_saved', true, getMessage('SPONSOR_NO_ACTIONS_ACTIVATED')));
 }
 
 // Free memory
index f2b1e9e9849c7bcf1e69dc7ae92ece4f364e2557..2090b96c3421be91548d53e3d024548061a037ba 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("sponsor"))) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "sponsor");
+} elseif ((!EXT_IS_ACTIVE('sponsor'))) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'sponsor');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
-$MODE = "";
+$MODE = '';
 if (REQUEST_ISSET_GET(('mode'))) {
        // A "special" mode of the login system was requested
        switch (REQUEST_GET('mode'))
        {
-               case "activate" : $MODE = "activate";  break; // Activation link requested
+               case 'activate' : $MODE = 'activate';  break; // Activation link requested
                case "lost_pass": $MODE = "lost_pass"; break; // Request new password
        }
 } // END - if
@@ -93,10 +93,10 @@ WHERE id='%s' AND hash='%s' AND `status`='UNCONFIRMED' LIMIT 1",
                                SEND_ADMIN_NOTIFICATION(getMessage('ADMIN_NEW_SPONSOR'), "admin_sponsor_pending", $SPONSOR);
 
                                // Sponsor account set to pending
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_ACCOUNT_IS_PENDING'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_ACCOUNT_IS_PENDING'));
                        } else {
                                // Could not unlock account!
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_ACCOUNT_PENDING_FAILED'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_ACCOUNT_PENDING_FAILED'));
                        }
                } elseif ($SPONSOR['status'] == "EMAIL") {
                        // Changed email adress need to be confirmed
@@ -107,23 +107,23 @@ WHERE id='%s' AND hash='%s' AND `status`='EMAIL' LIMIT 1",
                        // Check on success 
                        if (SQL_AFFECTEDROWS() == 1) {
                                // Sponsor account is unlocked again
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_ACCOUNT_IS_CONFIRMED_AGAIN'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_ACCOUNT_IS_CONFIRMED_AGAIN'));
                        } else {
                                // Could not unlock account!
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_ACCOUNT_EMAIL_FAILED'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_ACCOUNT_EMAIL_FAILED'));
                        }
                } else {
                        /// ??? Other status?
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_ACCOUNT_STATUS_FAILED'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_ACCOUNT_STATUS_FAILED'));
                }
        } else {
                // No sponsor found
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_ACCOUNT_NOT_FOUND'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_ACCOUNT_NOT_FOUND'));
        }
 
        // Free memory
        SQL_FREERESULT($result);
-} elseif ($MODE == "activate") {
+} elseif ($MODE == 'activate') {
        // Send activation link again
        if (IS_FORM_SENT()) {
                // Check submitted data
@@ -157,10 +157,10 @@ WHERE email='%s' AND (`status`='UNCONFIRMED' OR `status`='EMAIL') LIMIT 1",
                        SEND_EMAIL(REQUEST_POST('email'), SPONSOR_ACTIVATION_LINK_SUBJ, $msg_sponsor);
 
                        // Output message
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_ACTIVATION_LINK_SENT'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_ACTIVATION_LINK_SENT'));
                } else {
                        // No account found or not UNCONFIRMED
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_ACTIVATION_LINK_404'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_ACTIVATION_LINK_404'));
                }
 
                // Free memory
@@ -204,10 +204,10 @@ WHERE id='%s' LIMIT 1",
  array(md5($SPONSOR['password']), bigintval($SPONSOR['id'])), __FILE__, __LINE__);
 
                        // Output message
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_LOST_PASSWORD_SENT'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_LOST_PASSWORD_SENT'));
                } else {
                        // No account found or not UNCONFIRMED
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_LOST_PASSWORD_404'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_LOST_PASSWORD_404'));
                }
 
                // Free memory
@@ -235,7 +235,7 @@ WHERE id='%s' AND password='%s' LIMIT 1",
                                LOAD_URL("modules.php?module=sponsor");
                        } else {
                                // Cookie setup failed!
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSPOR_COOKIE_SETUP_FAILED'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSPOR_COOKIE_SETUP_FAILED'));
 
                                // Login formular and other links
                                LOAD_TEMPLATE("guest_sponsor_login");
@@ -243,14 +243,14 @@ WHERE id='%s' AND password='%s' LIMIT 1",
                } else {
                        // Status is not fine
                        $content = constant('SPONSOR_LOGIN_FAILED_'.strtoupper($status).'');
-                       LOAD_TEMPLATE("admin_settings_saved", false, $content);
+                       LOAD_TEMPLATE('admin_settings_saved', false, $content);
 
                        // Login formular and other links
                        LOAD_TEMPLATE("guest_sponsor_login");
                }
        } else {
                // Account missing or wrong pass! We shall not find this out for the "hacker folks"...
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_LOGIN_FAILED_404_WRONG_PASS'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_LOGIN_FAILED_404_WRONG_PASS'));
 
                // Login formular and other links
                LOAD_TEMPLATE("guest_sponsor_login");
index a6d0924daade924b938137d9a04bee3503645a0a..69920c8735d69ce74c12db56af0d19eb05696aed 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("sponsor"))) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "sponsor");
+} elseif ((!EXT_IS_ACTIVE('sponsor'))) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'sponsor');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Create array for form errors (= missing data)
 $FORM_ERRORS = array();
@@ -106,13 +106,13 @@ if (IS_FORM_SENT()) {
        }
 
        // 3. ZIP code
-       if (!REQUEST_ISSET_POST(('zip'))) {
+       if (!REQUEST_ISSET_POST('zip')) {
                // ZIP code is empty
                $FORM_ERRORS[] = getMessage('SPONSOR_ZIP_IS_EMPTY');
        } elseif (bigintval(REQUEST_POST('zip')) != REQUEST_POST('zip')) {
                // ZIP is invalid
                $FORM_ERRORS[] = getMessage('SPONSOR_ZIP_IS_INVALID');
-               REQUEST_SET_POST('zip', "");
+               REQUEST_SET_POST('zip', '');
        }
 
        // 4. City
@@ -134,7 +134,7 @@ if (IS_FORM_SENT()) {
        } elseif (!VALIDATE_URL(REQUEST_POST('url'))) {
                // Homepage URL is invalid
                $FORM_ERRORS[] = getMessage('SPONSOR_URL_IS_INVALID');
-               REQUEST_SET_POST('url', "");
+               REQUEST_SET_POST('url', '');
        }
 
        // 7. Light validation of email address
@@ -144,7 +144,7 @@ if (IS_FORM_SENT()) {
        } elseif (SPONSOR_FOUND_EMAIL_DB(REQUEST_POST('email'))) {
                // Email already found in database!
                $FORM_ERRORS[] = getMessage('SPONSOR_EMAIL_IS_ALREADY_REGISTERED');
-               REQUEST_SET_POST('email', "");
+               REQUEST_SET_POST('email', '');
        }
 
        // 8. Pay type selected?
@@ -273,7 +273,7 @@ WHERE id='%s' LIMIT 1", array(REQUEST_POST('pay_type')), __FILE__, __LINE__);
        }
 
        // Display message
-       LOAD_TEMPLATE("admin_settings_saved", false, $message);
+       LOAD_TEMPLATE('admin_settings_saved', false, $message);
 } else {
        // Check for payment types
        $result = SQL_QUERY("SELECT id, pay_name, pay_rate, pay_currency, pay_min_count
@@ -323,19 +323,19 @@ ORDER BY pay_name", __FILE__, __LINE__);
                        {
                        case "M": // Male
                                define('__GENDER_M'  , " selected=\"selected\"");
-                               define('__GENDER_F'  , "");
-                               define('__GENDER_C'  , "");
+                               define('__GENDER_F'  , '');
+                               define('__GENDER_C'  , '');
                                break;
 
                        case "F": // Female
-                               define('__GENDER_M'  , "");
+                               define('__GENDER_M'  , '');
                                define('__GENDER_F'  , " selected=\"selected\"");
-                               define('__GENDER_C'  , "");
+                               define('__GENDER_C'  , '');
                                break;
 
                        case "C": // Company
-                               define('__GENDER_M'  , "");
-                               define('__GENDER_F'  , "");
+                               define('__GENDER_M'  , '');
+                               define('__GENDER_F'  , '');
                                define('__GENDER_C'  , " selected=\"selected\"");
                                break;
                        }
@@ -343,13 +343,13 @@ ORDER BY pay_name", __FILE__, __LINE__);
                        // Check for receive_warnings
                        switch (REQUEST_POST('receive_warnings'))
                        {
-                       case "Y":
+                       case 'Y':
                                define('__REC_Y'    , " selected=\"selected\"");
-                               define('__REC_N'    , "");
+                               define('__REC_N'    , '');
                                break;
 
-                       case "N":
-                               define('__REC_Y'    , "");
+                       case 'N':
+                               define('__REC_Y'    , '');
                                define('__REC_N'    , " selected=\"selected\"");
                                break;
                        }
@@ -368,29 +368,29 @@ ORDER BY pay_name", __FILE__, __LINE__);
                        define('__SPONSOR_REFID', REQUEST_POST('refid'));
                } else {
                        // None found, first call
-                       define('__COMPANY'  , "");
-                       define('__POSITION' , "");
-                       define('__TAX_IDENT', "");
-                       define('__GENDER_M'  , "");
-                       define('__GENDER_F'  , "");
-                       define('__GENDER_C'  , "");
-                       define('__SURNAME'  , "");
-                       define('__FAMILY'   , "");
-                       define('__STREET1'  , "");
-                       define('__STREET2'  , "");
-                       define('__COUNTRY'  , "");
-                       define('__ZIP'      , "");
-                       define('__CITY'     , "");
-                       define('__PHONE'    , "");
-                       define('__FAX'      , "");
-                       define('__CELL'     , "");
-                       define('__EMAIL'    , "");
-                       define('__URL'      , "");
-                       define('__REC_Y'    , "");
-                       define('__REC_N'    , "");
+                       define('__COMPANY'  , '');
+                       define('__POSITION' , '');
+                       define('__TAX_IDENT', '');
+                       define('__GENDER_M' , '');
+                       define('__GENDER_F' , '');
+                       define('__GENDER_C' , '');
+                       define('__SURNAME'  , '');
+                       define('__FAMILY'   , '');
+                       define('__STREET1'  , '');
+                       define('__STREET2'  , '');
+                       define('__COUNTRY'  , '');
+                       define('__ZIP'      , '');
+                       define('__CITY'     , '');
+                       define('__PHONE'    , '');
+                       define('__FAX'      , '');
+                       define('__CELL'     , '');
+                       define('__EMAIL'    , '');
+                       define('__URL'      , '');
+                       define('__REC_Y'    , '');
+                       define('__REC_N'    , '');
 
                        // No errors found so far
-                       define('__SPONSOR_FORM_ERRORS', "");
+                       define('__SPONSOR_FORM_ERRORS', '');
                }
 
                // Prepare referal things
@@ -406,7 +406,7 @@ ORDER BY pay_name", __FILE__, __LINE__);
                LOAD_TEMPLATE("guest_sponsor_reg");
        } else {
                // Nothing added so far
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('SPONSOR_PAYMENT_LIST_IS_EMPTY'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('SPONSOR_PAYMENT_LIST_IS_EMPTY'));
        }
 
        // Free memory
index 8724592dd6f4db3211b356cfa44c72f6db6e4515..a272673a9633025d9c31a45a081178054c411988 100644 (file)
@@ -43,7 +43,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Derterminate which stats we want and set mode and title for the link below stats block
 if (!REQUEST_ISSET_GET(('mode'))) REQUEST_SET_GET('mode', strtolower(getConfig('guest_stats')));
@@ -80,8 +80,8 @@ case "MEMBERS": // Statistics about your members
        $treg = SQL_NUMROWS(SQL_QUERY("SELECT userid FROM `{!_MYSQL_PREFIX!}_user_data` WHERE joined >= ".constant('START_TDAY'), __FILE__, __LINE__));
 
        // Only males / females
-       $male   = GET_TOTAL_DATA("M", "user_data", "userid", "gender", true, " AND `status`='CONFIRMED'");
-       $female = GET_TOTAL_DATA("F", "user_data", "userid", "gender", true, " AND `status`='CONFIRMED'");
+       $male   = GET_TOTAL_DATA("M", "user_data", 'userid', "gender", true, " AND `status`='CONFIRMED'");
+       $female = GET_TOTAL_DATA("F", "user_data", 'userid', "gender", true, " AND `status`='CONFIRMED'");
 
        // Unconfirmed accounts
        $unconfirmed = SQL_NUMROWS(SQL_QUERY("SELECT userid FROM `{!_MYSQL_PREFIX!}_user_data` WHERE status != 'CONFIRMED'", __FILE__, __LINE__));
@@ -99,7 +99,7 @@ case "MEMBERS": // Statistics about your members
                if ($idx < 10) $month = "0".$idx;
 
                // Count months
-               $months[$month] = GET_TOTAL_DATA(bigintval($month), "user_data", "userid", "birth_month", true, " AND `status`='CONFIRMED'");
+               $months[$month] = GET_TOTAL_DATA(bigintval($month), "user_data", 'userid', "birth_month", true, " AND `status`='CONFIRMED'");
        }
 
        // Members in categories
@@ -133,7 +133,7 @@ case "MEMBERS": // Statistics about your members
        define('__LINK_TITLE'  , $ltitle);
 
        // Generate monthly stats
-       $SW = 2; $r2 = " right2"; $l = "ll"; $r = "lr"; $OUT = "";
+       $SW = 2; $r2 = " right2"; $l = "ll"; $r = "lr"; $OUT = '';
        foreach ($months as $month => $cnt) {
                if ($SW == 2) $OUT .= "<tr>\n";
 
@@ -150,7 +150,7 @@ case "MEMBERS": // Statistics about your members
                $OUT .= LOAD_TEMPLATE("guest_stats_month_row", true, $content);
 
                if ($SW == 2) {
-                       $r2 = "";
+                       $r2 = '';
                        $l = "rl"; $r = "rr";
                } else {
                        $OUT .= "</tr>\n";
@@ -162,7 +162,7 @@ case "MEMBERS": // Statistics about your members
        define('__MONTH_STATS_ROWS', $OUT);
 
        // Generate category stats
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach ($cat_cnt as $id => $cnt) {
                // Prepare data for the template
                $content = array(
@@ -182,11 +182,11 @@ case "MEMBERS": // Statistics about your members
        break;
 
 case "MODULES": // TOP10 module clicks
-       $AND = "";
+       $AND = '';
        if (!IS_ADMIN()) $AND = " AND `locked`='N' AND `visible`='Y'";
        $guest_t10 = SQL_QUERY("SELECT counter, title FROM `{!_MYSQL_PREFIX!}_guest_menu` WHERE counter > 0".$AND." ORDER BY counter DESC LIMIT 0,10", __FILE__, __LINE__);
        $mem_t10   = SQL_QUERY("SELECT counter, title FROM `{!_MYSQL_PREFIX!}_member_menu` WHERE counter > 0".$AND." ORDER BY counter DESC LIMIT 0,10", __FILE__, __LINE__);
-       $OUT = "";
+       $OUT = '';
        if ((SQL_NUMROWS($guest_t10) > 0) || (SQL_NUMROWS($mem_t10) > 0)) {
                // Output header
                // @TODO Rewrite this to one template and $OUT .= ....
@@ -238,7 +238,7 @@ case "MODULES": // TOP10 module clicks
        break;
 
 case "INACTIVE": // Deactivated stats
-       LOAD_TEMPLATE("admin_settings_saved", false, "<strong>{--GUEST_STATS_DEACTIVATED--}</strong>");
+       LOAD_TEMPLATE('admin_settings_saved', false, "<strong>{--GUEST_STATS_DEACTIVATED--}</strong>");
        break;
 }
 
index f3ead088a117f4fedbe643b29e376c488dea5c2c..896a8781ca985d107012954ddf31d87e19fed203 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("top10")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "top10");
+} elseif ((!EXT_IS_ACTIVE('top10')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'top10');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 //// TOP logins
 $result = SQL_QUERY_ESC("
@@ -62,13 +62,13 @@ ORDER BY
 LIMIT %s",
        array(getConfig('top10_max')), __FILE__, __LINE__);
 
-$OUT = ""; $SW = 2; $cnt = 1;
+$OUT = ''; $SW = 2; $cnt = 1;
 while ($content = SQL_FETCHARRAY($result)) {
        // Init nickname
        $content['nickname'] = "---";
 
        // Get nickname
-       if (EXT_IS_ACTIVE("nickname")) $content['nickname'] = NICKNAME_GET_NICK($content['userid']);
+       if (EXT_IS_ACTIVE('nickname')) $content['nickname'] = NICKNAME_GET_NICK($content['userid']);
 
        // Prepare data for template
        // @TODO Rewritings: uid->userid,nick->nickname,logins->total_logins in template
@@ -133,13 +133,13 @@ ORDER BY
 LIMIT %s",
        array(getConfig('top10_max')), __FILE__, __LINE__);
 
-$OUT = ""; $SW = 2; $cnt = 1;
+$OUT = ''; $SW = 2; $cnt = 1;
 while ($content = SQL_FETCHARRAY($result)) {
        // Init nickname
        $content['nickname'] = "---";
 
        // Get nickname
-       if (EXT_IS_ACTIVE("nickname")) $content['nickname'] = NICKNAME_GET_NICK($content['userid']);
+       if (EXT_IS_ACTIVE('nickname')) $content['nickname'] = NICKNAME_GET_NICK($content['userid']);
 
        // Prepare data for template
        // @TODO Rewritings: nick->nickname,uid->userid in template
@@ -203,13 +203,13 @@ ORDER BY
 LIMIT %s",
        array(getConfig('top10_max')), __FILE__, __LINE__);
 
-$OUT = ""; $SW = 2; $cnt = 1;
+$OUT = ''; $SW = 2; $cnt = 1;
 while ($content = SQL_FETCHARRAY($result)) {
        // Init nickname
        $content['nickname'] = "---";
 
        // Get nickname
-       if (EXT_IS_ACTIVE("nickname")) $content['nickname'] = NICKNAME_GET_NICK($content['userid']);
+       if (EXT_IS_ACTIVE('nickname')) $content['nickname'] = NICKNAME_GET_NICK($content['userid']);
 
        // Prepare data for template
        // @TODO Rewritings: nick->nickname,uid->userid in template
index 9d9203a88d801df54c0fef2e79d333b93bf14723..4414b0a0a186552b10bb6953c4ca8d5743037502 100644 (file)
@@ -43,7 +43,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 // Count referal levels
 $result = SQL_QUERY("SELECT COUNT(id) FROM `{!_MYSQL_PREFIX!}_refdepths` WHERE level>0", __FILE__, __LINE__);
index 6f7cbeeafd37ae97dea1165532c8357f860ce437..f684914b1bd8e7284e541402ecc409c68d914883 100644 (file)
@@ -40,8 +40,8 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("wernis")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "wernis");
+} elseif ((!EXT_IS_ACTIVE('wernis')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'wernis');
        return;
 }
 
@@ -49,7 +49,7 @@ if (!defined('__SECURITY')) {
 LOAD_INC_ONCE("inc/rdf.class.php");
 
 // Add description as navigation point
-ADD_DESCR("guest", __FILE__);
+ADD_DESCR('guest', __FILE__);
 
 OUTPUT_HTML("<div style=\"padding-left: 10px; padding-right: 10px\">");
 $rdf = new fase4_rdf();
index c4d19f2d72cad29bf188eec5c86dfbff3478b2ec..d1890480564c41c3a73b984b9e77bdd8dbd5ed0e 100644 (file)
@@ -40,8 +40,8 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("sql_patches")) {
-       // The extension "sql_patches" *MUST* be activated or you have lot's of problems!
+} elseif (!EXT_IS_ACTIVE('sql_patches')) {
+       // The extension 'sql_patches' *MUST* be activated or you have lot's of problems!
        LOAD_URL("admin.php");
 }
 
@@ -63,13 +63,13 @@ if (empty($GLOBALS['what'])) $GLOBALS['what'] = getConfig('index_home');
 // Adding the main content module here
 if (empty($GLOBALS['action'])) {
        // Get action value from what value
-       $GLOBALS['action'] = GET_ACTION("guest", $GLOBALS['what']);
+       $GLOBALS['action'] = GET_ACTION('guest', $GLOBALS['what']);
 } // END - if
 
 // Add the guest's menu here...
-if ((getConfig('guest_menu') == "Y") || (!EXT_IS_ACTIVE("sql_patches", true))) {
+if ((getConfig('guest_menu') == 'Y') || (!EXT_IS_ACTIVE('sql_patches', true))) {
        // Show only when guest menu is active
-       ADD_MENU("guest", $GLOBALS['action'], $GLOBALS['what']);
+       ADD_MENU('guest', $GLOBALS['action'], $GLOBALS['what']);
 } // END - if
 
 // TDs between menu and content
@@ -82,15 +82,15 @@ $GLOBALS['block_mode'] = false;
 $INC = sprintf("inc/modules/guest/action-%s.php", $GLOBALS['action']);
 
 // Is the file there?
-if ((INCLUDE_READABLE($INC)) && (VALIDATE_MENU_ACTION("guest", $GLOBALS['action'], $GLOBALS['what']))) {
+if ((INCLUDE_READABLE($INC)) && (VALIDATE_MENU_ACTION('guest', $GLOBALS['action'], $GLOBALS['what']))) {
        // Requested module is available so we load it
        LOAD_INC_ONCE($INC);
 } else {
        // Invalid module specified or not found...
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 }
 
-if ((getConfig('guest_menu') == "Y") || (!EXT_IS_ACTIVE("sql_patches", true))) {
+if ((getConfig('guest_menu') == 'Y') || (!EXT_IS_ACTIVE('sql_patches', true))) {
        // Right side of content (hint: a good place for 120x600 skyscraper banner!)
        LOAD_TEMPLATE("guest_content_footer");
 
index f06e6bac8f27d1f8e133a96a5b33d4a31630786d..9dd41b7776a96ff7791bd0891cbba9b1c4d4be70 100644 (file)
@@ -41,27 +41,27 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       $URL = "modules.php?module=index";
-       if ($check == "mem_only") $URL .= "&amp;msg=".getCode('MODULE_MEM_ONLY')."&amp;mod=".$GLOBALS['module'];
+       $URL = 'modules.php?module=index';
+       if ($check == 'mem_only') $URL .= '&amp;msg='.getCode('MODULE_MEM_ONLY').'&amp;mod='.$GLOBALS['module'];
        LOAD_URL($URL);
 }
 
-if ($status != "CONFIRMED") {
+if ($status != 'CONFIRMED') {
        // If the status is different than confirmed move the user away from here
        $errorCode = GEN_ERROR_CODE_FROM_ACCOUNT_STATUS($status);
 
        // Load URL
-       LOAD_URL("modules.php?module=index&amp;what=login&amp;login=".$errorCode);
+       LOAD_URL('modules.php?module=index&amp;what=login&amp;login='.$errorCode);
 } // END - if
 
 // Load adverstising template
-define('__MEMBER_ADVERT', LOAD_TEMPLATE("member_banner", true));
+define('__MEMBER_ADVERT', LOAD_TEMPLATE('member_banner', true));
 
 // Disable block mode by default
 $GLOBALS['block_mode'] = false;
 
 // Generate a tableset for the menu title and content
-LOAD_TEMPLATE("member_header");
+LOAD_TEMPLATE('member_header');
 
 // Begin menu block here
 OUTPUT_HTML("<tr>
@@ -69,14 +69,14 @@ OUTPUT_HTML("<tr>
 
 // Adding the main content module here
 if (empty($GLOBALS['action'])) {
-       if (empty($GLOBALS['what'])) $GLOBALS['what'] = "welcome";
+       if (empty($GLOBALS['what'])) $GLOBALS['what'] = 'welcome';
 } else {
        $act = SQL_ESCAPE($GLOBALS['action']);
 }
 
 // Add the member's menu here...
-if ((getConfig('member_menu') == "Y") || (!EXT_IS_ACTIVE("sql_patches", true))) {
-       ADD_MENU("member", GET_ACTION("member", $GLOBALS['what']), $GLOBALS['what']);
+if ((getConfig('member_menu') == 'Y') || (!EXT_IS_ACTIVE('sql_patches', true))) {
+       ADD_MENU('member', GET_ACTION('member', $GLOBALS['what']), $GLOBALS['what']);
 } // END - if
 
 // Menu -> content
@@ -84,30 +84,30 @@ OUTPUT_HTML("   </td>
   <td valign=\"top\" align=\"center\" rowspan=\"3\" class=\"member_content\">");
 
 $INC = sprintf("inc/modules/member/action-%s.php", $act);
-if ((INCLUDE_READABLE($INC)) && (VALIDATE_MENU_ACTION("member", $GLOBALS['action'], $GLOBALS['what']))) {
+if ((INCLUDE_READABLE($INC)) && (VALIDATE_MENU_ACTION('member', $GLOBALS['action'], $GLOBALS['what']))) {
        // Requested module is available so we load it
        LOAD_INC($INC);
 } else {
        // Invalid module specified or not found...
-       LOAD_URL("modules.php?module=login");
+       LOAD_URL('modules.php?module=login');
 }
 
-if ((getConfig('member_menu') == "Y") || (!EXT_IS_ACTIVE("sql_patches", true))) {
+if ((getConfig('member_menu') == 'Y') || (!EXT_IS_ACTIVE('sql_patches', true))) {
        // Right side of content (hint: a good place for 120x600 skyscraper banner!)
-       LOAD_TEMPLATE("member_content_right");
+       LOAD_TEMPLATE('member_content_right');
 
        // Some advertising stuff?
-       LOAD_TEMPLATE("member_advert");
+       LOAD_TEMPLATE('member_advert');
 }
 
 OUTPUT_HTML("  </td>
 </tr>");
 
-// Load same template for "Goto TOP"
-LOAD_TEMPLATE("member_goto_top");
+// Load same template for 'Goto TOP'
+LOAD_TEMPLATE('member_goto_top');
 
 // Footer template (Thanx to Mr. Glaus!)
-LOAD_TEMPLATE("member_footer");
+LOAD_TEMPLATE('member_footer');
 
 //
 ?>
index a6f03ff3acc61daf2c1f2372681cc16f11ddf21b..bae936ef5df708964ed9f6446a4730108bd28275 100644 (file)
@@ -51,7 +51,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/member/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index b909cb4d81961b233c277d008b13a7e538584ab6..c70be39ccdc56aa9eaf606f36130275401a9923e 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 } elseif ($GLOBALS['block_mode']) {
        // Block mode detected
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/member/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index d073fde05feb03b26f27c2294572c4aae2af2235..81acd1b57cdee97fa81babb267810a18a3ce8f80 100644 (file)
@@ -41,9 +41,9 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("bank")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "bank");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('bank')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'bank');
        return;
 } elseif ($GLOBALS['block_mode']) {
        // Block mode detected
@@ -51,7 +51,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/member/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 5e30dea779cb846fa3a3b664f317ed63cbfc2af2..b9ce98cb40030d720b08ed41c581dea8c66e1d7a 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 } elseif ($GLOBALS['block_mode']) {
        // Block mode detected
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/member/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 043b58fd6f59aaeba2ba91df0308d82196bc8d73..6e94ec7b7be8a0923aa746ee6d5170d383316f28 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 } elseif ($GLOBALS['block_mode']) {
        // Block mode detected
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/member/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 8ff8d0c29c2837ab48f3530a53e1160a807ab3ef..60066467ec0572a1a53cfad1b6e7a88df7c27d1b 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 } elseif ($GLOBALS['block_mode']) {
        // Block mode detected
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/member/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 636cd8f5b1811565b8d554d27fcda628af913256..a8c14f3958ecaaae6a8a35ea15eb8b34f72ffa45 100644 (file)
@@ -41,9 +41,9 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("order")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "order");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('order')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'order');
        return;
 } elseif ($GLOBALS['block_mode']) {
        // Block mode detected
@@ -51,7 +51,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/member/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index a74e63a72ccf2d0b262555b4976c45a7207ef45d..c1e015b50ddd24bb533fb01a28a6f217e044b0fe 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 } elseif ($GLOBALS['block_mode']) {
        // Block mode detected
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/member/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index 0b791f7d1119575b9760acb24d1a4080912025a8..32b8363c6350042780af6787c06b9ec59dbfcce1 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 } elseif ($GLOBALS['block_mode']) {
        // Block mode detected
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/member/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index e9349e4c9a70a7cde18c977ecada26aa61285e34..2e03a12323ea6ed205f96b53e627339ba9822644 100644 (file)
@@ -41,9 +41,9 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("surfbar")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "surfbar");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('surfbar')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'surfbar');
        return;
 } elseif ($GLOBALS['block_mode']) {
        // Block mode detected
@@ -51,7 +51,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load the include file
 $INC = sprintf("inc/modules/member/what-%s.php", SQL_ESCAPE($GLOBALS['what']));
index bc7ab3ee4d9289b4b6b891aadece416e82548cc7..b471e2c425f91c102b69b1b5365514ac28c83314 100644 (file)
@@ -41,21 +41,21 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("theme")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "theme");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('theme')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'theme');
        return;
 }
 
 // Load all active designs (or all if admin)
-$whereStatement = ""; $OUT = "";
+$whereStatement = ''; $OUT = '';
 if (!IS_ADMIN()) $whereStatement = " WHERE theme_active='Y'";
 $result_themes = SQL_QUERY("SELECT theme_path FROM `{!_MYSQL_PREFIX!}_themes`".$whereStatement, __FILE__, __LINE__);
 $num_themes = SQL_NUMROWS($result_themes);
 
 if ($num_themes > 1) {
        // If more than 1 is installed output selection box
-       $act = ""; $wht = "";
+       $act = ''; $wht = '';
        if (!empty($GLOBALS['action'])) $act = SQL_ESCAPE($GLOBALS['action']);
        if (!empty($GLOBALS['what']))   $wht = SQL_ESCAPE($GLOBALS['what']);
        $OUT = THEME_SELECTION_BOX("login", $act, $wht, $result_themes);
@@ -65,7 +65,7 @@ if ($num_themes > 1) {
        $OUT = LOAD_TEMPLATE("theme_one", true);
 } elseif (IS_ADMIN()) {
        // If there is no theme installed and there's an admin notify him!
-       $OUT = LOAD_TEMPLATE("admin_settings_saved", true, "<div class=\"admin_note\">{--ADMIN_NO_THEME_INSTALLED_WARNING--}</div>");
+       $OUT = LOAD_TEMPLATE('admin_settings_saved', true, "<div class=\"admin_note\">{--ADMIN_NO_THEME_INSTALLED_WARNING--}</div>");
 }
 
 // Free memory
index 04d21113141d6e9129cdde69746ea7e36177e27e..0a0ccb74a532559656f2c75a1179ca3ccd517cf7 100644 (file)
@@ -45,7 +45,7 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Loads the name-matching template
 LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));
index 2747efd5481c2969d31ffac60123a686bafc6b50..6b24d28276209737e4a1924782f745a0451fec69 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("bank")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "bank");
+} elseif ((!EXT_IS_ACTIVE('bank')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'bank');
        return;
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Loads the name-matching template
 LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));
index 516c33ffa2e7cca0505478e38c5e559a7839e527..589e8babce4fe5c227b7ed9358b2951777fe3cbc 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("bank")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "bank");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('bank')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'bank');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Loads the name-matching template
 LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));
index 23d2edf357e7c3d31b9411e3e77953727157d7dd..34ec453bba4f1700f6092652d89777e2c873b587 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("bank")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "bank");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('bank')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'bank');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Loads the name-matching template
 LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));
index 23d2edf357e7c3d31b9411e3e77953727157d7dd..34ec453bba4f1700f6092652d89777e2c873b587 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("bank")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "bank");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('bank')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'bank');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Loads the name-matching template
 LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));
index 23d2edf357e7c3d31b9411e3e77953727157d7dd..34ec453bba4f1700f6092652d89777e2c873b587 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("bank")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "bank");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('bank')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'bank');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Loads the name-matching template
 LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));
index 581ab6155a6f38403427b8cc31a38c0996dc3dbd..c19db75ba300a37b555ca88aa4b1667479e1e593 100644 (file)
@@ -41,25 +41,25 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("beg")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "beg");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('beg')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'beg');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 $uid = getUserId();
-if (EXT_IS_ACTIVE("nickname"))
+if (EXT_IS_ACTIVE('nickname'))
 {
        // Load nickname
-       $data = "nickname";
+       $data = 'nickname';
 }
  else
 {
        // Load userid
-       $data = "userid";
+       $data = 'userid';
 }
 
 // Run SQL command
index b5c9fc92dc9c9ad34449869393ff49795b68a966..037c7dcd8615eca70f1f28db170110239d1988bd 100644 (file)
@@ -42,17 +42,17 @@ if (!defined('__SECURITY')) {
        require($INC);
 } elseif (!IS_MEMBER()) {
        LOAD_URL("modules.php[5~?module=index");
-} elseif ((!EXT_IS_ACTIVE("beg")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "beg");
+} elseif ((!EXT_IS_ACTIVE('beg')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'beg');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Autopurge installed?
-$lastOnline = "%s"; $ONLINE = "";
-if (EXT_IS_ACTIVE("autopurge")) {
+$lastOnline = "%s"; $ONLINE = '';
+if (EXT_IS_ACTIVE('autopurge')) {
        // Use last online timestamp to keep inactive members away from here
        $lastOnline   = " AND last_online >= (UNIX_TIMESTAMP() - %s)";
        $ONLINE = getConfig('ap_inactive_since');
@@ -65,7 +65,7 @@ ORDER BY beg_points DESC, last_online DESC, userid LIMIT %s",
        array($ONLINE, getConfig('beg_ranks')), __FILE__, __LINE__);
 
 // Reset temporary variable and check for users
-$OUT = "";
+$OUT = '';
 if (SQL_NUMROWS($result) > 0) {
        // Load our winners...
        $SW = 2; $cnt = 1;
index 4934cb9f486bd094b3308e40a42256cf0a2e18e8..e562705c82ddae805f80dfa11aba2c7bd4a6ce3e 100644 (file)
@@ -42,23 +42,23 @@ if (!defined('__SECURITY')) {
        require($INC);
 } elseif (!IS_MEMBER()) {
        LOAD_URL("modules.php[5~?module=index");
-} elseif ((!EXT_IS_ACTIVE("bonus")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "bonus");
+} elseif ((!EXT_IS_ACTIVE('bonus')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'bonus');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
-if (GET_EXT_VERSION("bonus") >= "0.6.9") {
+if (GET_EXT_VERSION('bonus') >= '0.6.9') {
        // Add more bonus points here
        // @TODO Rewrite this to a filter
        $USE = "(0";
-       if (getConfig('bonus_click_yn') == "Y") $USE .= " + turbo_bonus";
-       if (getConfig('bonus_login_yn') == "Y") $USE .= " + login_bonus";
-       if (getConfig('bonus_order_yn') == "Y") $USE .= " + bonus_order";
-       if (getConfig('bonus_stats_yn') == "Y") $USE .= " + bonus_stats";
-       if (getConfig('bonus_ref_yn')   == "Y") $USE .= " + bonus_ref";
+       if (getConfig('bonus_click_yn') == 'Y') $USE .= " + turbo_bonus";
+       if (getConfig('bonus_login_yn') == 'Y') $USE .= " + login_bonus";
+       if (getConfig('bonus_order_yn') == 'Y') $USE .= " + bonus_order";
+       if (getConfig('bonus_stats_yn') == 'Y') $USE .= " + bonus_stats";
+       if (getConfig('bonus_ref_yn')   == 'Y') $USE .= " + bonus_ref";
        $USE .= ")";
 } else {
        // Old version ???
@@ -66,8 +66,8 @@ if (GET_EXT_VERSION("bonus") >= "0.6.9") {
 }
 
 // Autopurge installed?
-$lastOnline = "%s"; $ONLINE = "";
-if (EXT_IS_ACTIVE("autopurge")) {
+$lastOnline = "%s"; $ONLINE = '';
+if (EXT_IS_ACTIVE('autopurge')) {
        // Use last online timestamp to keep inactive members away from here
        $lastOnline   = " AND last_online >= (UNIX_TIMESTAMP() - %s)";
        $ONLINE = getConfig('ap_inactive_since');
@@ -81,7 +81,7 @@ LIMIT %s",
        array($ONLINE, getConfig('bonus_ranks')), __FILE__, __LINE__);
 
 // Reset temporary variable and check for users
-$OUT = "";
+$OUT = '';
 if (SQL_NUMROWS($result) > 0) {
        // Load our winners...
        $SW = 2; $cnt = 1;
index 9eee48ca05f626065b99feeb467a6962d3f68fef..1fb64f1e65c1c19957377e39688acaadd662f9a7 100644 (file)
@@ -45,11 +45,11 @@ if (!defined('__SECURITY')) {
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 $UID = getUserId();
 $whereStatement = " WHERE `visible`='Y'";
-if (IS_ADMIN()) $whereStatement = "";
+if (IS_ADMIN()) $whereStatement = '';
 
 $result = SQL_QUERY("SELECT id, cat FROM `{!_MYSQL_PREFIX!}_cats`".$whereStatement." ORDER BY `sort`", __FILE__, __LINE__);
 $cats = SQL_NUMROWS($result);
@@ -59,7 +59,7 @@ if ($cats > 0) {
        if (IS_FORM_SENT()) {
                $cnt = 0;
                foreach (REQUEST_POST('cat') as $cat => $joined) {
-                       if ($joined == "N") $cnt++;
+                       if ($joined == 'N') $cnt++;
                }
 
                if (($cats - $cnt) < getConfig('least_cats')) {
@@ -71,8 +71,8 @@ if ($cats > 0) {
        if (IS_FORM_SENT()) {
                foreach (REQUEST_POST('cat') as $cat => $joined) {
                        switch ($joined) {
-                               case "Y":
-                                       $sql = "";
+                               case 'Y':
+                                       $sql = '';
                                        $result_user = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_user_cats` WHERE userid=%s AND cat_id=%s LIMIT 1",
                                         array($UID, bigintval($cat)), __FILE__, __LINE__);
 
@@ -84,7 +84,7 @@ if ($cats > 0) {
                                        }
                                        break;
 
-                               case "N":
+                               case 'N':
                                        $sql = "DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_user_cats` WHERE userid=%s AND cat_id=%s LIMIT 1";
                                        break;
                        }
@@ -96,11 +96,11 @@ if ($cats > 0) {
                }
 
                // Categories saved...
-               LOAD_TEMPLATE("admin_settings_saved", true, getMessage('MEMBER_CATS_SAVED'));
+               LOAD_TEMPLATE('admin_settings_saved', true, getMessage('MEMBER_CATS_SAVED'));
        } else {
                if ($LEAST) {
                        // Also here we have to secure it... :(
-                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('CATS_LEAST'), getConfig('least_cats')));
+                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('CATS_LEAST'), getConfig('least_cats')));
                }
                // Put some data into constants for the template
                define('__ROWS', ($cats*2+4));
@@ -110,24 +110,24 @@ if ($cats > 0) {
 
                // Start switching colors and load all visible categories
                // @TODO Rewrite this to use $OUT .= ...
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Default he has not joined
-                       $content['jn'] = " checked=\"checked\"";
-                       $content['jy'] = "";
+                       $content['jn'] = ' chkecked="checked"';
+                       $content['jy'] = '';
 
                        // When we found an entry don't read it, just change the jx elements
                        if (REQUEST_ISSET_POST(('cat'))) {
                                // Form sent?
                                if (REQUEST_POST('cat', $content['id']) =='Y') {
-                                       $content['jy'] = " checked=\"checked\"";
-                                       $content['jn'] = "";
+                                       $content['jy'] = ' chkecked="checked"';
+                                       $content['jn'] = '';
                                }
                        } else {
                                // Check if he has an entry
-                               if (GET_TOTAL_DATA($UID, "user_cats", "id", "userid", true, sprintf(" AND cat_id=%s", bigintval($content['id']))) == 1) {
-                                       $content['jn'] = "";
-                                       $content['jy'] = " checked=\"checked\"";
+                               if (GET_TOTAL_DATA($UID, "user_cats", "id", 'userid', true, sprintf(" AND cat_id=%s", bigintval($content['id']))) == 1) {
+                                       $content['jn'] = '';
+                                       $content['jy'] = ' chkecked="checked"';
                                }
                        }
 
@@ -144,7 +144,7 @@ if ($cats > 0) {
        }
 } else {
        // No cateogries are defined yet
-       LOAD_TEMPLATE("admin_settings_saved", true, getMessage('MEMBER_NO_CATS'));
+       LOAD_TEMPLATE('admin_settings_saved', true, getMessage('MEMBER_NO_CATS'));
 }
 
 // Free result
index f67a2d4643c8e1cb1d036db4dd91c5aa83fc0ce5..fe209d5cd34229f96592930fc8d938a01c20f23b 100644 (file)
@@ -42,13 +42,13 @@ if (!defined('__SECURITY')) {
        require($INC);
 } elseif (!IS_MEMBER()) {
        LOAD_URL("modules.php[5~?module=index");
-} elseif ((!EXT_IS_ACTIVE("doubler")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "doubler");
+} elseif ((!EXT_IS_ACTIVE('doubler')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'doubler');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Percent values etc.
 define('__CHARGE_VALUE', TRANSLATE_COMMA(getConfig('doubler_charge') * 100));
@@ -58,7 +58,7 @@ define('__MIN_VALUE'   , TRANSLATE_COMMA(getConfig('doubler_min')));
 define('__MAX_VALUE'   , TRANSLATE_COMMA(getConfig('doubler_max')));
 
 // Transfer referal ID
-if (EXT_IS_ACTIVE("nickname")) {
+if (EXT_IS_ACTIVE('nickname')) {
        // Load nickname from DB
        $nick = NICKNAME_GET_NICK(getUserId());
 
index ab4f138e93f690bc80e38f5f88beaab8c7903873..97fe132352085ca0cb80892e015e50c727a5b75e 100644 (file)
@@ -41,13 +41,13 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Simply redirect...
-LOAD_URL("modules.php?module=index");
+LOAD_URL('modules.php?module=index');
 //
 ?>
index d156309ff58c173959605f695e0721e0e0847b08..e33a813917a7248fd38064bb42cdca6ff092451f 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("holiday")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "holiday");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('holiday')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'holiday');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Check for running mail orders in pool
 $result1 = SQL_QUERY_ESC("SELECT timestamp FROM `{!_MYSQL_PREFIX!}_pool`
@@ -79,7 +79,7 @@ if ((SQL_NUMROWS($result1) == 1) || (SQL_NUMROWS($result2) == 1)) {
                }
 
                // Display message and exit here
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('HOLIDAY_MEMBER_ORDER'), MAKE_DATETIME($stamp, "1")));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('HOLIDAY_MEMBER_ORDER'), MAKE_DATETIME($stamp, "1")));
                return;
        }
 }
@@ -130,7 +130,7 @@ WHERE userid=%s LIMIT 1",
                 array(getUserId(), $msg), __FILE__, __LINE__);
 
                // Display message
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('HOLIDAY_IS_ACTIVATED_NOW'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('HOLIDAY_IS_ACTIVATED_NOW'));
        }
 }
 
@@ -143,7 +143,7 @@ WHERE userid=%s LIMIT 1", array(getUserId()), __FILE__, __LINE__);
        list($active, $locked) = SQL_FETCHROW($result);
        SQL_FREERESULT($result);
 
-       if (($active == "Y") && (($locked + getConfig('holiday_lock')) < time()))
+       if (($active == 'Y') && (($locked + getConfig('holiday_lock')) < time()))
        {
                // Load data
                $result = SQL_QUERY_ESC("SELECT holiday_start, holiday_end FROM `{!_MYSQL_PREFIX!}_user_holidays`
@@ -171,14 +171,14 @@ WHERE userid=%s LIMIT 1", array(getUserId()), __FILE__, __LINE__);
                        SEND_ADMIN_NOTIFICATION(getMessage('HOLIDAY_ADMIN_DEAC_SUBJ'), "admin_holiday_deactivated", array(), getUserId());
 
                        // Display message to user
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('HOLIDAY_MEMBER_DEACTIVATED_NOW'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('HOLIDAY_MEMBER_DEACTIVATED_NOW'));
                } else {
                        // Display message to user
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('HOLIDAY_MEMBER_CANNOT_DEACTIVATE'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('HOLIDAY_MEMBER_CANNOT_DEACTIVATE'));
                }
-       } elseif ($active == "Y") {
+       } elseif ($active == 'Y') {
                // To fast!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('HOLIDAY_MEMBER_LOCKED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('HOLIDAY_MEMBER_LOCKED'));
        }
 }
 
@@ -197,7 +197,7 @@ WHERE userid=%s LIMIT 1", array(getUserId()), __FILE__, __LINE__);
                // User can deactivate his holiday request
                switch ($active)
                {
-               case "Y": // Display deactivation form
+               case 'Y': // Display deactivation form
                        // Load starting and ending date
                        $result = SQL_QUERY_ESC("SELECT holiday_start, holiday_end FROM `{!_MYSQL_PREFIX!}_user_holidays`
 WHERE userid=%s LIMIT 1", array(getUserId()), __FILE__, __LINE__);
@@ -229,7 +229,7 @@ WHERE userid=%s LIMIT 1", array(getUserId()), __FILE__, __LINE__);
                        }
                        break;
 
-               case "N": // Display activation form
+               case 'N': // Display activation form
                        // Starting day
                        define('_START_DAY'  , ADD_SELECTION("day"  , date("d", (time() + getConfig('one_day'))), "start"));
                        define('_START_MONTH', ADD_SELECTION("month", date("m", (time() + getConfig('one_day'))), "start"));
@@ -254,7 +254,7 @@ WHERE userid=%s LIMIT 1", array(getUserId()), __FILE__, __LINE__);
                }
        } else {
                // To fast!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('HOLIDAY_MEMBER_LOCKED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('HOLIDAY_MEMBER_LOCKED'));
        }
 }
 //
index af20a603e796b4ee9eb19713e7a4d72dce328499..611788314384eb238f6fe0e471a2ca32e4496bb0 100644 (file)
@@ -41,21 +41,21 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("html_mail")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "html_mail");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('html_mail')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'html_mail');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Class was found and loaded
 if (IS_FORM_SENT()) {
        // Save settings
        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET html='%s' WHERE userid=%s LIMIT 1",
                array(REQUEST_POST('html'), getUserId()), __FILE__, __LINE__);
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_SETTINGS_SAVED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_SETTINGS_SAVED'));
 } else {
        // Load template for changing settings
        $result = SQL_QUERY_ESC("SELECT html FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
@@ -63,12 +63,12 @@ if (IS_FORM_SENT()) {
        list($mode) = SQL_FETCHROW($result);
        SQL_FREERESULT($result);
 
-       if ($mode == "Y") {
-               define('HTML_Y', " checked=\"checked\"");
-               define('HTML_N', "");
+       if ($mode == 'Y') {
+               define('HTML_Y', ' chkecked="checked"');
+               define('HTML_N', '');
        } else {
-               define('HTML_N', " checked=\"checked\"");
-               define('HTML_Y', "");
+               define('HTML_N', ' chkecked="checked"');
+               define('HTML_Y', '');
        }
        LOAD_TEMPLATE("member_html_mail_settings");
 }
index 7571378573ccbc53e0b690f3ad7bb6055e6e88bd..c1b9dc97c605212d98285c7315920c1584b84288 100644 (file)
@@ -41,7 +41,7 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 }
 
 // Base URL for redirection (both cases)
@@ -49,7 +49,7 @@ $URL = "modules.php?module=index&amp;msg=";
 
 if (destroy_user_session()) {
        // Remove theme cookie as well
-       set_session("mxchange_theme", "");
+       set_session("mxchange_theme", '');
 
        // Logout completed
        $URL .= getCode('LOGOUT_DONE');
index e897ad539b7f607617caeec14701226070d52737..4c2f95a026b4ea73edd8c5c325a4bfac293b3833 100644 (file)
@@ -41,16 +41,16 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("mydata")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "mydata");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('mydata')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'mydata');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
-define('UID_VALUE', getUserId()); $URL = "";
+define('UID_VALUE', getUserId()); $URL = '';
 
 // Detect what the member wants to do
 $MODE = "show"; // Show his data
@@ -61,7 +61,7 @@ if (REQUEST_ISSET_POST(('notify'))) $MODE = "notify"; // Switch off notification
 switch ($MODE)
 {
 case "show": // Show his data
-       if (EXT_IS_ACTIVE("country", true)) {
+       if (EXT_IS_ACTIVE('country', true)) {
                // New way                         0        1         2          3         4     5     6        7           8            9       10      11           12           13
                $result = SQL_QUERY_ESC("SELECT surname, family, street_nr, country_code, zip, city, email, birth_day, birth_month, birth_year, gender, max_mails, receive_mails, last_update FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
                 array(UID_VALUE), __FILE__, __LINE__);
@@ -94,7 +94,7 @@ case "show": // Show his data
                default  : define('DOB', $DATA[8]."-".$DATA[7]."-".$DATA[9]); break;
        }
 
-       if (EXT_IS_ACTIVE("country")) {
+       if (EXT_IS_ACTIVE('country')) {
                // Load country's description and code
                $DATA[3] = COUNTRY_GENERATE_INFO($DATA[3]);
        }
@@ -104,7 +104,7 @@ case "show": // Show his data
        break;
 
 case "edit": // Edit data
-       if (EXT_IS_ACTIVE("country", true)) {
+       if (EXT_IS_ACTIVE('country', true)) {
                // New way                         0        1         2          3         4     5     6        7           8            9       10      11           12           13
                $result = SQL_QUERY_ESC("SELECT surname, family, street_nr, country_code, zip, city, email, birth_day, birth_month, birth_year, gender, max_mails, receive_mails, last_update
 FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
@@ -131,23 +131,23 @@ FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
                {
                case "M":
                        define('M_DEFAULT', " selected=\"selected\"");
-                       define('F_DEFAULT', "");
-                       define('C_DEFAULT', "");
+                       define('F_DEFAULT', '');
+                       define('C_DEFAULT', '');
                        break;
 
                case "F":
-                       define('M_DEFAULT', "");
+                       define('M_DEFAULT', '');
                        define('F_DEFAULT', " selected=\"selected\"");
-                       define('C_DEFAULT', "");
+                       define('C_DEFAULT', '');
                        break;
 
                case "C":
-                       define('M_DEFAULT', "");
-                       define('F_DEFAULT', "");
+                       define('M_DEFAULT', '');
+                       define('F_DEFAULT', '');
                        define('C_DEFAULT', " selected=\"selected\"");
                        break;
                }
-               $DOB = "";
+               $DOB = '';
                switch (GET_LANGUAGE())
                {
                case "de": // German date format
@@ -166,13 +166,13 @@ FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
                }
 
                define('DOB', $DOB);
-               define('MAX_REC_LIST', ADD_MAX_RECEIVE_LIST("member", $DATA[11], true));
+               define('MAX_REC_LIST', ADD_MAX_RECEIVE_LIST('member', $DATA[11], true));
 
-               if (EXT_IS_ACTIVE("country")) {
+               if (EXT_IS_ACTIVE('country')) {
                        // Generate selection box
                        $OUT  = "<select name=\"country_code\" class=\"member_select\" size=\"1\">\n";
                        $whereStatement = "WHERE is_active='Y'";
-                       if (IS_ADMIN()) $whereStatement = "";
+                       if (IS_ADMIN()) $whereStatement = '';
                        $OUT .= ADD_OPTION_LINES("countries", "id", "descr", $DATA[3], "code", $whereStatement);
                        $OUT .= "</select>";
                        define('__COUNTRY_CONTENT', $OUT);
@@ -201,26 +201,26 @@ case "save": // Save entered data
                LOAD_TEMPLATE("member_mydata_locked");
        } elseif (!VALIDATE_EMAIL(REQUEST_POST('addy'))) {
                // Invalid email address!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('INVALID_EMAIL_ADDRESS_ENTERED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('INVALID_EMAIL_ADDRESS_ENTERED'));
        } else {
                // Generate hash
                $hash = generateHash(REQUEST_POST('pass1'), substr($DATA[1], 0, -40));
                if ((($hash == $DATA[1]) || (REQUEST_POST('pass1') == REQUEST_POST('pass2'))) && (REQUEST_ISSET_POST(('pass1')))) {
                        // Only on simple changes normal mode is active = no email or password changed
-                       $MODE = "normal"; $AND = "";
+                       $MODE = 'normal'; $AND = '';
 
                        // Did the user changed the password?
-                       if ($hash != $DATA[1]) { $AND = ", password='".$hash."'"; $MODE = "pass"; }
+                       if ($hash != $DATA[1]) { $AND = ", password='".$hash."'"; $MODE = 'pass'; }
 
                        // Or did he changed his password?
                        if (REQUEST_POST('addy') != $DATA[0]) {
                                // Jupp
-                               if ($MODE == "normal") { $MODE = "email"; } else { $MODE .= ";email"; }
+                               if ($MODE == 'normal') { $MODE = 'email'; } else { $MODE .= ";email"; }
                                REQUEST_SET_POST('old_addy', $DATA[0]);
                        }
 
                        // Update member's profile
-                       if (EXT_IS_ACTIVE("country")) {
+                       if (EXT_IS_ACTIVE('country')) {
                                // New way
                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET
 gender='%s', surname='%s', family='%s',
@@ -281,13 +281,13 @@ array(
                        }
 
                        // Get all modes ...
-                       $modes = explode(";", $MODE);
+                       $modes = explode(';', $MODE);
 
                        // ... and run them through
-                       SEND_MODE_MAILS ("mydata", $modes);
+                       SEND_MODE_MAILS ('mydata', $modes);
                } else {
                        // Entered wrong pass for updating profile
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEBER_UPDATE_PWD_WRONG'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEBER_UPDATE_PWD_WRONG'));
                }
        }
        break;
@@ -295,7 +295,7 @@ array(
 case "notify": // Switch off notfication
        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET notified='N', last_update=UNIX_TIMESTAMP() WHERE userid=%s LIMIT 1",
                array(getUserId()), __FILE__, __LINE__);
-       $URL = "modules.php?module=login&amp;what=welcome&amp;msg=".urlencode(getMessage('PROFILE_UPDATED'));
+       $URL = 'modules.php?module=login&amp;what=welcome&amp;msg=' . urlencode(getMessage('PROFILE_UPDATED'));
        break;
 }
 
index ceac5aa82ab173a1221d6085e9351e28db2008af..b4aa6697f3e6cc8a34f15839506019d6fbf32847 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("newsletter")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "newsletter");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('newsletter')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'newsletter');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load status
 $result = SQL_QUERY_ESC("SELECT nl_receive, nl_until, nl_timespan FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
@@ -59,7 +59,7 @@ SQL_FREERESULT($result);
 // Remember charge value
 define('__CHARGE_VALUE', TRANSLATE_COMMA(getConfig('nl_charge')));
 
-if ((IS_FORM_SENT()) && ($status == "Y") && ($span == "0")) {
+if ((IS_FORM_SENT()) && ($status == 'Y') && ($span == "0")) {
        // Save request
        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET nl_timespan='".(getConfig('one_day') * 30)."' WHERE userid=%s LIMIT 1",
                array(getUserId()), __FILE__, __LINE__);
@@ -79,10 +79,10 @@ VALUES ('0','NEW','NL_UNSUBSCRIBE','{--ADMIN_NL_SUBJECT--}','".$admin_msg."', UN
        SEND_ADMIN_NOTIFICATION(getMessage('NL_ADMIN_SUBJECT'), "admin_newsletter_request", array(), getUserId());
 
        // Display message
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('NL_MEMBER_REQUEST_DONE'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('NL_MEMBER_REQUEST_DONE'));
 } elseif ($span > 0) {
        // Already ordered
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('NL_MEMBER_REQUEST_ALREADY'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('NL_MEMBER_REQUEST_ALREADY'));
 } else {
        // Load template for the note
        define('NL_MEMBER_NOTE', LOAD_TEMPLATE("member_newsletter_note", true));
@@ -90,13 +90,13 @@ VALUES ('0','NEW','NL_UNSUBSCRIBE','{--ADMIN_NL_SUBJECT--}','".$admin_msg."', UN
        // Set status message and submit button
        switch ($status)
        {
-       case "Y": // Receives the newsletter
+       case 'Y': // Receives the newsletter
                define('__STATUS_VALUE', getMessage('NL_MEMBER_ON'));
-               define('__UNTIL_VALUE' , "");
+               define('__UNTIL_VALUE' , '');
                define('NL_SUBMIT'     , getMessage('NL_MEMBER_SUBMIT_OFF'));
                break;
 
-       case "N": // Does not receive the newsletter
+       case 'N': // Does not receive the newsletter
                define('__STATUS_VALUE', getMessage('NL_MEMBER_OFF'));
                define('__UNTIL_VALUE' , MAKE_DATETIME($until, "2"));
                define('NL_SUBMIT'     , getMessage('NL_MEMBER_SUBMIT_ON'));
index b3530da502a4af6917abbfdc9f429f5d4713ae73..ebb4035923c76074e4d45e628e33ca06b2d15071 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("nickname")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "nickname");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('nickname')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'nickname');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 $isValid = false;
 
 if (IS_FORM_SENT()) {
@@ -81,14 +81,14 @@ if ($isValid === true) {
        }
 
        // Load template
-       LOAD_TEMPLATE("admin_settings_saved", false, $content);
+       LOAD_TEMPLATE('admin_settings_saved', false, $content);
 } else {
        // Load current nickname
        define('__NICKNAME', NICKNAME_GET_NICK(getUserId()));
 
        // Do we have already submit the form?
        if (REQUEST_ISSET_POST(('nickname'))) {
-               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_failed\">{--NICKNAME_IS_INVALID--}</div");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_failed\">{--NICKNAME_IS_INVALID--}</div");
        } // END - if
 
        // Load Template
index b7612de10b06383972a00cfff144764ba0ce4b5a..5d96988fbb806d87eadc0899d5410c54652bdba5 100644 (file)
@@ -41,34 +41,34 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("order")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "order");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('order')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'order');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
-$URL = ""; $id = 0;
+$URL = ''; $id = 0;
 $whereStatement = " WHERE `visible`='Y'";
 
 // Set undefined array elements
-if (!REQUEST_ISSET_GET(('msg')))       REQUEST_SET_GET('msg'      , "");
-if (!REQUEST_ISSET_POST(('zip')))      REQUEST_SET_POST('zip'     , "");
-if (!REQUEST_ISSET_POST(('html')))     REQUEST_SET_POST('html'    , "");
-if (!REQUEST_ISSET_POST(('receiver'))) REQUEST_SET_POST('receiver', "");
-if (IS_ADMIN()) $whereStatement = "";
+if (!REQUEST_ISSET_GET('msg'))       REQUEST_SET_GET('msg'      , '');
+if (!REQUEST_ISSET_POST('zip'))      REQUEST_SET_POST('zip'     , '');
+if (!REQUEST_ISSET_POST('html'))     REQUEST_SET_POST('html'    , '');
+if (!REQUEST_ISSET_POST('receiver')) REQUEST_SET_POST('receiver', '');
+if (IS_ADMIN()) $whereStatement = '';
 
 // Minimum mails / order
 define('__MIN_VALUE', getConfig('order_min'));
 
 // Count unconfirmed mails
-$links = GET_TOTAL_DATA(getUserId(), "user_links", "id", "userid", true);
+$links = GET_TOTAL_DATA(getUserId(), "user_links", "id", 'userid', true);
 
 // Does the user has more than 0 mails per day set?
-$HOLIDAY = "userid";
-if (GET_EXT_VERSION("holiday") >= "0.1.3") {
+$HOLIDAY = 'userid';
+if (GET_EXT_VERSION('holiday') >= '0.1.3') {
        // Fetch also holiday activation data
        $HOLIDAY = "holiday_active";
 } // END - if
@@ -84,14 +84,14 @@ SQL_FREERESULT($result_mmails);
 if ($HOLIDAY == $DMY) $HOLIDAY='N';
 
 $ALLOWED = $MAXI - $ORDERS;
-if (getConfig('order_max_full') == "MAX") $ALLOWED = $MAXI;
+if (getConfig('order_max_full') == 'MAX') $ALLOWED = $MAXI;
 
 // Now check his points amount
 $total = GET_TOTAL_DATA(getUserId(), "user_points", "points") - GET_TOTAL_DATA(getUserId(), "user_data", "used_points");;
 
-if (($HOLIDAY == "Y") && (GET_EXT_VERSION("holiday") >= "0.1.3")) {
+if (($HOLIDAY == 'Y') && (GET_EXT_VERSION('holiday') >= '0.1.3')) {
        // Holiday is active!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('HOLIDAY_ORDER_NOT_POSSIBLE'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('HOLIDAY_ORDER_NOT_POSSIBLE'));
 } elseif ((REQUEST_ISSET_POST(('frametester'))) && ($ALLOWED > 0) && (REQUEST_POST('receiver') > 0)) {
        // Continue with the frametester, we first need to store the data temporary in the pool
        //
@@ -113,36 +113,36 @@ WHERE sender=%s AND url='%s' AND timestamp > (UNIX_TIMESTAMP() - %s) LIMIT 1",
        if ($type == "TEMP") {
                // No entry found, so we need to check out the stats table as well... :)
                // We have to add that suff here, now we continue WITHOUT checking and check the text and subject against some filters
-               $URL = "";
-               if (getConfig('test_text') == "Y") {
+               $URL = '';
+               if (getConfig('test_text') == 'Y') {
                        // Test submitted text against some filters (length, URLs in text etc.)
                        if ((strpos(strtolower(REQUEST_POST('text')), "https://") > -1) || (strpos(strtolower(REQUEST_POST('text')), "http://") > -1) || (strpos(strtolower(REQUEST_POST('text')), "www") > -1)) {
                                // URL found!
-                               $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('URL_FOUND');
+                               $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('URL_FOUND');
                        } // END - if
 
                        // Remove new-line and carriage-return characters
-                       $TEST = str_replace("\n", "", str_replace("\r", "", REQUEST_POST('text')));
+                       $TEST = str_replace("\n", '', str_replace("\r", '', REQUEST_POST('text')));
 
                        // Text length within allowed length?
                        if (strlen($TEST) > getConfig('max_tlength')) {
                                // Text is too long!
-                               $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('OVERLENGTH');
+                               $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('OVERLENGTH');
                        } // END - if
                } // END - if
 
                // Shall I test the subject line against URLs?
-               if (getConfig('test_subj') == "Y") {
+               if (getConfig('test_subj') == 'Y') {
                        // Check the subject line for issues
                        REQUEST_SET_POST('subject', str_replace("\\", "[nl]", substr(REQUEST_POST('subject'), 0, 200)));
                        if ((strpos(strtolower(REQUEST_POST('subject')), "http://") > -1) || (strpos(strtolower(REQUEST_POST('subject')), "www") > -1)) {
                                // URL in subject found
-                               $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('SUBJ_URL');
+                               $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('SUBJ_URL');
                        } // END - if
                } // END - if
 
                // And shall I check that his URL is not in the black list?
-               if (getConfig('url_blacklist') == "Y") {
+               if (getConfig('url_blacklist') == 'Y') {
                        // Ok, I do that for you know...
                        $result = SQL_QUERY_ESC("SELECT UNIX_TIMESTAMP(`timestamp`) AS tstamp FROM `{!_MYSQL_PREFIX!}_url_blacklist` WHERE `url`='%s' LIMIT 1",
                                array(REQUEST_POST('url')), __FILE__, __LINE__);
@@ -152,7 +152,7 @@ WHERE sender=%s AND url='%s' AND timestamp > (UNIX_TIMESTAMP() - %s) LIMIT 1",
                                list($blist) = SQL_FETCHROW($result);
 
                                // Create redirect-URL
-                               $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('BLIST_URL')."&amp;blist=".$blist;
+                               $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('BLIST_URL')."&amp;blist=".$blist;
                        } // END - if
 
                        // Free result
@@ -162,24 +162,24 @@ WHERE sender=%s AND url='%s' AND timestamp > (UNIX_TIMESTAMP() - %s) LIMIT 1",
                // Enougth receivers entered?
                if ((REQUEST_POST('receiver') < getConfig('order_min')) && (!IS_ADMIN())) {
                        // Less than allowed receivers entered!
-                       $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('MORE_RECEIVERS3');
+                       $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('MORE_RECEIVERS3');
                } // END - if
 
                // Validate URL
                if (!VALIDATE_URL(REQUEST_POST('url'))) {
                        // URL is invalid!
-                       $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('INVALID_URL');
+                       $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('INVALID_URL');
                } // END - if
 
                // Probe for HTML extension
-               if (EXT_IS_ACTIVE("html_mail")) {
+               if (EXT_IS_ACTIVE('html_mail')) {
                        // HTML or regular text mail?
-                       if (REQUEST_POST('html') == "Y") {
+                       if (REQUEST_POST('html') == 'Y') {
                                // Chek for valid HTML tags
                                REQUEST_SET_POST('text', HTML_CHECK_TAGS(REQUEST_POST('text')));
 
                                // Maybe invalid tags found?
-                               if (!REQUEST_ISSET_POST(('text'))) $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('INVALID_TAGS')."&amp;id=".$id;
+                               if (!REQUEST_ISSET_POST(('text'))) $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('INVALID_TAGS')."&amp;id=".$id;
                        } else {
                                // Remove any HTML code
                                REQUEST_SET_POST('text', str_replace("<", "{OPEN_HTML}", str_replace(">", "{CLOSE_HTML}", REQUEST_POST('text'))));
@@ -187,14 +187,14 @@ WHERE sender=%s AND url='%s' AND timestamp > (UNIX_TIMESTAMP() - %s) LIMIT 1",
                }
        } elseif (!IS_ADMIN()) {
                // He has already sent a mail within a specific time
-               $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('URL_TLOCK')."&amp;id=".$id;
+               $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('URL_TLOCK')."&amp;id=".$id;
        }
 
        // Still no error?
        if (empty($URL)) {
                // Check if category and number of receivers is okay
-               $add = "";
-               if ((getConfig('order_multi_page') == "Y") && (REQUEST_ISSET_POST(('zip')))) {
+               $add = '';
+               if ((getConfig('order_multi_page') == 'Y') && (REQUEST_ISSET_POST('zip'))) {
                        // Choose recipients by ZIP code
                        $add = " AND d.zip LIKE '".bigintval(REQUEST_POST('zip'))."{PER}'";
                } // END - if
@@ -216,7 +216,7 @@ ORDER BY d.%s %s",
                if (SQL_NUMROWS($result) >= REQUEST_POST('receiver')) {
                        // Check for holiday extensions
                        $HOLIDAY = false;
-                       if (GET_EXT_VERSION("holiday") >= "0.1.3") {
+                       if (GET_EXT_VERSION('holiday') >= '0.1.3') {
                                // Include checking for users in holiday
                                $HOLIDAY = true;
                        } // END - if
@@ -246,14 +246,14 @@ WHERE userid=%s AND holiday_start < UNIX_TIMESTAMP() AND holiday_end > UNIX_TIME
                        SQL_FREERESULT($result);
 
                        // Implode array into string for the sending pool
-                       $RECEIVER = implode($TEST, ";");
+                       $RECEIVER = implode($TEST, ';');
 
                        // Count array for maximum sent
                        $MAX_SEND = count($TEST);
 
                        // Update receiver list
                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET receive_mails=receive_mails-1 WHERE userid IN (%s) LIMIT %s",
-                               array(str_replace(";", ", ", $RECEIVER), $MAX_SEND), __FILE__, __LINE__);
+                               array(str_replace(';', ", ", $RECEIVER), $MAX_SEND), __FILE__, __LINE__);
 
                        // Is calculated max receivers larger than wanted receivers then reset it
                        if ($MAX_SEND > REQUEST_POST('receiver')) $MAX_SEND = REQUEST_POST('receiver');
@@ -262,7 +262,7 @@ WHERE userid=%s AND holiday_start < UNIX_TIMESTAMP() AND holiday_end > UNIX_TIME
                        $USED = $MAX_SEND * GET_PAY_POINTS(bigintval(REQUEST_POST('type')));
 
                        // Fix empty zip code
-                       if (!REQUEST_ISSET_POST(('zip'))) REQUEST_SET_POST('zip', "0");
+                       if (!REQUEST_ISSET_POST('zip')) REQUEST_SET_POST('zip', "0");
 
                        // Check if he has enougth points for this order and selected more than 0 receivers
                        if (($USED > 0) && ($USED <= $total) && ($MAX_SEND > 0)) {
@@ -271,7 +271,7 @@ WHERE userid=%s AND holiday_start < UNIX_TIMESTAMP() AND holiday_end > UNIX_TIME
                                if (($id == "0") || ($type != "TEMP")) {
                                        // New order
                                        $id = 0;
-                                       if (EXT_IS_ACTIVE("html_mail")) {
+                                       if (EXT_IS_ACTIVE('html_mail')) {
                                                // HTML extension is active
                                                SQL_QUERY_ESC("INSERT INTO `{!_MYSQL_PREFIX!}_pool` (sender, subject, text, receivers, payment_id, data_type, timestamp, url, cat_id, target_send, zip, html_msg)
  VALUES ('%s','%s','%s','%s','%s','TEMP','%s','%s','%s','%s','%s','%s')",
@@ -307,7 +307,7 @@ array(
                                        }
                                } else {
                                        // Change current order
-                                       if (EXT_IS_ACTIVE("html_mail")) {
+                                       if (EXT_IS_ACTIVE('html_mail')) {
                                                // HTML extension is active
                                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_pool` SET
 subject='%s',
@@ -379,22 +379,22 @@ array(
                                $URL = "modules.php?module=frametester&amp;order=".$id."";
                        } elseif ($MAX_SEND == 0) {
                                // Not enougth receivers found which can receive mails
-                               $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('MORE_RECEIVERS2');
+                               $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('MORE_RECEIVERS2');
                        } else {
                                // No enougth points left!
-                               $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('MORE_POINTS');
+                               $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('MORE_POINTS');
                        }
                } else  {
                        // Ordered more mails than he can send in this category
-                       $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('NO_RECS_LEFT');
+                       $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('NO_RECS_LEFT');
                }
        }
 } elseif (REQUEST_POST('receiver') == "0") {
        // Not enougth receivers selected
-       $URL = "modules.php?module=login&amp;what=order&amp;msg=".getCode('MORE_RECEIVERS1');
-} elseif (($ALLOWED == 0) && (getConfig('order_max_full') == "ORDER")) {
+       $URL = 'modules.php?module=login&amp;what=order&amp;msg=' . getCode('MORE_RECEIVERS1');
+} elseif (($ALLOWED == 0) && (getConfig('order_max_full') == 'ORDER')) {
        // No more mail orders allowed
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_ORDER_ALLOWED_EXHAUSTED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_ORDER_ALLOWED_EXHAUSTED'));
 } elseif (($links < getConfig('unconfirmed')) && ($mmails == "1")) {
        // Display order form
        $result_cats = SQL_QUERY("SELECT id, cat FROM `{!_MYSQL_PREFIX!}_cats`".$whereStatement." ORDER BY `sort`", __FILE__, __LINE__);
@@ -408,9 +408,9 @@ array(
                        );
 
                        // Enable HTML checking
-                       $HTML = ""; $HOLIDAY = false; $HOL_STRING = "";
-                       if ((EXT_IS_ACTIVE("html_mail")) && (REQUEST_POST('html') == "Y")) $HTML = " AND html='Y'";
-                       if (GET_EXT_VERSION("holiday") >= "0.1.3") {
+                       $HTML = ''; $HOLIDAY = false; $HOL_STRING = '';
+                       if ((EXT_IS_ACTIVE('html_mail')) && (REQUEST_POST('html') == 'Y')) $HTML = " AND html='Y'";
+                       if (GET_EXT_VERSION('holiday') >= '0.1.3') {
                                // Extension's version is fine
                                $HOLIDAY = true; $HOL_STRING = " AND holiday_active='N'";
                        } // END - if
@@ -450,7 +450,7 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                                                $result_ver = SQL_QUERY_ESC("SELECT zip FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s".$HTML." AND receive_mails > 0 AND `status`='CONFIRMED' LIMIT 1",
                                                        array(bigintval($ucat)), __FILE__, __LINE__);
 
-                                               if ((SQL_NUMROWS($result_ver) == 1) && (REQUEST_ISSET_POST(('zip'))) && (getConfig('order_multi_page') == "Y")) {
+                                               if ((SQL_NUMROWS($result_ver) == 1) && (REQUEST_ISSET_POST('zip')) && (getConfig('order_multi_page') == 'Y')) {
                                                        list($zip) = SQL_FETCHROW($result_ver);
                                                        SQL_FREERESULT($result_ver);
                                                        if (substr($zip, 0, strlen(REQUEST_POST('zip'))) == REQUEST_POST('zip')) {
@@ -478,7 +478,7 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                        $typeS = array();
                        if (SQL_NUMROWS($result) > 0) {
                                // Check for message ID in URL
-                               $message = "";
+                               $message = '';
                                switch (REQUEST_GET('msg'))
                                {
                                case getCode('URL_TLOCK'):
@@ -563,7 +563,7 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
 
                                if (!empty($message)) {
                                        // We got system message so we drop it out to the user
-                                       LOAD_TEMPLATE("admin_settings_saved", false, $message);
+                                       LOAD_TEMPLATE('admin_settings_saved', false, $message);
                                } // END - if
 
                                // Load all email types...
@@ -580,11 +580,11 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                                // Check how many mail orders he has placed today and how many he's allowed to send
                                switch (getConfig('order_max_full'))
                                {
-                               case "MAX": // He is allowed to send as much as possible
+                               case 'MAX': // He is allowed to send as much as possible
                                        define('ORDER_MAX_VALUE', getMessage('ORDER_ALLOWED_MAX'));
                                        break;
 
-                               case "ORDER": // He is allowed to send as much as he setup the receiving value
+                               case 'ORDER': // He is allowed to send as much as he setup the receiving value
                                        define('ORDER_MAX_VALUE', sprintf(getMessage('ORDER_ALLOWED_RECEIVE'), $ALLOWED, $MAXI));
                                        break;
 
@@ -598,7 +598,7 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                                LOAD_TEMPLATE("member_order_points", false, $total);
 
                                // Reset variables
-                               $OLD_ORDER = false; $subject = ""; $text = ""; $target = "";
+                               $OLD_ORDER = false; $subject = ''; $text = ''; $target = '';
 
                                // Check if we already have an order placed and make it editable
                                $result = SQL_QUERY_ESC("SELECT subject, text, payment_id, timestamp, url, target_send, cat_id, zip FROM `{!_MYSQL_PREFIX!}_pool` WHERE sender=%s AND data_type='TEMP' LIMIT 1",
@@ -622,9 +622,9 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                                SQL_FREERESULT($result);
 
                                // 01      2              21    12                                    2    23         443    3          3210
-                               if ((REQUEST_ISSET_POST(('data'))) || ((getConfig('order_multi_page') != "Y") && ((!IS_ADMIN()) && (!EXT_IS_ACTIVE("html_mail"))))) {
+                               if ((REQUEST_ISSET_POST(('data'))) || ((getConfig('order_multi_page') != "Y") && ((!IS_ADMIN()) && (!EXT_IS_ACTIVE('html_mail'))))) {
                                        // Pre-output categories
-                                       $CAT = "";
+                                       $CAT = '';
                                        foreach ($CATS['id'] as $key => $value) {
                                                $CAT .= "      <option value=\"".$value."\"";
                                                if (($OLD_ORDER) && ($content['cat'] == $value)) $CAT .= " selected=\"selected\"";
@@ -632,7 +632,7 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                                        } // END - foreach
 
                                        // Mail type
-                                       $type = "";
+                                       $type = '';
                                        foreach ($typeS as $key => $value) {
                                                $P = TRANSLATE_COMMA($typeS[$key][1]);
                                                if (is_array($value)) {
@@ -651,7 +651,7 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                                        define('TEXT', COMPILE_CODE($text));
                                        define('T_URL', $url);
 
-                                       if (REQUEST_ISSET_POST(('zip'))) {
+                                       if (REQUEST_ISSET_POST('zip')) {
                                                // Output entered ZIP code
                                                define('ZIP_OUTPUT', LOAD_TEMPLATE("member_order-zip2", true, REQUEST_POST('zip')));
                                        } else {
@@ -659,7 +659,7 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                                        }
 
                                        // HTML extension
-                                       if ((EXT_IS_ACTIVE("html_mail")) && (REQUEST_POST('html') == "Y")) {
+                                       if ((EXT_IS_ACTIVE('html_mail')) && (REQUEST_POST('html') == 'Y')) {
                                                // Extension is active so output valid HTML tags
                                                define('MEMBER_HTML_EXTENSION', LOAD_TEMPLATE("member_order-html_ext", true, HTML_ADD_VALID_TAGS()));
                                        } else {
@@ -671,10 +671,10 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                                        LOAD_TEMPLATE("member_order_page2");
                                } else {
                                        // Remember maybe entered ZIP code in constant
-                                       $add = "";
-                                       if (EXT_IS_ACTIVE("html_mail")) {
+                                       $add = '';
+                                       if (EXT_IS_ACTIVE('html_mail')) {
                                                // Add some content when html extension is active
-                                               if ((getConfig('order_multi_page') == "Y") || (IS_ADMIN())) $add = "<tr><td colspan=\"2\" class=\"seperator bottom2\" height=\"5\">&nbsp;</td></tr>\n";
+                                               if ((getConfig('order_multi_page') == 'Y') || (IS_ADMIN())) $add = "<tr><td colspan=\"2\" class=\"seperator bottom2\" height=\"5\">&nbsp;</td></tr>\n";
                                                define('MEMBER_HTML_EXTENSION', LOAD_TEMPLATE("member_order-html_intro", true));
                                        } else {
                                                // No HTML extension installed
@@ -682,7 +682,7 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                                        }
 
                                        // Do we want ZIP code or not?
-                                       if ((getConfig('order_multi_page') == "Y") || (IS_ADMIN())) {
+                                       if ((getConfig('order_multi_page') == 'Y') || (IS_ADMIN())) {
                                                // Yes
                                                if (REQUEST_POST('zip') > 0) {
                                                        $content = array(
@@ -698,7 +698,7 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                                                define('MEMBER_ZIP_CONTENT', LOAD_TEMPLATE("member_order-zip1", true, $content));
                                        } else {
                                                // No
-                                               define('MEMBER_ZIP_CONTENT', "");
+                                               define('MEMBER_ZIP_CONTENT', '');
                                        }
 
                                        // Output form for page 1 (ZIP code or HTML)
@@ -706,22 +706,22 @@ LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
                                }
                        } else {
                                // No mail types defined
-                               LOAD_TEMPLATE("admin_settings_saved", false, "<span class=\"member_failed\">{--MEMBER_NO_PAYMENTS--}</span>");
+                               LOAD_TEMPLATE('admin_settings_saved', false, "<span class=\"member_failed\">{--MEMBER_NO_PAYMENTS--}</span>");
                        }
                } else {
                        // No points left
-                       LOAD_TEMPLATE("admin_settings_saved", false, "<span class=\"member_failed\">{--MEMBER_NO_POINTS--}</span>");
+                       LOAD_TEMPLATE('admin_settings_saved', false, "<span class=\"member_failed\">{--MEMBER_NO_POINTS--}</span>");
                }
        } else {
                // No cateogries are defined yet
-               LOAD_TEMPLATE("admin_settings_saved", false, "<span class=\"member_failed\">{--MEMBER_NO_CATS--}</span>");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<span class=\"member_failed\">{--MEMBER_NO_CATS--}</span>");
        }
 } elseif ($mmails == "0") {
        // Please set more than 0 mails per day
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_HAS_ZERO_MMAILS'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_HAS_ZERO_MMAILS'));
 } else {
        // Please confirm some mails first
-       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('MEMBER_LINKS_LEFT'), $links, getConfig('unconfirmed')));
+       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('MEMBER_LINKS_LEFT'), $links, getConfig('unconfirmed')));
 }
 
 if (!empty($URL)) {
index 07a0dd7428e1ae2b1600eccb4e724758d0f38eec..14c078d039f7aec5d519e3ef260d172539865801 100644 (file)
@@ -43,14 +43,14 @@ if (!defined('__SECURITY')) {
        require($INC);
 } elseif (!IS_MEMBER()) {
        // Not logged in
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("payout")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "payout");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('payout')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'payout');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 $result_depths = SQL_QUERY("SELECT level, percents FROM `{!_MYSQL_PREFIX!}_refdepths` ORDER BY level", __FILE__, __LINE__);
 $TPTS = 0;
@@ -104,14 +104,14 @@ ORDER BY p.payout_timestamp DESC",
                 array(getUserId()), __FILE__, __LINE__);
                if (SQL_NUMROWS($result_payouts) > 0) {
                        // List all his requests
-                       $OUT = ""; $SW = 2;
+                       $OUT = ''; $SW = 2;
                        while ($content = SQL_FETCHARRAY($result_payouts)) {
                                // Translate status
                                $content['status'] = getMessage('PAYOUT_MEMBER_STATUS_'.strtoupper($content['status']).'');
                                $content['status'] = "<div class=\"member_failed\">".$content['status']."</div>";
 
                                // Nothing entered must be secured in member/what-payputs.php !
-                               if ($content['allow'] == "Y") {
+                               if ($content['allow'] == 'Y') {
                                        // Banner/Textlink views/clicks request
                                        if (!empty($content['banner'])) {
                                                // Banner
@@ -190,10 +190,10 @@ ORDER BY p.payout_timestamp DESC",
                                define('PAYOUT_POINTS_VALUE', $PAYOUT);
 
                                // Subtract points from member's account
-                               SUB_POINTS("payout", getUserId(), $PAYOUT);
+                               SUB_POINTS('payout', getUserId(), $PAYOUT);
 
                                // Add entry to his tranfer history
-                               if ($content['allow'] == "Y") {
+                               if ($content['allow'] == 'Y') {
                                        // Banner/textlink ordered
                                        SQL_QUERY_ESC("INSERT INTO `{!_MYSQL_PREFIX!}_user_payouts` (userid, payout_total, payout_id, payout_timestamp, status, target_url, link_text, banner_url)
 VALUES (%s,%s,%s, UNIX_TIMESTAMP(), 'NEW','%s','%s','%s')",
@@ -208,7 +208,7 @@ VALUES (%s,%s,%s, UNIX_TIMESTAMP(), 'NEW','%s','%s','%s')",
 
                                        // Load templates
                                        $msg_mem = LOAD_EMAIL_TEMPLATE("member_payout_request_banner", array(), getUserId());
-                                       if (GET_EXT_VERSION("admins") >= "0.4.1") {
+                                       if (GET_EXT_VERSION('admins') >= '0.4.1') {
                                                $adm_tpl = "admin_payout_request_banner";
                                        } else {
                                                $msg_adm = LOAD_EMAIL_TEMPLATE("admin_payout_request_banner", array(), getUserId());
@@ -229,8 +229,8 @@ VALUES (%s,%s,%s,'%s',%s, UNIX_TIMESTAMP(), 'NEW','%s')",
                                        // Load templates
                                        $msg_mem = LOAD_EMAIL_TEMPLATE("member_payout_request", array(), getUserId());
                                        $msg_adm = LOAD_EMAIL_TEMPLATE("admin_payout_request", array(), getUserId());
-                                       $admin_tpl = "";
-                                       if (GET_EXT_VERSION("admins") >= "0.4.1")
+                                       $admin_tpl = '';
+                                       if (GET_EXT_VERSION('admins') >= '0.4.1')
                                        {
                                                $admin_tpl = "admin_payout_request";
                                        }
@@ -251,8 +251,8 @@ VALUES (0, 'NEW','PAYOUT_REQUEST','[payout:] {--PAYOUT_REQUEST_ADMIN--}','%s', U
                                SEND_ADMIN_NOTIFICATION(getMessage('PAYOUT_REQUEST_ADMIN'), $admin_tpl, array(), getUserId());
 
                                // Load template and output it
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PAYOUT_REQUEST_SENT'));
-                       } elseif ($content['allow'] == "Y") {
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PAYOUT_REQUEST_SENT'));
+                       } elseif ($content['allow'] == 'Y') {
                                // Prepare content
                                $content = array(
                                        'payout' => bigintval(REQUEST_GET('payout'))
@@ -271,11 +271,11 @@ VALUES (0, 'NEW','PAYOUT_REQUEST','[payout:] {--PAYOUT_REQUEST_ADMIN--}','%s', U
                        }
                } else {
                        // Not enougth points
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PAYOUT_POINTS_NOT_ENOUGTH'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PAYOUT_POINTS_NOT_ENOUGTH'));
                }
        } else {
                // ID is invalid
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PAYOUT_ID_INVALID'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PAYOUT_ID_INVALID'));
        }
 }
 
index ac4344a25d896b9546f7674489195c34ce41264a..fd3c0e1b7e6a6ffc54aa5c4017b3404ace90f74b 100644 (file)
@@ -41,26 +41,26 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 $result_depths = SQL_QUERY("SELECT level, percents FROM `{!_MYSQL_PREFIX!}_refdepths` ORDER BY level", __FILE__, __LINE__);
 $depths = SQL_NUMROWS($result_depths);
 
 // Add many more rows for the login/turbo/ref/order bonus
 // @TODO Should we rewrite this to a filter?
-if (!EXT_IS_ACTIVE("bonus")) $depths += 1;
-if (GET_EXT_VERSION("bonus") >= "0.2.2") $depths += 6;
-if (GET_EXT_VERSION("bonus") >= "0.4.4") $depths += 4;
+if (!EXT_IS_ACTIVE('bonus')) $depths += 1;
+if (GET_EXT_VERSION('bonus') >= '0.2.2') $depths += 6;
+if (GET_EXT_VERSION('bonus') >= '0.4.4') $depths += 4;
 
 // Remember row count in constant
 define('__ROWS_VALUE', ($depths*2+15));
 
 // Init some vars...
-$TPTS = 0; $TREF = 0; $TLOCK = 0; $OUT = "";
+$TPTS = 0; $TREF = 0; $TLOCK = 0; $OUT = '';
 
 // Load ref levels
 while ($content = SQL_FETCHARRAY($result_depths)) {
@@ -116,9 +116,9 @@ SQL_FREERESULT($result);
 $CONFIRMED = "---"; $SENT = "---"; $RECEIVED = "---";
 
 // Only user >= v0.1.2: Fetch confirmed mails counter
-if (GET_EXT_VERSION("user") >= "0.1.2") {
-       $add = "";
-       if (GET_EXT_VERSION("user") >= "0.1.4") {
+if (GET_EXT_VERSION('user') >= '0.1.2') {
+       $add = '';
+       if (GET_EXT_VERSION('user') >= '0.1.4') {
                $add = ", emails_sent, emails_received";
        }
        $result = SQL_QUERY_ESC("SELECT mails_confirmed".$add." FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1", array(getUserId()), __FILE__, __LINE__);
@@ -143,12 +143,12 @@ 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")) setConfigEntry('bonus_active', "X");
+if (EXT_VERSION_IS_OLDER('bonus', '0.4.4')) setConfigEntry('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")) {
+if ((GET_EXT_VERSION('bonus') >= '0.2.2') && (EXT_IS_ACTIVE('bonus')) && (getConfig('bonus_active') == 'Y')) {
        $add = ", 0, 0, 0";
-       if (GET_EXT_VERSION("bonus") >= "0.4.4") $add = ", bonus_ref, bonus_order, bonus_stats";
+       if (GET_EXT_VERSION('bonus') >= '0.4.4') $add = ", bonus_ref, bonus_order, bonus_stats";
 
        // Load data
        $result = SQL_QUERY_ESC("SELECT login_bonus, turbo_bonus".$add." FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
@@ -162,7 +162,7 @@ if ((GET_EXT_VERSION("bonus") >= "0.2.2") && (EXT_IS_ACTIVE("bonus")) && (getCon
        define('__TURBO_VALUE',  TRANSLATE_COMMA($turbo));
        define('__LOGIN_VALUE',  TRANSLATE_COMMA($login));
 
-       if (GET_EXT_VERSION("bonus") >= "0.4.4") {
+       if (GET_EXT_VERSION('bonus') >= '0.4.4') {
                // Add referal, stats and order bonys
                define('__REF_VALUE'  ,  TRANSLATE_COMMA($ref));
                define('__ORDER_VALUE',  TRANSLATE_COMMA($order));
@@ -177,12 +177,12 @@ if ((GET_EXT_VERSION("bonus") >= "0.2.2") && (EXT_IS_ACTIVE("bonus")) && (getCon
 } elseif (getConfig('bonus_active') != "Y") {
        // Bonus active rallye deactivated
        define('__SPECIAL_ROWS', LOAD_TEMPLATE("member_points_bonus_disabled", true));
-} elseif ((IS_ADMIN()) && (EXT_VERSION_IS_OLDER("bonus", "0.2.2")) && (EXT_IS_ACTIVE("bonus"))) {
+} elseif ((IS_ADMIN()) && (EXT_VERSION_IS_OLDER('bonus', '0.2.2')) && (EXT_IS_ACTIVE('bonus'))) {
        // Please upgrade your bonus extension to v0.2.2 or newer!
        define('__SPECIAL_ROWS', LOAD_TEMPLATE("member_points_upgrade"));
 } else {
        // Members shall see no special rows here
-       define('__SPECIAL_ROWS', "");
+       define('__SPECIAL_ROWS', '');
 }
 
 // Remeber values for the final template
@@ -192,18 +192,18 @@ define('__RECEIVE_VALUE'  , $RECEIVED);
 define('__SENT_VALUE'     , $SENT);
 
 // Load final template
-if (EXT_IS_ACTIVE("user")) {
+if (EXT_IS_ACTIVE('user')) {
        // Load template when required extension is there
        LOAD_TEMPLATE("member_points");
 } elseif (IS_ADMIN()) {
        // Missing extension
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "user");
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'user');
 } else {
        // Message for user
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PROBLEM_POINTS_OVERVIEW_UNAVAILABLE'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PROBLEM_POINTS_OVERVIEW_UNAVAILABLE'));
 }
 
-if (EXT_IS_ACTIVE("payout")) {
+if (EXT_IS_ACTIVE('payout')) {
        // Payput extension is installed and active so we can check if the user has enougth points
        PAYOUT_OUTPUT_PAYOUT_LIST(REVERT_COMMA(($TPTS - $USED)));
 }
index 53d8284c5a4cd5370d1e30896d8e839705cba147..23f6823ce24e5f369ad94f31fcf94b02542a3c36 100644 (file)
@@ -42,20 +42,20 @@ if (!defined('__SECURITY')) {
        require($INC);
 } elseif (!IS_MEMBER()) {
        // User is not logged in
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("primera")) && (!IS_ADMIN())) {
-       // Extension "primera" is not activated
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "primera");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('primera')) && (!IS_ADMIN())) {
+       // Extension 'primera' is not activated
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'primera');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Check if the admin has entered the data
 if ((getConfig('primera_api_name') == "") || (getConfig('primera_api_md5') == "")) {
        // Something important is missing...
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PRIMERA_MEMBER_API_DATA_MISSING'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PRIMERA_MEMBER_API_DATA_MISSING'));
        return;
 }
 
@@ -90,7 +90,7 @@ if (!REQUEST_ISSET_GET(('mode'))) {
                        array(getUserId()), __FILE__, __LINE__);
 
                // Load all rows
-               $content['rows'] = ""; $SW = 2;
+               $content['rows'] = ''; $SW = 2;
                while ($data = SQL_FETCHARRAY($result)) {
                        // Prepare data for output
                        $rowContent = array(
@@ -128,7 +128,7 @@ if (REQUEST_GET('mode') == "pay") {
        // Is this enougth for a payout?
        if ($points < getConfig('primera_min_payout')) {
                // No, then abort here
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('PRIMERA_MEMBER_MIN_PAYOUT_PAYOUT'), TRANSLATE_COMMA(getConfig('primera_min_payout'))));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('PRIMERA_MEMBER_MIN_PAYOUT_PAYOUT'), TRANSLATE_COMMA(getConfig('primera_min_payout'))));
                return;
        }
 
@@ -137,7 +137,7 @@ if (REQUEST_GET('mode') == "pay") {
        $content['min_points']  = TRANSLATE_COMMA(getConfig('primera_min_payout'));
 
        // Get Primera id
-       $content['primera_nickname'] = "";
+       $content['primera_nickname'] = '';
        $result = SQL_QUERY_ESC("SELECT primera_userid FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
                array(getUserId()), __FILE__, __LINE__);
 
@@ -151,7 +151,7 @@ if (REQUEST_GET('mode') == "pay") {
        SQL_FREERESULT($result);
 } else {
        // Invalid mode!
-       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('PRIMERA_MEMBER_MODE_INVALID'), REQUEST_GET(('mode'))));
+       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('PRIMERA_MEMBER_MODE_INVALID'), REQUEST_GET(('mode'))));
        return;
 }
 
@@ -163,22 +163,22 @@ if ((IS_FORM_SENT()) && (REQUEST_ISSET_GET(('mode')))) {
                        // Is the user ID and password set?
                        if (!REQUEST_ISSET_POST(('primera_nickname'))) {
                                // Nothing entered in Primus nickname
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PRIMERA_MEMBER_EMPTY_USERNAME'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PRIMERA_MEMBER_EMPTY_USERNAME'));
                        } elseif (!REQUEST_ISSET_POST(('primera_password'))) {
                                // Nothing entered in Primera password
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PRIMERA_MEMBER_EMPTY_PASSWORD'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PRIMERA_MEMBER_EMPTY_PASSWORD'));
                        } elseif (!REQUEST_ISSET_POST(('amount'))) {
                                // Nothing entered in amount
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PRIMERA_MEMBER_EMPTY_AMOUNT'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PRIMERA_MEMBER_EMPTY_AMOUNT'));
                        } elseif (REQUEST_POST('amount') != bigintval(REQUEST_POST('amount'))) {
                                // Only numbers in amount!
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PRIMERA_MEMBER_INVALID_AMOUNT'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PRIMERA_MEMBER_INVALID_AMOUNT'));
                        } elseif (REQUEST_POST('amount') < getConfig('primera_min_payout')) {
                                // Not enougth entered!
-                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('PRIMERA_MEMBER_AMOUNT_SMALLER_MIN'), getConfig(('primera_min_payout'))));
+                               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('PRIMERA_MEMBER_AMOUNT_SMALLER_MIN'), getConfig(('primera_min_payout'))));
                        } elseif (REQUEST_POST('amount') > $points) {
                                // Not enougth points left!
-                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('PRIMERA_MEMBER_PAYOUT_POINTS_DEPLETED'), bigintval(REQUEST_POST('amount')), bigintval($points)));
+                               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('PRIMERA_MEMBER_PAYOUT_POINTS_DEPLETED'), bigintval(REQUEST_POST('amount')), bigintval($points)));
                        } else {
                                // All is fine here so do the payout
                                $success = PRIMERA_EXECUTE_PAYOUT(REQUEST_POST('primera_nickname'), md5(REQUEST_POST('primera_password')), REQUEST_POST('amount'));
@@ -200,21 +200,21 @@ if ((IS_FORM_SENT()) && (REQUEST_ISSET_GET(('mode')))) {
                                                array(REQUEST_POST('primera_nickname'), getUserId()), __FILE__, __LINE__);
 
                                        // All done!
-                                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('PRIMERA_MEMBER_PAYOUT_DONE'));
+                                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('PRIMERA_MEMBER_PAYOUT_DONE'));
                                        return;
                                } elseif ((GET_PRIMERA_ERROR_CODE() == "user_failed") || (GET_PRIMERA_ERROR_CODE() == "own_failed") || (GET_PRIMERA_ERROR_CODE() == "amount_failed") || (GET_PRIMERA_ERROR_CODE() == "api_amount_failed")) {
                                        // Wrong login data
-                                       LOAD_TEMPLATE("admin_settings_saved", false, GET_PRIMERA_ERROR_MESSAGE());
+                                       LOAD_TEMPLATE('admin_settings_saved', false, GET_PRIMERA_ERROR_MESSAGE());
                                } else {
                                        // Something went wrong
-                                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('PRIMERA_MEMBER_PAYOUT_FAILED'), GET_PRIMERA_ERROR_MESSAGE()));
+                                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('PRIMERA_MEMBER_PAYOUT_FAILED'), GET_PRIMERA_ERROR_MESSAGE()));
                                }
                        }
                        break;
 
                default: // Invalid mode!
                        DEBUG_LOG(__FILE__, __LINE__, sprintf("Invalid mode %s detected.", REQUEST_GET('mode')));
-                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('PRIMERA_MEMBER_MODE_INVALID'), REQUEST_GET(('mode'))));
+                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('PRIMERA_MEMBER_MODE_INVALID'), REQUEST_GET(('mode'))));
                        return;
        }
 } // END - if
index 465f9d5b9a546778f820c76da5c3cb9d22abcd9b..287c51f5f06726b9958ed55a9b8a0c04fee05c87 100644 (file)
@@ -41,20 +41,20 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("rallye")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "rallye");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('rallye')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'rallye');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 OUTPUT_HTML("<div align=\"center\">");
 
 // Check for possible running rallyes
 $ADMIN = " AND d.is_active='Y'";
-if (IS_ADMIN()) $ADMIN = "";
+if (IS_ADMIN()) $ADMIN = '';
 $result = SQL_QUERY("SELECT DISTINCT d.id, d.admin_id, a.login, d.title, d.descr, d.template, d.start_time, d.end_time, d.min_users, d.min_prices
  FROM `{!_MYSQL_PREFIX!}_rallye_data` AS d, `{!_MYSQL_PREFIX!}_admins` AS a
  WHERE d.admin_id=a.id".$ADMIN." AND d.notified='Y'
@@ -105,7 +105,7 @@ if (SQL_NUMROWS($result) == 1) {
                define('__RALLYE_TOP_USERS', "<div align=\"center\" class=\"big\">{!__RALLYE_EXTRAS!}</div>");
                define('__RALLYE_CAN_WIN_THIS', getMessage('RALLYE_OUR_WINNERS_ARE'));
        } else {
-               define('__RALLYE_PRICES', RALLYE_ADD_PRICES($id, "html"));
+               define('__RALLYE_PRICES', RALLYE_ADD_PRICES($id, 'html'));
                define('__RALLYE_TOP_USERS', RALLYE_ADD_TOPUSERS($id, getUserId()));
                define('__RALLYE_CAN_WIN_THIS', getMessage('RALLYE_YOU_CAN_WIN'));
        }
index 06d202d1709cb7ca078846081adb4af8963e20d7..922861be91a481525842c17d439c0782435618d9 100644 (file)
@@ -42,22 +42,22 @@ if (!defined('__SECURITY')) {
        require($INC);
 } elseif (!IS_MEMBER()) {
        // User is not logged in
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("refback")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "refback");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('refback')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'refback');
        return;
 }
 
 // Is the refback system enabled?
 if (getConfig('refback_enabled') != "Y") {
        // Output message
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_REFBACK_DISABLED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_REFBACK_DISABLED'));
        // Abort here
        return false;
 } // END - if
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Was the form submitted?
 if ((REQUEST_ISSET_POST('edit')) && (REQUEST_ISSET_POST(('id')))) {
@@ -74,17 +74,17 @@ if ((REQUEST_ISSET_POST('edit')) && (REQUEST_ISSET_POST(('id')))) {
                        // Check status
                        if (isset($status['ok'])) {
                                // No message found
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_REFBACK_DONE'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_REFBACK_DONE'));
                        } elseif (isset($status['message'])) {
                                // Something went wrong with error message
-                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('MEMBER_REFBACK_ERROR_MESSAGE'), $status['message']));
+                               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('MEMBER_REFBACK_ERROR_MESSAGE'), $status['message']));
                        } else {
                                // No message found
-                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_REFBACK_ERROR_EMPTY_MESSAGE'));
+                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_REFBACK_ERROR_EMPTY_MESSAGE'));
                        }
                } else {
                        // Percents out-of-bounds ;-)
-                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('MEMBER_REFBACK_ERROR_OUT_OF_BOUNDS'), getConfig('refback_min_perc'), getConfig('refback_max_perc')));
+                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('MEMBER_REFBACK_ERROR_OUT_OF_BOUNDS'), getConfig('refback_min_perc'), getConfig('refback_max_perc')));
                }
 
                // Insert line
@@ -112,10 +112,10 @@ ORDER BY r.level ASC",
 // Are there some entries? (Shall be!)
 if (SQL_NUMROWS($result) > 0) {
        // List all levels
-       $OUT = "";
+       $OUT = '';
        while ($content = SQL_FETCHARRAY($result)) {
                // Init variables
-               $rows = "";
+               $rows = '';
                $counter = 0;
                $SW = 2;
 
@@ -157,7 +157,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("member_refback_list", false, $OUT);
 } else {
        // No entries
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_REFBACK_NO_ENTRIES'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_REFBACK_NO_ENTRIES'));
 }
 
 // Free result
index 4e186055a9bb536dfdff9bf9f639687506c23f87..751ff784dfb499c9628758be4c2550b3816a4440 100644 (file)
@@ -41,11 +41,11 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load current referal clicks
 $result = SQL_QUERY_ESC("SELECT ref_clicks FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
@@ -57,7 +57,7 @@ OUTPUT_HTML("<div class=\"tiny\">{--YOUR_PERSONAL_REFLINK--}:<br />
 <strong><a href=\"{!URL!}/ref.php?refid=".getUserId()."\" target=\"_blank\">{!URL!}/ref.php?ref=".getUserId()."</a></strong><br />
 <br />");
 
-if (EXT_IS_ACTIVE("nickname")) {
+if (EXT_IS_ACTIVE('nickname')) {
        // Add nickname link when nickname is entered
        $nick = NICKNAME_GET_NICK(getUserId());
 
@@ -76,17 +76,17 @@ if (EXT_IS_ACTIVE("nickname")) {
 // Clicks on your reflink
 OUTPUT_HTML("{--YOUR_REFCLICKS--}: <strong>".$c."</strong> {--CLICKS--}</div><br /><br />");
 $whereStatement = " WHERE `visible`='Y'";
-if (IS_ADMIN()) $whereStatement = "";
+if (IS_ADMIN()) $whereStatement = '';
 $result = SQL_QUERY("SELECT id, url, alternate, counter, clicks FROM `{!_MYSQL_PREFIX!}_refbanner`", __FILE__, __LINE__);
 
 if (SQL_NUMROWS($result) > 0) {
        // List available ref banners
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($content = SQL_FETCHARRAY($result)) {
                $test = str_replace(constant('URL'), constant('PATH'), $content['url']); $size = 0;
                if ($test == $content['url']) {
                        // Download banner (I hope you keep the banner on same server???)
-                       $fp = GET_URL($content['url']); $bannerContent = "";
+                       $fp = GET_URL($content['url']); $bannerContent = '';
                        if ((!empty($fp)) && (is_array($fp)) && (count($fp) > 0) {
                                // Loads only found banner, when there is a 404 error this foreach() command
                                // will cause an "Invalid argument supplied for foreach()" error
@@ -126,7 +126,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("member_reflinks_table", false, getUserId());
 } else {
        // No refbanner found!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_NO_REFBANNER_FOUND'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_NO_REFBANNER_FOUND'));
 }
 
 // Free result
index fdfbb8d45e2ff01f8ffad683d730c1a4d742e9a4..32bd0bd7ff6d437f62e82b9ef1c14f92dd0e412c 100644 (file)
@@ -42,11 +42,11 @@ if (!defined('__SECURITY')) {
        require($INC);
 } elseif (!IS_MEMBER()) {
        // User is not logged in
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load all referal levels
 $result = SQL_QUERY_ESC("SELECT r.level, r.percents
@@ -58,10 +58,10 @@ ORDER BY r.level ASC",
 // Are there some entries? (Shall be!)
 if (SQL_NUMROWS($result) > 0) {
        // List all levels
-       $OUT = "";
+       $OUT = '';
        while ($content = SQL_FETCHARRAY($result)) {
                // Init variables
-               $rows = "";
+               $rows = '';
                $counter = 0;
                $SW = 2;
 
@@ -96,7 +96,7 @@ if (SQL_NUMROWS($result) > 0) {
        LOAD_TEMPLATE("member_ref_list", false, $OUT);
 } else {
        // No entries
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_REFBACK_NO_ENTRIES'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_REFBACK_NO_ENTRIES'));
 }
 
 // Free result
index 942f1c79773fc1532b1a7d8b98a43cb0d30fa2e5..b1d357ee70ae79ede0b449c7ba3b105fdc355256 100644 (file)
@@ -40,14 +40,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("sponsor")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "sponsor");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('sponsor')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'sponsor');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Loads the name-matching template
 LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));
index 538861ba13bd71e7df16aab6729863d6a70298b9..d36e64f60cc33b4d8857c36f6723d270e8d5127d 100644 (file)
@@ -41,11 +41,11 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Init output
 $main_content = array();
@@ -60,7 +60,7 @@ ORDER BY timestamp DESC",
 // Are there mails left in pool?
 if (SQL_NUMROWS($result) > 0) {
        // Load all orders
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($data = SQL_FETCHARRAY($result)) {
                // Is the ZIP code set? If not, set dashes
                if (empty($data['zip'])) $data['zip'] =  "---";
@@ -90,7 +90,7 @@ if (SQL_NUMROWS($result) > 0) {
        $main_content['pool'] = LOAD_TEMPLATE("member_pool_table", true, $OUT);
 } else {
        // No mails in pool!
-       $main_content['pool'] = LOAD_TEMPLATE("admin_settings_saved", true, getMessage('MEMBER_NO_MAILS_IN_POOL'));
+       $main_content['pool'] = LOAD_TEMPLATE('admin_settings_saved', true, getMessage('MEMBER_NO_MAILS_IN_POOL'));
 }
 
 // Free result
@@ -106,7 +106,7 @@ ORDER BY timestamp_ordered DESC",
 
 if (SQL_NUMROWS($result) > 0) {
        // Mail orders are in pool so we can display them
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        while ($data = SQL_FETCHROW($result)) {
                // Prepare data for the template
                $content = array(
@@ -131,7 +131,7 @@ if (SQL_NUMROWS($result) > 0) {
        $main_content['stats'] = LOAD_TEMPLATE("member_stats_table", true, $OUT);
 } else {
        // No mail orders fond
-       $main_content['stats'] = LOAD_TEMPLATE("admin_settings_saved", true, getMessage('MEMBER_NO_MAILS_IN_STATS'));
+       $main_content['stats'] = LOAD_TEMPLATE('admin_settings_saved', true, getMessage('MEMBER_NO_MAILS_IN_STATS'));
 }
 
 // Free result
index f48d6a97fd17dc89ba2fd356f7b24973031a7db4..04d7af67d20a2f250023f1a3d36e5ea7b15c48f0 100644 (file)
@@ -41,21 +41,21 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 }  elseif (!IS_MEMBER()){
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("support")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "support");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('support')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'support');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 if ((!IS_FORM_SENT()) || (!REQUEST_ISSET_POST(('qsummary')))) {
        // Output form
        LOAD_TEMPLATE("member_support_form");
 } else {
        // Load mail template based on your member's decision
-       if (GET_EXT_VERSION("admins") >= "0.4.1") {
+       if (GET_EXT_VERSION('admins') >= '0.4.1') {
                $a_tpl = "admin_support-".REQUEST_POST('qsummary');
        } else {
                $msg_a = LOAD_EMAIL_TEMPLATE("admin_support-".REQUEST_POST('qsummary'), array('text' => REQUEST_POST('qdetails')), getUserId());
index bafef8493840eed1879eb0bce4540141f81fcd72..9c7de3ad57f32ec6798941faf0947c705bffdbb7 100644 (file)
@@ -42,22 +42,22 @@ if (!defined('__SECURITY')) {
        require($INC);
 } elseif (!IS_MEMBER()) {
        // Redirect
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("surfbar")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "surfbar");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('surfbar')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'surfbar');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Still allowed to book more URLs?
 if (!SURFBAR_IF_USER_BOOK_MORE_URLS()) {
        // No more URLs allowed to book!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_SURFBAR_NO_MORE_ALLOWED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_SURFBAR_NO_MORE_ALLOWED'));
 } elseif ((IS_FORM_SENT()) && (REQUEST_ISSET_POST(('limited')))) {
        // Is limitation "no" and "limit" is > 0?
-       if ((REQUEST_POST('limited') == "N") && ((REQUEST_ISSET_POST(('limit'))) && (REQUEST_POST('limit') > 0)) || (!REQUEST_ISSET_POST(('limit')))) {
+       if ((REQUEST_POST('limited') == 'N') && ((REQUEST_ISSET_POST(('limit'))) && (REQUEST_POST('limit') > 0)) || (!REQUEST_ISSET_POST(('limit')))) {
                // Set it to unlimited
                REQUEST_SET_POST('limit', 0);
        } // END - if
@@ -75,7 +75,7 @@ if (!SURFBAR_IF_USER_BOOK_MORE_URLS()) {
        } // END - if
 
        // Load message template
-       LOAD_TEMPLATE("admin_settings_saved", false, $msg);
+       LOAD_TEMPLATE('admin_settings_saved', false, $msg);
 } else {
        // Prepare some content
        $content = array(
index 0ceab6546121096c00cfa7a476c9d6e201c5f0db..3db32b4d69599151d0e39e5d32131774810ab649 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("surfbar")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "surfbar");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('surfbar')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'surfbar');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load user URLs
 $URLs = SURFBAR_GET_USER_URLS();
@@ -60,15 +60,15 @@ if ((IS_FORM_SENT()) && (REQUEST_ISSET_POST(('action'))) && (REQUEST_ISSET_POST(
                // Action performed but shall we display it?
                if (((REQUEST_POST('action') != "edit") && (REQUEST_POST('action') != "delete")) || (REQUEST_ISSET_POST(('execute')))) {
                        // Display "action done" message if action is wether 'edit' nor 'delete' or has been executed
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_SURFBAR_ACTION_DONE'));
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_SURFBAR_ACTION_DONE'));
                } // END - if
        } else {
                // Something went wrong
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_SURFBAR_ACTION_FAILED'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_SURFBAR_ACTION_FAILED'));
        }
 } elseif (count($URLs) > 0) {
        // List all URLs
-       $OUT = ""; $SW = 2;
+       $OUT = ''; $SW = 2;
        foreach ($URLs as $id => $content) {
                // "Translate"/insert data
                $content['sw'] = $SW;
@@ -97,7 +97,7 @@ if ((IS_FORM_SENT()) && (REQUEST_ISSET_POST(('action'))) && (REQUEST_ISSET_POST(
        LOAD_TEMPLATE("member_surfbar_list", false, $OUT);
 } else {
        // No URLs booked so far
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_SURFBAR_NO_URLS_FOUND'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_SURFBAR_NO_URLS_FOUND'));
 }
 
 //
index 3918d922c53660cb26137629ee799980719d8e64..c04e1abe3af96ab98f399897f9d50b5a798cbef9 100644 (file)
@@ -42,14 +42,14 @@ if (!defined('__SECURITY')) {
        require($INC);
 } elseif (!IS_MEMBER()) {
        // Not logged in
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("surfbar")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "surfbar");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('surfbar')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'surfbar');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Prepare content for output
 $content = array(
@@ -67,7 +67,7 @@ if (getConfig('surfbar_pay_model') == "DYNAMIC") {
                'surfbar_total_urls'      => SURFBAR_GET_TOTAL_URLS("ACTIVE", "0"),
                'surfbar_user_urls'       => SURFBAR_GET_TOTAL_USER_URLS(),
                'surfbar_total_online'    => SURFBAR_DETERMINE_TOTAL_ONLINE(),
-               'surfbar_total_users'     => TRANSLATE_COMMA(GET_TOTAL_DATA("CONFIRMED", "user_data", "userid", "status", true)),
+               'surfbar_total_users'     => TRANSLATE_COMMA(GET_TOTAL_DATA("CONFIRMED", "user_data", 'userid', "status", true)),
                'surfbar_min_reward'      => TRANSLATE_COMMA(SURFBAR_CALCULATE_DYNAMIC_MIN_VALUE()),
                'surfbar_max_reward'      => TRANSLATE_COMMA(SURFBAR_CALCULATE_DYNAMIC_MAX_VALUE()),
                'surfbar_min_time'        => CREATE_FANCY_TIME(SURFBAR_CALCULATE_DYNAMIC_MIN_VALUE()),
index c3a33d33f95ebf76c124ea16deff9b146336c730..b9e6347a97e56a3275d851cb55839080cf755917 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("surfbar")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "surfbar");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('surfbar')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'surfbar');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 //
 ?>
index 2a466cdbee5df30b2873a03fa309b645ad4f8dd8..1cf59982ae7a76821d536551e06ad06a2197a95b 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("theme")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "theme");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('theme')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'theme');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 if (REQUEST_ISSET_POST(('member_theme'))) {
        // Save theme to member's profile
@@ -62,7 +62,7 @@ if (REQUEST_ISSET_POST(('member_theme'))) {
        set_session('mxchange_theme', $newTheme);
 
        // Theme saved!
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_THEME_SAVED'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_THEME_SAVED'));
 }
 
 // Initialize array
@@ -102,9 +102,9 @@ closedir($handle);
 array_pk_sort($THEMES, array("theme_name"));
 
 // Generate output lines for the template
-$OUT = ""; $SW = 2;
+$OUT = ''; $SW = 2;
 foreach ($THEMES['theme_unix'] as $key => $unix) {
-       $default = "";
+       $default = '';
        if (get_session('mxchange_theme') == $unix) $default = " selected=\"selected\"";
 
        // Add row
@@ -128,7 +128,7 @@ if (empty($OUT)) {
        // No themes found???
        $OUT = "<tr>
   <td colspan=\"5\" class=\"bottom2\" height=\"80\">
-    ".LOAD_TEMPLATE("admin_settings_saved", true, getMessage('MEMBER_NO_THEMES_FOUND'))."
+    ".LOAD_TEMPLATE('admin_settings_saved', true, getMessage('MEMBER_NO_THEMES_FOUND'))."
   </td>
 </tr>\n";
 }
index 7d082789ea3f3345824252ace8e4c1c6303057b5..04d2c686e831ad94cf503dbb0156a8887cb74734 100644 (file)
@@ -41,14 +41,14 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("transfer")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "transfer");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('transfer')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'transfer');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Load data
 $result = SQL_QUERY_ESC("SELECT opt_in FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
@@ -58,11 +58,11 @@ list($opt_in) = SQL_FETCHROW($result);
 // Free memory
 SQL_FREERESULT($result);
 
-$MODE = "";
+$MODE = '';
 if (REQUEST_ISSET_GET(('mode'))) $MODE = REQUEST_GET('mode');
 
 // Check for "faker"
-if (($opt_in == "N") && ($MODE == "new")) $MODE = "";
+if (($opt_in == 'N') && ($MODE == "new")) $MODE = '';
 
 switch ($MODE)
 {
@@ -98,7 +98,7 @@ case "new": // Start new transfer
 
                // Check for nickname extension and set additional data
                $nick = false; $add = ", userid";
-               if (EXT_IS_ACTIVE("nickname")) {
+               if (EXT_IS_ACTIVE('nickname')) {
                        $add = ", nickname";
                        $nick = true;
                }
@@ -185,14 +185,14 @@ case "new": // Start new transfer
                        ADD_POINTS_REFSYSTEM("member_transfer", bigintval(REQUEST_POST('to_uid')), bigintval(REQUEST_POST('points')), false, "0", false, "direct");
 
                        // ... and add it to current user's used points
-                       SUB_POINTS("transfer", getUserId(), REQUEST_POST('points'));
+                       SUB_POINTS('transfer', getUserId(), REQUEST_POST('points'));
 
                        // First send email to recipient
-                       $msg = LOAD_EMAIL_TEMPLATE("member_transfer_recipient", "", constant('__RECIPIENT_UID'));
+                       $msg = LOAD_EMAIL_TEMPLATE("member_transfer_recipient", '', constant('__RECIPIENT_UID'));
                        SEND_EMAIL(constant('__RECIPIENT_EMAIL'), getMessage('TRANSFER_MEMBER_RECIPIENT_SUBJ').": ".$SENDER, $msg);
 
                        // Second send email to sender
-                       $msg = LOAD_EMAIL_TEMPLATE("member_transfer_sender", "", constant('__SENDER_UID'));
+                       $msg = LOAD_EMAIL_TEMPLATE("member_transfer_sender", '', constant('__SENDER_UID'));
                        SEND_EMAIL(constant('__SENDER_EMAIL'), getMessage('TRANSFER_MEMBER_SENDER_SUBJ').": ".$RECIPIENT, $msg);
 
                        // At last send admin mail(s)
@@ -200,37 +200,37 @@ case "new": // Start new transfer
                        SEND_ADMIN_NOTIFICATION($ADMIN_SUBJ, "admin_transfer_points");
 
                        // Transfer is completed
-                       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('TRANSFER_COMPLETED')."<br /><a href=\"{!URL!}/modules.php?module=login&amp;what=transfer\">{--TRANSFER_CONTINUE_OVERVIEW--}</a>");
+                       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('TRANSFER_COMPLETED')."<br /><a href=\"{!URL!}/modules.php?module=login&amp;what=transfer\">{--TRANSFER_CONTINUE_OVERVIEW--}</a>");
                } elseif (!$valid_code) {
                        // Invalid Touring code!
-                       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_note\">{--TRANSFER_INVALID_CODE--}</div>");
+                       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_note\">{--TRANSFER_INVALID_CODE--}</div>");
                        REQUEST_UNSET_POST('ok');
                } elseif (!$valid_pass) {
                        // Wrong password entered
-                       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_note\">{--TRANSFER_INVALID_PASSWORD--}</div>");
+                       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_note\">{--TRANSFER_INVALID_PASSWORD--}</div>");
                        REQUEST_UNSET_POST('ok');
                } elseif (!$valid_amount) {
                        // Too much points entered
-                       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_note\">{--TRANSFER_INVALID_POINTS--}</div>");
+                       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_note\">{--TRANSFER_INVALID_POINTS--}</div>");
                        REQUEST_UNSET_POST('ok');
                } elseif (!$valid_reason) {
                        // No transfer reason entered
-                       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_note\">{--TRANSFER_INVALID_REASON--}</div>");
+                       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_note\">{--TRANSFER_INVALID_REASON--}</div>");
                        REQUEST_UNSET_POST('ok');
                } elseif (!$valid_recipient) {
                        // No recipient selected
-                       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_note\">{--TRANSFER_INVALID_RECIPIENT--}</div>");
+                       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_note\">{--TRANSFER_INVALID_RECIPIENT--}</div>");
                        REQUEST_UNSET_POST('ok');
                } elseif (!$valid_data) {
                        // No recipient selected
-                       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_note\">{--TRANSFER_INVALID_DATA--}</div>");
+                       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_note\">{--TRANSFER_INVALID_DATA--}</div>");
                        REQUEST_UNSET_POST('ok');
                }
        }
 
        if (!IS_FORM_SENT()) {
                // Load member list
-               if (EXT_IS_ACTIVE("nickname")) {
+               if (EXT_IS_ACTIVE('nickname')) {
                        // Load userid and nickname
                        $result = SQL_QUERY_ESC("SELECT userid, nickname FROM `{!_MYSQL_PREFIX!}_user_data` WHERE `status`='CONFIRMED' AND opt_in='Y' AND userid != '%s' ORDER BY userid",
                         array(getUserId()), __FILE__, __LINE__);
@@ -259,7 +259,7 @@ case "new": // Start new transfer
                                $OUT .= "</option>\n";
                        }
                        $OUT .= "</select>\n";
-                       define('__TRANSFER_TO_DISABLED', "");
+                       define('__TRANSFER_TO_DISABLED', '');
 
                        // Free memory
                        SQL_FREERESULT($result);
@@ -290,8 +290,8 @@ case "new": // Start new transfer
                        define('__TRANSFER_REASON_VALUE', strip_tags(REQUEST_POST('reason')));
                } else {
                        // Set empty values
-                       define('__TRANSFER_POINTS_VALUE', "");
-                       define('__TRANSFER_REASON_VALUE', "");
+                       define('__TRANSFER_POINTS_VALUE', '');
+                       define('__TRANSFER_REASON_VALUE', '');
                }
 
                // Output form
@@ -325,7 +325,7 @@ case "list_out": // List only outgoing transactions
        $total = 0;
        $result = SQL_QUERY_ESC($sql, array(getUserId()), __FILE__, __LINE__);
        if (SQL_NUMROWS($result) > 0) {
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                // @TODO This should be somehow rewritten to $content = SQL_FETCHARRAY(), see switch() block above for SQL queries
                while (list($tid, $uid, $points, $reason, $stamp) = SQL_FETCHROW($result)) {
                        // Rewrite points
@@ -355,7 +355,7 @@ case "list_out": // List only outgoing transactions
                // Nothing for in or out
                $OUT = "<tr>
   <td colspan=\"5\" align=\"center\" class=\"bottom2\" height=\"70\">
-    ".LOAD_TEMPLATE("admin_settings_saved", true, $NOTHING)."
+    ".LOAD_TEMPLATE('admin_settings_saved', true, $NOTHING)."
   </td>
 </tr>";
        }
@@ -418,7 +418,7 @@ array(getUserId(), getConfig('transfer_max')), __FILE__, __LINE__);
                        __FILE__, __LINE__);
 
                // Output rows
-               $OUT = ""; $SW = 2;
+               $OUT = ''; $SW = 2;
                while ($content = SQL_FETCHARRAY($result)) {
                        // Rewrite points
                        if ($content['trans_type'] == "OUT") $content['points'] = "-".$content['points']."";
@@ -442,7 +442,7 @@ array(getUserId(), getConfig('transfer_max')), __FILE__, __LINE__);
                // Nothing for in and out
                $OUT = "<tr>
   <td colspan=\"5\" align=\"center\" class=\"bottom2\" height=\"70\">
-    ".LOAD_TEMPLATE("admin_settings_saved", true, getMessage('TRANSFER_NO_INOUT_TRANSFERS'))."
+    ".LOAD_TEMPLATE('admin_settings_saved', true, getMessage('TRANSFER_NO_INOUT_TRANSFERS'))."
   </td>
 </tr>";
        }
@@ -511,20 +511,20 @@ case "": // Overview page
                $opt_in = REQUEST_POST('opt_in');
 
                // "Settings saved..."
-               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_done\">{--SETTINGS_SAVED--}</div>");
+               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_done\">{--SETTINGS_SAVED--}</div>");
        }
 
        switch ($opt_in)
        {
-       case "Y":
-               define('__TRANSFER_ALLOW_Y', " checked=\"checked\"");
-               define('__TRANSFER_ALLOW_N', "");
+       case 'Y':
+               define('__TRANSFER_ALLOW_Y', ' chkecked="checked"');
+               define('__TRANSFER_ALLOW_N', '');
                define('__TRANSFER_NEW_LINK', "<a href=\"{!URL!}/modules.php?module=login&amp;what=transfer&amp;mode=new\">{--TRANSFER_NOW_LINK--}</a>");
                break;
 
-       case "N":
-               define('__TRANSFER_ALLOW_Y', "");
-               define('__TRANSFER_ALLOW_N', " checked=\"checked\"");
+       case 'N':
+               define('__TRANSFER_ALLOW_Y', '');
+               define('__TRANSFER_ALLOW_N', ' chkecked="checked"');
                define('__TRANSFER_NEW_LINK', getMessage('TRANSFER_PLEASE_ALLOW_OPT_IN'));
                break;
        }
index 04b715934acfbc0ec2f0284ffe6363f8203ae31a..2c4f10bef5412746b29a2cb24fc5f2d4ca9152b7 100644 (file)
@@ -41,16 +41,16 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("mailid")) && (!IS_ADMIN())) {
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('mailid')) && (!IS_ADMIN())) {
        LOAD_URL("modules.php?module=login");
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Shall we display a mail?
-if ((REQUEST_ISSET_GET(('bonusid'))) && (EXT_IS_ACTIVE("bonus"))) {
+if ((REQUEST_ISSET_GET(('bonusid'))) && (EXT_IS_ACTIVE('bonus'))) {
        // Display bonus mail by loading it's full data
        $result_data = SQL_QUERY_ESC("SELECT id, subject, timestamp, cat_id, points, text, is_notify, data_type, time, url
 FROM `{!_MYSQL_PREFIX!}_bonus`
@@ -73,7 +73,7 @@ WHERE id=%s LIMIT 1",
 
        // Get timestamp from insert
        $content['user_status'] = sprintf(getMessage('MEMBER_MAIL_BONUS_CONFIRMED_ON'),
-               MAKE_DATETIME(USER_STATS_GET_TIMESTAMP("bonusid", $content['id']), "2")
+               MAKE_DATETIME(USER_STATS_GET_TIMESTAMP('bonusid', $content['id']), "2")
        );
 
        // Display it depending on mail (data) type
@@ -106,7 +106,7 @@ WHERE s.id=%s LIMIT 1",
 
        // Get timestamp from insert
        $content['user_status'] = sprintf(getMessage('MEMBER_MAIL_NORMAL_CONFIRMED_ON'),
-               MAKE_DATETIME(USER_STATS_GET_TIMESTAMP("mailid", $content['id']), "2")
+               MAKE_DATETIME(USER_STATS_GET_TIMESTAMP('mailid', $content['id']), "2")
        );
 
        // Display it depending on mail (data) type
@@ -116,7 +116,7 @@ WHERE s.id=%s LIMIT 1",
        SQL_FREERESULT($result_data);
 }
 
-if (EXT_IS_ACTIVE("bonus")) {
+if (EXT_IS_ACTIVE('bonus')) {
        // Load bonus ID
        $result = SQL_QUERY_ESC("SELECT stats_id, bonus_id, link_type FROM `{!_MYSQL_PREFIX!}_user_links` WHERE userid=%s ORDER BY bonus_id DESC, stats_id DESC",
                array(getUserId()), __FILE__, __LINE__);
@@ -129,12 +129,12 @@ if (EXT_IS_ACTIVE("bonus")) {
 // Mails left for confirmation?
 if (SQL_NUMROWS($result) > 0) {
        // Please confirm these mails!
-       $sum = 0; $OUT = ""; $SW = 2;
+       $sum = 0; $OUT = ''; $SW = 2;
 
        // @TODO Try to rewrite this to $content = SQL_FETCHARRAY()
        while (list($id, $id2, $type) = SQL_FETCHROW($result)) {
                // Load data from stats table...
-               $cat = ""; $result_data = false;
+               $cat = ''; $result_data = false;
                switch ($type)
                {
                case "NORMAL":
@@ -145,13 +145,13 @@ ON s.pool_id=p.id
 WHERE s.id=%s
 LIMIT 1",
                                array(bigintval($id)), __FILE__, __LINE__);
-                       $type = "mailid"; $DATA = $id; $PROBLEM = getMessage('NORMAL_MAIL_PROBLEM');
+                       $type = 'mailid'; $DATA = $id; $PROBLEM = getMessage('NORMAL_MAIL_PROBLEM');
                        break;
 
                case "BONUS":
                        $result_data = SQL_QUERY_ESC("SELECT subject, timestamp, cat_id, points, 0 FROM `{!_MYSQL_PREFIX!}_bonus` WHERE id=%s LIMIT 1",
                         array(bigintval($id2)), __FILE__, __LINE__);
-                       $type = "bonusid"; $DATA = $id2; $PROBLEM = getMessage('BONUS_MAIL_PROBLEM');
+                       $type = 'bonusid'; $DATA = $id2; $PROBLEM = getMessage('BONUS_MAIL_PROBLEM');
                        break;
 
                default: // Unknown type detected!
@@ -160,7 +160,7 @@ LIMIT 1",
                }
 
                // Data found to this mail?
-               if ((SQL_NUMROWS($result_data) == 1) && (($type == "mailid") || ($type == "bonusid"))) {
+               if ((SQL_NUMROWS($result_data) == 1) && (($type == 'mailid') || ($type == 'bonusid'))) {
                        // Mail was found!
                        list($subject, $timestamp, $cat, $pay, $sender) = SQL_FETCHROW($result_data);
 
@@ -174,10 +174,10 @@ LIMIT 1",
                        }
 
                        // Prepare sender id
-                       if (($sender > 0) && ($type == "mailid")) {
+                       if (($sender > 0) && ($type == 'mailid')) {
                                // Sender id
                                $sender = bigintval($sender);
-                       } elseif ($type == "bonusid") {
+                       } elseif ($type == 'bonusid') {
                                // Is admin
                                $sender = getMessage('_ADMIN_SHORT');
                        } else {
@@ -199,7 +199,7 @@ LIMIT 1",
                        );
 
                        // Load row template
-                       if (getConfig('show_points_unconfirmed') == "Y") {
+                       if (getConfig('show_points_unconfirmed') == 'Y') {
                                $OUT .= LOAD_TEMPLATE("member_unconfirmed_row", true, $content);
                        } else {
                                $OUT .= LOAD_TEMPLATE("member_unconfirmed_row_nopoints", true, $content);
@@ -216,7 +216,7 @@ LIMIT 1",
                        );
 
                        // Display points or not?
-                       if (getConfig('show_points_unconfirmed') == "Y") {
+                       if (getConfig('show_points_unconfirmed') == 'Y') {
                                $OUT .= LOAD_TEMPLATE("member_unconfirmed_404", true, $content);
                        } else {
                                $OUT .= LOAD_TEMPLATE("member_unconfirmed_404_nopoints", true, $content);
@@ -240,14 +240,14 @@ LIMIT 1",
        define('__UNCONFIRMED_ROWS', $OUT);
 
        // Load main template
-       if (getConfig('show_points_unconfirmed') == "Y") {
+       if (getConfig('show_points_unconfirmed') == 'Y') {
                LOAD_TEMPLATE("member_unconfirmed_table");
        } else {
                LOAD_TEMPLATE("member_unconfirmed_table_nopoints");
        }
 } else {
        // No mails left to confirm... :)
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('MEMBER_NO_MAILS_TO_CONFIRM'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_NO_MAILS_TO_CONFIRM'));
 }
 
 //
index cef107664ea0b0142f244c0d1caab47706668171..84bc8e673f7e29740752a0f93b5d6fe930183f7b 100644 (file)
@@ -41,15 +41,15 @@ if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
 } elseif (!IS_MEMBER()) {
-       LOAD_URL("modules.php?module=index");
+       LOAD_URL('modules.php?module=index');
 }
 
 // Add description as navigation point
-ADD_DESCR ("member", basename(__FILE__));
+ADD_DESCR ('member', basename(__FILE__));
 
 // Export data for template
 define('_LAST_ONLINE_VALUE', MAKE_DATETIME($GLOBALS['last']['online']));
-define('_LAST_MODULE_VALUE', GET_MOD_DESCR("member", $GLOBALS['last']['module']));
+define('_LAST_MODULE_VALUE', GET_MOD_DESCR('member', $GLOBALS['last']['module']));
 
 // Load header template
 LOAD_TEMPLATE("member_welcome_header");
@@ -58,7 +58,7 @@ LOAD_TEMPLATE("member_welcome_header");
 $result = SQL_QUERY_ESC("SELECT userid FROM `{!_MYSQL_PREFIX!}_user_data` WHERE notified='Y' AND userid=%s LIMIT 1",
        array(getUserId()), __FILE__, __LINE__);
 
-if ((SQL_NUMROWS($result) == 1) && (EXT_IS_ACTIVE("profile"))) {
+if ((SQL_NUMROWS($result) == 1) && (EXT_IS_ACTIVE('profile'))) {
        // Yes, he is so let's place him his wanted buttons
        LOAD_TEMPLATE("profile-update");
 } else {
index c34be7db0db8ab41100121947b37460810f93f81..ffc0acca60a391ce252c7f9b5bcf219fc4ea9ab2 100644 (file)
@@ -42,19 +42,19 @@ if (!defined('__SECURITY')) {
        require($INC);
 } elseif (!IS_MEMBER()) {
        // User is not logged in
-       LOAD_URL("modules.php?module=index");
-} elseif ((!EXT_IS_ACTIVE("wernis")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "wernis");
+       LOAD_URL('modules.php?module=index');
+} elseif ((!EXT_IS_ACTIVE('wernis')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'wernis');
        return;
 }
 
 // Add description as navigation point
-ADD_DESCR("member", __FILE__);
+ADD_DESCR('member', __FILE__);
 
 // Check if the admin has entered the data
 if ((getConfig('wernis_api_id') == "") || (getConfig('wernis_api_md5') == "")) {
        // Something important is missing...
-       LOAD_TEMPLATE("admin_settings_saved", false, getMessage('WERNIS_MEMBER_API_DATA_MISSING'));
+       LOAD_TEMPLATE('admin_settings_saved', false, getMessage('WERNIS_MEMBER_API_DATA_MISSING'));
        return;
 } // END - if
 
@@ -90,7 +90,7 @@ if ((!REQUEST_ISSET_GET(('mode'))) || (REQUEST_GET('mode') == "choose")) {
                        array(getUserId()), __FILE__, __LINE__);
 
                // Load all rows
-               $content['rows'] = ""; $SW = 2;
+               $content['rows'] = ''; $SW = 2;
                while ($data = SQL_FETCHARRAY($result)) {
                        // Prepare data for output
                        $rowContent = array(
@@ -115,13 +115,13 @@ if ((!REQUEST_ISSET_GET(('mode'))) || (REQUEST_GET('mode') == "choose")) {
                $content['withdraw_link'] = "<em>{--WERNIS_MEMBER_WITHDRAW_DISABLED--}</em>";
 
                // Is the payout mode active?
-               if (getConfig('wernis_payout_active') == "Y") {
+               if (getConfig('wernis_payout_active') == 'Y') {
                        // Add link
                        $content['payout_link'] = "<a class=\"menu_blur\" style=\"height: 40px\" href=\"{!URL!}/modules.php?module=login&amp;what=wernis&amp;mode=payout\"><div style=\"padding-top: 10px\">{--MEMBER_WERNIS_MODE_PAYOUT--}</div></a>";
                } // END - if
 
                // Is the withdraw mode active?
-               if (getConfig('wernis_withdraw_active') == "Y") {
+               if (getConfig('wernis_withdraw_active') == 'Y') {
                        // Add link
                        $content['withdraw_link'] = "<a class=\"menu_blur\" style=\"height: 40px\" href=\"{!URL!}/modules.php?module=login&amp;what=wernis&amp;mode=withdraw\"><div style=\"padding-top: 10px\">{--MEMBER_WERNIS_MODE_WITHDRAW--}</div></a>";
                } // END - if
@@ -129,7 +129,7 @@ if ((!REQUEST_ISSET_GET(('mode'))) || (REQUEST_GET('mode') == "choose")) {
                // Mode chooser! ;-)
                REQUEST_SET_GET('mode', "choose");
        }
-} elseif ((REQUEST_GET('mode') == "payout") && (getConfig('wernis_payout_active') == "Y")) {
+} elseif ((REQUEST_GET('mode') == 'payout') && (getConfig('wernis_payout_active') == 'Y')) {
        // Get total points and check if the user can request a payout
        $points = GET_TOTAL_DATA(getUserId(), "user_points", "points") - GET_TOTAL_DATA(getUserId(), "user_data", "used_points");
 
@@ -137,12 +137,12 @@ if ((!REQUEST_ISSET_GET(('mode'))) || (REQUEST_GET('mode') == "choose")) {
        $points = $points - getConfig('points_register');
 
        // Is there a percentage or fixed fee?
-       $points = WERNIS_TAKE_FEE($points, "payout");
+       $points = WERNIS_TAKE_FEE($points, 'payout');
 
        // Is this enougth for a payout?
        if ($points < getConfig('wernis_min_payout')) {
                // No, then abort here
-               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('WERNIS_MEMBER_MIN_PAYOUT'), TRANSLATE_COMMA(getConfig('wernis_min_payout'))));
+               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('WERNIS_MEMBER_MIN_PAYOUT'), TRANSLATE_COMMA(getConfig('wernis_min_payout'))));
                return;
        } // END - if
 
@@ -158,7 +158,7 @@ if ((!REQUEST_ISSET_GET(('mode'))) || (REQUEST_GET('mode') == "choose")) {
        WERNIS_ADD_FEES_TO_ARRAY($content);
 
        // Get WDS66 id
-       $content['wds66_id'] = "";
+       $content['wds66_id'] = '';
        $result = SQL_QUERY_ESC("SELECT wernis_userid FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
                array(getUserId()), __FILE__, __LINE__);
 
@@ -170,14 +170,14 @@ if ((!REQUEST_ISSET_GET(('mode'))) || (REQUEST_GET('mode') == "choose")) {
 
        // Free result
        SQL_FREERESULT($result);
-} elseif ((REQUEST_GET('mode') == "withdraw") && (getConfig('wernis_withdraw_active') == "Y")) {
+} elseif ((REQUEST_GET('mode') == "withdraw") && (getConfig('wernis_withdraw_active') == 'Y')) {
        // Get total points for just displaying them
        $points = GET_TOTAL_DATA(getUserId(), "user_points", "points") - GET_TOTAL_DATA(getUserId(), "user_data", "used_points");
 
        // Prepare data for the template
        $content['points']     = TRANSLATE_COMMA($points);
        $content['min_points'] = TRANSLATE_COMMA(getConfig('wernis_min_withdraw'));
-       $content['wds66_id']   = "";
+       $content['wds66_id']   = '';
 
        // Add fees to array
        WERNIS_ADD_FEES_TO_ARRAY($content);
@@ -196,7 +196,7 @@ if ((!REQUEST_ISSET_GET(('mode'))) || (REQUEST_GET('mode') == "choose")) {
        SQL_FREERESULT($result);
 } else {
        // Invalid mode!
-       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('WERNIS_MEMBER_MODE_INVALID'), REQUEST_GET(('mode'))));
+       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('WERNIS_MEMBER_MODE_INVALID'), REQUEST_GET(('mode'))));
        return;
 }
 
@@ -205,26 +205,26 @@ if ((IS_FORM_SENT()) && (REQUEST_ISSET_GET(('mode')))) {
        // Is the user ID and password set?
        if (!REQUEST_ISSET_POST(('wds66_id'))) {
                // Nothing entered in WDS66 user ID
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('WERNIS_MEMBER_EMPTY_USERNAME'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('WERNIS_MEMBER_EMPTY_USERNAME'));
        } elseif (!REQUEST_ISSET_POST(('wds66_password'))) {
                // Nothing entered in WDS66 password
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('WERNIS_MEMBER_EMPTY_PASSWORD'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('WERNIS_MEMBER_EMPTY_PASSWORD'));
        } elseif (!REQUEST_ISSET_POST(('amount'))) {
                // Nothing entered in amount
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('WERNIS_MEMBER_EMPTY_AMOUNT'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('WERNIS_MEMBER_EMPTY_AMOUNT'));
        } elseif (REQUEST_POST('wds66_id') != bigintval(REQUEST_POST('wds66_id'))) {
                // Only numbers in account ID!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('WERNIS_MEMBER_INVALID_USERNAME'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('WERNIS_MEMBER_INVALID_USERNAME'));
        } elseif (REQUEST_POST('amount') != bigintval(REQUEST_POST('amount'))) {
                // Only numbers in amount!
-               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('WERNIS_MEMBER_INVALID_AMOUNT'));
+               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('WERNIS_MEMBER_INVALID_AMOUNT'));
        } else {
                // Check input data depending on the mode and execute the requested mode
                switch (REQUEST_GET('mode')) {
                        case "withdraw": // Widthdraws WDS66 -> This exchange
                                if (REQUEST_POST('amount') < getConfig('wernis_min_withdraw')) {
                                        // Not enougth entered!
-                                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('WERNIS_MEMBER_AMOUNT_SMALLER_MIN'), getConfig(('wernis_min_withdraw'))));
+                                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('WERNIS_MEMBER_AMOUNT_SMALLER_MIN'), getConfig(('wernis_min_withdraw'))));
                                } else {
                                        // All is fine here so do the withdraw
                                        $success = WERNIS_EXECUTE_WITHDRAW(REQUEST_POST('wds66_id'), md5(REQUEST_POST('wds66_password')), REQUEST_POST('amount'));
@@ -238,25 +238,25 @@ if ((IS_FORM_SENT()) && (REQUEST_ISSET_GET(('mode')))) {
                                                        array(bigintval(REQUEST_POST('wds66_id')), getUserId()), __FILE__, __LINE__);
 
                                                // All done!
-                                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('WERNIS_MEMBER_WITHDRAW_DONE'));
+                                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('WERNIS_MEMBER_WITHDRAW_DONE'));
                                                return;
                                        } elseif ((GET_WERNIS_ERROR_CODE() == "user_failed") || (GET_WERNIS_ERROR_CODE() == "own_failed") || (GET_WERNIS_ERROR_CODE() == "amount_failed")) {
                                                // Wrong login data
-                                               LOAD_TEMPLATE("admin_settings_saved", false, GET_WERNIS_ERROR_MESSAGE());
+                                               LOAD_TEMPLATE('admin_settings_saved', false, GET_WERNIS_ERROR_MESSAGE());
                                        } else {
                                                // Something went wrong
-                                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('WERNIS_MEMBER_WITHDRAW_FAILED'), GET_WERNIS_ERROR_MESSAGE()));
+                                               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('WERNIS_MEMBER_WITHDRAW_FAILED'), GET_WERNIS_ERROR_MESSAGE()));
                                        }
                                }
                                break;
 
-                       case "payout": // Payout this exchange -> WDS66
+                       case 'payout': // Payout this exchange -> WDS66
                                if (REQUEST_POST('amount') < getConfig('wernis_min_payout')) {
                                        // Not enougth entered!
-                                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('WERNIS_MEMBER_AMOUNT_SMALLER_MIN'), getConfig(('wernis_min_payout'))));
+                                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('WERNIS_MEMBER_AMOUNT_SMALLER_MIN'), getConfig(('wernis_min_payout'))));
                                } elseif (REQUEST_POST('amount') > $points) {
                                        // Not enougth points left!
-                                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('WERNIS_MEMBER_PAYOUT_POINTS_DEPLETED'), bigintval(REQUEST_POST('amount')), bigintval($points)));
+                                       LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('WERNIS_MEMBER_PAYOUT_POINTS_DEPLETED'), bigintval(REQUEST_POST('amount')), bigintval($points)));
                                } else {
                                        // All is fine here so do the withdraw
                                        $success = WERNIS_EXECUTE_PAYOUT(REQUEST_POST('wds66_id'), REQUEST_POST('amount'));
@@ -269,21 +269,21 @@ if ((IS_FORM_SENT()) && (REQUEST_ISSET_GET(('mode')))) {
                                                        array(bigintval(REQUEST_POST('wds66_id')), getUserId()), __FILE__, __LINE__);
 
                                                // All done!
-                                               LOAD_TEMPLATE("admin_settings_saved", false, getMessage('WERNIS_MEMBER_PAYOUT_DONE'));
+                                               LOAD_TEMPLATE('admin_settings_saved', false, getMessage('WERNIS_MEMBER_PAYOUT_DONE'));
                                                return;
                                        } elseif ((GET_WERNIS_ERROR_CODE() == "user_failed") || (GET_WERNIS_ERROR_CODE() == "own_failed") || (GET_WERNIS_ERROR_CODE() == "amount_failed") || (GET_WERNIS_ERROR_CODE() == "api_amount_failed")) {
                                                // Wrong login data
-                                               LOAD_TEMPLATE("admin_settings_saved", false, GET_WERNIS_ERROR_MESSAGE());
+                                               LOAD_TEMPLATE('admin_settings_saved', false, GET_WERNIS_ERROR_MESSAGE());
                                        } else {
                                                // Something went wrong
-                                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('WERNIS_MEMBER_WITHDRAW_FAILED'), GET_WERNIS_ERROR_MESSAGE()));
+                                               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('WERNIS_MEMBER_WITHDRAW_FAILED'), GET_WERNIS_ERROR_MESSAGE()));
                                        }
                                }
                                break;
 
                        default: // Invalid mode!
                                DEBUG_LOG(__FILE__, __LINE__, sprintf("Invalid mode %s detected.", REQUEST_GET('mode')));
-                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(getMessage('WERNIS_MEMBER_MODE_INVALID'), REQUEST_GET(('mode'))));
+                               LOAD_TEMPLATE('admin_settings_saved', false, sprintf(getMessage('WERNIS_MEMBER_MODE_INVALID'), REQUEST_GET(('mode'))));
                                return;
                }
        }
index 133ab4c8aedffcd4ac0289808d792cbc729d5c80..9836b0db7b5eb2380195997ee7b58d99eb5778de 100644 (file)
  ************************************************************************/
 
 // Some security stuff...
-$URL = "";
+$URL = '';
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("order")) && (!IS_ADMIN())) {
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "order");
+} elseif ((!EXT_IS_ACTIVE('order')) && (!IS_ADMIN())) {
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'order');
        return;
 } elseif (!IS_MEMBER()) {
        // Sorry, no guest access!
-       $URL = "modules.php?module=index";
+       $URL = 'modules.php?module=index';
 } elseif (!REQUEST_ISSET_GET(('order'))) {
        // You cannot call this module directly!
        $URL = "modules.php?module=login&amp;what=order";
@@ -55,7 +55,7 @@ if (!defined('__SECURITY')) {
 // When URL is empty nothing bad happend here
 if (empty($URL)) {
        // Is the auto-send mechanism active or inactive?
-       if (getConfig('autosend_active') == "Y") {
+       if (getConfig('autosend_active') == 'Y') {
                // Auto-send is active
                define('ADMIN_AUTOSEND',  getMessage('ADMIN_AUTOSEND_ACTIVE'));
                define('MEMBER_AUTOSEND', getMessage('MEMBER_AUTOSEND_ACTIVE'));
@@ -90,9 +90,9 @@ if (empty($URL)) {
                $USED = $DATA[7] * GET_PAY_POINTS($DATA[3]);
 
                // Update used points
-               $add = "";
-               if (getConfig('order_max_full') == "ORDER") $add = ", mail_orders=mail_orders+1";
-               SUB_POINTS("order", getUserId(), $USED);
+               $add = '';
+               if (getConfig('order_max_full') == 'ORDER') $add = ", mail_orders=mail_orders+1";
+               SUB_POINTS('order', getUserId(), $USED);
 
                // Prepare content
                $content = array(
index 9756679d8abdc9e5dac3737abeb1be91d2691de1..c72ae18dbf0a513265e990d6485535a13e339e2e 100644 (file)
@@ -39,7 +39,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("sponsor"))
+} elseif ((!EXT_IS_ACTIVE('sponsor'))
        addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'));
        return;
 } elseif (!IS_SPONSOR()) {
@@ -68,7 +68,7 @@ define('__SPONSOR_HEADER', LOAD_TEMPLATE("sponsor_header", true));
 define('__SPONSOR_FOOTER', LOAD_TEMPLATE("sponsor_footer", true));
 
 // "You are here" navigation
-define('__SPONSOR_YOURE_HERE', ADD_DESCR("sponsor", $GLOBALS['what'], false, false));
+define('__SPONSOR_YOURE_HERE', ADD_DESCR('sponsor', $GLOBALS['what'], false, false));
 
 // Load main sponsor template
 LOAD_TEMPLATE("sponsor_main");
index d5d7f31168a07277c76daba821d16b15ec7c3ad6..55da39e569d4f7f866692d1a4545c855260ea6f3 100644 (file)
@@ -39,8 +39,8 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("sponsor"))
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "sponsor");
+} elseif ((!EXT_IS_ACTIVE('sponsor'))
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'sponsor');
        return;
 } elseif (!IS_SPONSOR()) {
        // No sponsor!
index c0abe1d508ae320ff5d68fc91ceb3d6cdf203ae9..15ab182de00fb0b47194ceb19db646702c3f108b 100644 (file)
@@ -39,8 +39,8 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("sponsor"))
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "sponsor");
+} elseif ((!EXT_IS_ACTIVE('sponsor'))
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'sponsor');
        return;
 } elseif (!IS_SPONSOR()) {
        // No sponsor!
@@ -85,7 +85,7 @@ if (SQL_NUMROWS($result) == 1) {
                                $message = sprintf(getMessage('SPONSOR_PASSWORD_TOO_SHORT'), getConfig('pass_len'));
                        } else {
                                // Default is we don't want to change password!
-                               $PASS_AND = ""; $PASS_DATA = "";
+                               $PASS_AND = ''; $PASS_DATA = '';
 
                                // Check if we want to change password or not
                                if ((REQUEST_POST('pass1') == REQUEST_POST('pass2')) && (REQUEST_ISSET_POST(('pass1'))) && (REQUEST_POST('pass1') != REQUEST_POST('pass_old'))) {
@@ -111,10 +111,10 @@ if (SQL_NUMROWS($result) == 1) {
 
                        if (!empty($message)) {
                                // Output message
-                               $OUT = LOAD_TEMPLATE("admin_settings_saved", true, $message);
+                               $OUT = LOAD_TEMPLATE('admin_settings_saved', true, $message);
                        } else {
                                // No message generated
-                               $OUT = LOAD_TEMPLATE("admin_settings_saved", true, getMessage('SPONSOR_NO_MESSAGE_GENERATED'));
+                               $OUT = LOAD_TEMPLATE('admin_settings_saved', true, getMessage('SPONSOR_NO_MESSAGE_GENERATED'));
                        }
                } else {
                        // Check for gender selection
@@ -122,19 +122,19 @@ if (SQL_NUMROWS($result) == 1) {
                        {
                        case "M": // Male
                                define('__GENDER_M', " selected=\"selected\"");
-                               define('__GENDER_F', "");
-                               define('__GENDER_C', "");
+                               define('__GENDER_F', '');
+                               define('__GENDER_C', '');
                                break;
 
                        case "F": // Female
-                               define('__GENDER_M', "");
+                               define('__GENDER_M', '');
                                define('__GENDER_F', " selected=\"selected\"");
-                               define('__GENDER_C', "");
+                               define('__GENDER_C', '');
                                break;
 
                        case "C": // Company
-                               define('__GENDER_M', "");
-                               define('__GENDER_F', "");
+                               define('__GENDER_M', '');
+                               define('__GENDER_F', '');
                                define('__GENDER_C', " selected=\"selected\"");
                                break;
                        }
@@ -145,11 +145,11 @@ if (SQL_NUMROWS($result) == 1) {
        } else {
                // Locked or so?
                $STATUS = SPONSOR_TRANSLATE_STATUS($content['status']);
-               $OUT = LOAD_TEMPLATE("admin_settings_saved", true, sprintf(getMessage('SPONSOR_ACCOUNT_FAILED'), $STATUS));
+               $OUT = LOAD_TEMPLATE('admin_settings_saved', true, sprintf(getMessage('SPONSOR_ACCOUNT_FAILED'), $STATUS));
        }
 } else {
        // Sponsor account not found!
-       $OUT = LOAD_TEMPLATE("admin_settings_saved", true, sprintf(getMessage('SPONSOR_ACCOUNT_404'), get_session('sponsorid')));
+       $OUT = LOAD_TEMPLATE('admin_settings_saved', true, sprintf(getMessage('SPONSOR_ACCOUNT_404'), get_session('sponsorid')));
 }
 
 // Free memory
index 42b14bf0e445869c26c43a25d30657edd2461373..0ff2febb62908958f3a2c812521e4f259dab860a 100644 (file)
@@ -39,8 +39,8 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("sponsor"))
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "sponsor");
+} elseif ((!EXT_IS_ACTIVE('sponsor'))
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'sponsor');
        return;
 } elseif (!IS_SPONSOR()) {
        // No sponsor!
@@ -86,22 +86,22 @@ if (SQL_NUMROWS($result) == 1) {
 
                        if (!empty($message)) {
                                // Output message
-                               $OUT = LOAD_TEMPLATE("admin_settings_saved", true, $message);
+                               $OUT = LOAD_TEMPLATE('admin_settings_saved', true, $message);
                        } else {
                                // No message generated
-                               $OUT = LOAD_TEMPLATE("admin_settings_saved", true, getMessage('SPONSOR_NO_MESSAGE_GENERATED'));
+                               $OUT = LOAD_TEMPLATE('admin_settings_saved', true, getMessage('SPONSOR_NO_MESSAGE_GENERATED'));
                        }
                } else {
                        // Make yes/no selection
                        switch ($content['receive_warnings']) {
-                               case "Y":
-                                       define('__YES', " checked=\"checked\"");
-                                       define('__NO', "");
+                               case 'Y':
+                                       define('__YES', ' chkecked="checked"');
+                                       define('__NO', '');
                                        break;
 
-                               case "N":
-                                       define('__YES', "");
-                                       define('__NO', " checked=\"checked\"");
+                               case 'N':
+                                       define('__YES', '');
+                                       define('__NO', ' chkecked="checked"');
                                        break;
                        }
 
@@ -114,11 +114,11 @@ if (SQL_NUMROWS($result) == 1) {
        } else {
                // Locked or so?
                $STATUS = SPONSOR_TRANSLATE_STATUS($content['status']);
-               $OUT = LOAD_TEMPLATE("admin_settings_saved", true, sprintf(getMessage('SPONSOR_ACCOUNT_FAILED'), $STATUS));
+               $OUT = LOAD_TEMPLATE('admin_settings_saved', true, sprintf(getMessage('SPONSOR_ACCOUNT_FAILED'), $STATUS));
        }
 } else {
        // Sponsor account not found!
-       $OUT = LOAD_TEMPLATE("admin_settings_saved", true, sprintf(getMessage('SPONSOR_ACCOUNT_404'), get_session('sponsorid')));
+       $OUT = LOAD_TEMPLATE('admin_settings_saved', true, sprintf(getMessage('SPONSOR_ACCOUNT_404'), get_session('sponsorid')));
 }
 
 // Free memory
index aeeeec1f9e8a08ce9368a4fd0a511929aa37b23d..71af3ebb7e29b67b21cb91c2bc74ecd366da5448 100644 (file)
@@ -39,8 +39,8 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
        require($INC);
-} elseif ((!EXT_IS_ACTIVE("sponsor"))
-       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "sponsor");
+} elseif ((!EXT_IS_ACTIVE('sponsor'))
+       addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'sponsor');
        return;
 } elseif (!IS_SPONSOR()) {
        // No sponsor!
index d243864380b7c7ac61d1988e9511158d0d5a89e6..7d6f26b65fd2e50b2654bb342294fd6852a474d8 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("beg")) {
+} elseif (!EXT_IS_ACTIVE('beg')) {
        return;
 }
 
@@ -53,8 +53,8 @@ $curr = date("m", time());
 
 // Check if month is done
 if (($curr != getConfig('last_month')) && (getConfig('last_month') > 0) && (getConfig('beg_ranks') > 0) && ($GLOBALS['output_mode'] != 1)) {
-       // Extension "autopurge" is inactive or purging of inactive accounts is deactivated
-       $whereStatement1 = "";
+       // Extension 'autopurge' is inactive or purging of inactive accounts is deactivated
+       $whereStatement1 = '';
        $whereStatement2 = getConfig(('beg_ranks'));
 
        // Shall we exclude webmaster's own userid?
@@ -64,9 +64,9 @@ if (($curr != getConfig('last_month')) && (getConfig('last_month') > 0) && (getC
        } // END - if
 
        // Let's check if there are some points left we can "pay"...
-       if (EXT_IS_ACTIVE("autopurge")) {
+       if (EXT_IS_ACTIVE('autopurge')) {
                // Use last online stamp only when autopurge for inactive members is activated
-               if ((getConfig('ap_inactive_since') > 0) && (getConfig('beg_active') == "Y")) {
+               if ((getConfig('ap_inactive_since') > 0) && (getConfig('beg_active') == 'Y')) {
                        // Okay, include last online timestamp
                        $whereStatement1 .= sprintf(" AND last_online >= (UNIX_TIMESTAMP() - %s)", getConfig(('ap_inactive_since')));;
                } // END - if
index 060b0d599926199b3201589f6da644642525ee54..0dea2f2ac5987f125ff981dd60fc14b95a89c21e 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("bonus")) {
+} elseif (!EXT_IS_ACTIVE('bonus')) {
        return;
 }
 
@@ -52,12 +52,12 @@ if (($GLOBALS['output_mode'] == 1) || (!isResetModeEnabled())) return;
 $curr = date("m", time());
 
 if (($curr != getConfig('last_month')) && (getConfig('bonus_ranks') > 0) && ($GLOBALS['output_mode'] != 1)) {
-       // Extension "autopurge" is inactive or purging of inactive accounts is deactivated
+       // Extension 'autopurge' is inactive or purging of inactive accounts is deactivated
        $whereStatement1 = "WHERE `status`='CONFIRMED'";
        $whereStatement2 = getConfig(('bonus_ranks'));
 
        // Shall I keep inactive members away from here? (mostly wanted in an "active-rallye" ...)
-       if (EXT_IS_ACTIVE("autopurge")) {
+       if (EXT_IS_ACTIVE('autopurge')) {
                // Use last online stamp only when autopurge for inactive members is activated
                if (getConfig('ap_inactive_since') > 0) {
                        // Okay, include last online timestamp
@@ -67,12 +67,12 @@ if (($curr != getConfig('last_month')) && (getConfig('bonus_ranks') > 0) && ($GL
        } // END - if
 
        // Add more bonus points here
-       $add = "";
-       if (getConfig('bonus_click_yn') == "Y") $add .= " + turbo_bonus";
-       if (getConfig('bonus_login_yn') == "Y") $add .= " + login_bonus";
-       if (getConfig('bonus_order_yn') == "Y") $add .= " + bonus_order";
-       if (getConfig('bonus_stats_yn') == "Y") $add .= " + bonus_stats";
-       if (getConfig('bonus_ref_yn')   == "Y") $add .= " + bonus_ref";
+       $add = '';
+       if (getConfig('bonus_click_yn') == 'Y') $add .= " + turbo_bonus";
+       if (getConfig('bonus_login_yn') == 'Y') $add .= " + login_bonus";
+       if (getConfig('bonus_order_yn') == 'Y') $add .= " + bonus_order";
+       if (getConfig('bonus_stats_yn') == 'Y') $add .= " + bonus_stats";
+       if (getConfig('bonus_ref_yn')   == 'Y') $add .= " + bonus_ref";
 
        // Shall we add some entries?
        if (!empty($add)) {
index 519071773dc245e6a0e32eece88d88a831e0cf97..6134f519e97c77de8fb36e6336ae1287879e443e 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("newsletter")) {
+} elseif (!EXT_IS_ACTIVE('newsletter')) {
        return;
 }
 
index d53207fd61ea5d333fe4701ad46725a2fc210863..e7f52fdb313f8f8aa55af2ee3f4c0b9522912809 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("surfbar")) {
+} elseif (!EXT_IS_ACTIVE('surfbar')) {
        return;
 }
 
index 326edc5cebe82223b7de24dd11af802d0b5a9d6c..736dc1fa92dbe3dacb4c4b40df5692c79fbcc72b 100644 (file)
@@ -83,7 +83,7 @@ initFatalMessages();
 if ((!isInstalling()) && (isInstalled())) {
        // Check for write-permission for config.php and inc directory
        if (empty($GLOBALS['module'])) $GLOBALS['module'] = REQUEST_GET('module');
-       if (empty($GLOBALS['module'])) $GLOBALS['module'] = "index";
+       if (empty($GLOBALS['module'])) $GLOBALS['module'] = 'index';
 
        // CSS array
        EXT_INIT_CSS_FILES();
@@ -106,37 +106,37 @@ if ((!isInstalling()) && (isInstalled())) {
                                loadConfiguration();
 
                                // Load "databases" aka static arrays
-                               LOAD_INC_ONCE("inc/databases.php");
+                               LOAD_INC_ONCE('inc/databases.php');
 
                                // Init session
-                               LOAD_INC_ONCE("inc/session.php");
+                               LOAD_INC_ONCE('inc/session.php');
 
                                // Load versions
-                               LOAD_INC_ONCE("inc/versions.php");
+                               LOAD_INC_ONCE('inc/versions.php');
 
                                // Loading patching system is required here...
-                               LOAD_INC_ONCE("inc/patch-system.php"); // Initialize patch system
+                               LOAD_INC_ONCE('inc/patch-system.php'); // Initialize patch system
 
                                // Run daily reset
-                               LOAD_INC_ONCE("inc/check-reset.php");
+                               LOAD_INC_ONCE('inc/check-reset.php');
 
                                // Load admin include file if he is admin
                                if (IS_ADMIN()) {
                                        // Administrative functions
-                                       LOAD_INC_ONCE("inc/modules/admin/admin-inc.php");
+                                       LOAD_INC_ONCE('inc/modules/admin/admin-inc.php');
                                } // END - if
-                               //* DEBUG: */ ADD_POINTS_REFSYSTEM("test", 36, 1000);
+                               //* DEBUG: */ ADD_POINTS_REFSYSTEM('test', 36, 1000);
                                //* DEBUG: */ die();
 
                                // Get all values
                                if (($GLOBALS['output_mode'] != 1) && ($GLOBALS['output_mode'] != -1)) {
-                                       if (empty($GLOBALS['module']))  $GLOBALS['module'] = "empty";
+                                       if (empty($GLOBALS['module']))  $GLOBALS['module'] = 'empty';
                                        if (empty($GLOBALS['what']))    $GLOBALS['what']   = GET_WHAT($GLOBALS['module']);
                                        if (empty($GLOBALS['action']))  $GLOBALS['action'] = GET_ACTION($GLOBALS['module'], $GLOBALS['what']);
                                } else {
                                        // Set action/what to empty
-                                       $GLOBALS['action'] = "";
-                                       $GLOBALS['what']   = "";
+                                       $GLOBALS['action'] = '';
+                                       $GLOBALS['what']   = '';
                                }
 
                                // Run the init filter chain
@@ -145,33 +145,33 @@ if ((!isInstalling()) && (isInstalled())) {
                                // Set default 'what' value
                                //* DEBUG: */ OUTPUT_HTML("-".$GLOBALS['module']."/".$GLOBALS['what']."-<br />");
                                if ((empty($GLOBALS['what'])) && (empty($GLOBALS['action'])) && ($GLOBALS['output_mode'] != 1) && ($GLOBALS['output_mode'] != -1)) {
-                                       if ($GLOBALS['module'] == "admin") {
+                                       if ($GLOBALS['module'] == 'admin') {
                                                // Set 'action' value to 'login' in admin menu
                                                $GLOBALS['action'] = GET_ACTION($GLOBALS['module'], $GLOBALS['what']);
-                                       } elseif (($GLOBALS['module'] == "index") || ($GLOBALS['module'] == "login")) {
+                                       } elseif (($GLOBALS['module'] == 'index') || ($GLOBALS['module'] == 'login')) {
                                                // Set 'what' value to 'welcome' in guest and member menu
-                                               $GLOBALS['what'] = "welcome";
-                                               if (getConfig('index_home') != "") $GLOBALS['what'] = getConfig('index_home');
+                                               $GLOBALS['what'] = 'welcome';
+                                               if (getConfig('index_home') != '') $GLOBALS['what'] = getConfig('index_home');
                                        } else {
                                                // Anything else like begging link
-                                               $GLOBALS['what'] = "";
+                                               $GLOBALS['what'] = '';
                                        }
                                } // END - if
 
                                // Update sending pool
-                               if (($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != "-1")) LOAD_INC_ONCE("inc/pool-update.php"); // Sends out mails in configureable steps
+                               if (($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != '-1')) LOAD_INC_ONCE('inc/pool-update.php'); // Sends out mails in configureable steps
 
                                // Load all active extension including language files when not upgrading.
                                // Check module for testing and count one click
-                               if (checkModulePermissions($GLOBALS['module']) == "done") countModuleHit($GLOBALS['module']);
+                               if (checkModulePermissions($GLOBALS['module']) == 'done') countModuleHit($GLOBALS['module']);
 
                                // Shall we activate the exchange?
                                if (getConfig('activate_xchange') > 0) activateExchange();
 
                                // Is the extension sql_patches installed and at least 0.3.6?
-                               if (GET_EXT_VERSION("sql_patches") >= "0.3.6") {
+                               if (GET_EXT_VERSION('sql_patches') >= '0.3.6') {
                                        // Generate random number
-                                       define('RAND_NUMBER', generateRandomCodde(10, mt_rand(10000,32766), getUserId(), ""));
+                                       define('RAND_NUMBER', generateRandomCodde(10, mt_rand(10000,32766), getUserId(), ''));
                                } else {
                                        // Generate weak (!!!) code
                                        define('RAND_NUMBER', mt_rand(1000000, 9999999));
@@ -194,33 +194,33 @@ if ((!isInstalling()) && (isInstalled())) {
        ///////////////////////////////////////////////////
 
        // Set other missing variables
-       if (!isset($GLOBALS['output_mode'])) $GLOBALS['output_mode'] = "0";
+       if (!isset($GLOBALS['output_mode'])) $GLOBALS['output_mode'] = '0';
 
        // Include databases.php
-       LOAD_INC_ONCE("inc/databases.php");
+       LOAD_INC_ONCE('inc/databases.php');
 
        // Init session
-       LOAD_INC_ONCE("inc/session.php");
+       LOAD_INC_ONCE('inc/session.php');
 
        // Load versions
-       LOAD_INC_ONCE("inc/versions.php");
+       LOAD_INC_ONCE('inc/versions.php');
 
        // Check if we are in installation routine
-       if ((!isInstalling()) && ($GLOBALS['output_mode'] != "1") && ($GLOBALS['output_mode'] != -1)) {
+       if ((!isInstalling()) && ($GLOBALS['output_mode'] != '1') && ($GLOBALS['output_mode'] != -1)) {
                // Redirect to the installation system
-               LOAD_URL("install.php");
+               LOAD_URL('install.php');
        } // END - if
 
        // Double-check installation mode
        if ((!isInstalled()) || (!isAdminRegistered())) {
                // Check for file permissions
-               if (!IS_INC_WRITEABLE("config")) {
+               if (!IS_INC_WRITEABLE('config')) {
                        addFatalMessage(__FILE__, __LINE__, getMessage('CONFIG_IS_WRITE_PROTECTED'));
                } // END - if
-               if (!IS_INC_WRITEABLE("dummy")) {
+               if (!IS_INC_WRITEABLE('dummy')) {
                        addFatalMessage(__FILE__, __LINE__, getMessage('DUMMY_IS_WRITE_PROTECTED'));
                } // END - if
-               if (!IS_INC_WRITEABLE(".secret/dummy")) {
+               if (!IS_INC_WRITEABLE('.secret/dummy')) {
                        addFatalMessage(__FILE__, __LINE__, getMessage('SECRET_IS_WRITE_PROTECTED'));
                } // END - if
        } // END - if
@@ -229,14 +229,14 @@ if ((!isInstalling()) && (isInstalled())) {
        runFilterChain('init');
 
        // Load extension 'sql_patches'
-       LOAD_EXTENSION("sql_patches");
+       LOAD_EXTENSION('sql_patches');
 }
 
-if ((getTotalFatalErrors() > 0) && (isInstalled()) && (!isInstalling()) && ($GLOBALS['output_mode'] != "1")) {
+if ((getTotalFatalErrors() > 0) && (isInstalled()) && (!isInstalling()) && ($GLOBALS['output_mode'] != '1')) {
        // One or more fatal error(s) occur during connect...
-       LOAD_INC_ONCE("inc/header.php");
-       LOAD_INC_ONCE("inc/fatal_errors.php");
-       LOAD_INC_ONCE("inc/footer.php");
+       LOAD_INC_ONCE('inc/header.php');
+       LOAD_INC_ONCE('inc/fatal_errors.php');
+       LOAD_INC_ONCE('inc/footer.php');
 } // END - if
 
 //
index e9e263e34db0c1a5bdc751354216285af2cea676..efe2ced2495208908cfb0f1b7ef72ac748cf1f0b 100644 (file)
@@ -45,19 +45,19 @@ if (!defined('__SECURITY')) {
 // Returns the title for given module
 function ADD_MODULE_TITLE ($mod) {
        // Init variables
-       $name = "";
+       $name = '';
        $result = false;
 
        // Is the script installed?
        if (isInstalled()) {
                // Check if cache is valid
-               if ((GET_EXT_VERSION("cache") >= "0.1.2") && (isset($GLOBALS['cache_array']['modules']['module'])) && (in_array($mod, $GLOBALS['cache_array']['modules']['module']))) {
+               if ((GET_EXT_VERSION('cache') >= '0.1.2') && (isset($GLOBALS['cache_array']['modules']['module'])) && (in_array($mod, $GLOBALS['cache_array']['modules']['module']))) {
                        // Load from cache
                        $name = $GLOBALS['cache_array']['modules']['title'][$mod];
 
                        // Update cache hits
                        incrementConfigEntry('cache_hits');
-               } elseif (!EXT_IS_ACTIVE("cache")) {
+               } elseif (!EXT_IS_ACTIVE('cache')) {
                        // Load from database
                        $result = SQL_QUERY_ESC("SELECT title FROM `{!_MYSQL_PREFIX!}_mod_reg` WHERE `module`='%s' LIMIT 1",
                                array($mod), __FUNCTION__, __LINE__);
@@ -86,11 +86,11 @@ function ADD_MODULE_TITLE ($mod) {
 // Check validity of a given module name (no file extension)
 function checkModulePermissions ($mod) {
        // Filter module name (names with low chars and underlines are fine!)
-       $mod = preg_replace("/[^a-z_]/", "", $mod);
+       $mod = preg_replace("/[^a-z_]/", '', $mod);
 
        // Check for prefix is a extension...
        $modSplit = explode("_", $mod);
-       $extension = ""; $mod_chk = $mod;
+       $extension = ''; $mod_chk = $mod;
        //* DEBUG: */ echo __LINE__."*".count($modSplit)."*/".$mod."*<br />";
        if (count($modSplit) == 2) {
                // Okay, there is a seperator (_) in the name so is the first part a module?
@@ -118,7 +118,7 @@ function checkModulePermissions ($mod) {
        $found  = false;
 
        // Check if cache is latest version
-       if (GET_EXT_VERSION("cache") >= "0.1.2") {
+       if (GET_EXT_VERSION('cache') >= '0.1.2') {
                // Is the cache there?
                if (!isset($GLOBALS['cache_array']['modules'])) {
                        // This should normally not happen...
@@ -140,7 +140,7 @@ function checkModulePermissions ($mod) {
                        // No, then we have to update it!
                        $ret = "cache_miss";
                }
-       } elseif (!EXT_IS_ACTIVE("cache")) {
+       } elseif (!EXT_IS_ACTIVE('cache')) {
                // Check for module in database
                $result = SQL_QUERY_ESC("SELECT locked, hidden, admin_only, mem_only FROM `{!_MYSQL_PREFIX!}_mod_reg` WHERE `module`='%s' LIMIT 1",
                        array($mod_chk), __FUNCTION__, __LINE__);
@@ -157,16 +157,16 @@ function checkModulePermissions ($mod) {
                // Check returned values against current access permissions
                //
                //  Admin access            ----- Guest access -----           --- Guest   or   member? ---
-               if ((IS_ADMIN()) || (($locked == "N") && ($admin == "N") && (($mem == "N") || (IS_MEMBER())))) {
+               if ((IS_ADMIN()) || (($locked == 'N') && ($admin == 'N') && (($mem == 'N') || (IS_MEMBER())))) {
                        // If you are admin you are welcome for everything!
                        $ret = "done";
-               } elseif ($locked == "Y") {
+               } elseif ($locked == 'Y') {
                        // Module is locked
                        $ret = "locked";
-               } elseif (($mem == "Y") && (!IS_MEMBER())) {
+               } elseif (($mem == 'Y') && (!IS_MEMBER())) {
                        // You have to login first!
                        $ret = "mem_only";
-               } elseif (($admin == "Y") && (!IS_ADMIN())) {
+               } elseif (($admin == 'Y') && (!IS_ADMIN())) {
                        // Only the Admin is allowed to enter this module!
                        $ret = "admin_only";
                } else {
@@ -185,7 +185,7 @@ function checkModulePermissions ($mod) {
                //              ----- Legacy module -----                                               ---- Module in base folder  ----                       --- Module with extension's name ---
                if ((FILE_READABLE(sprintf("%sinc/modules/%s.php", constant('PATH'), $mod))) || (FILE_READABLE(sprintf("%s%s.php", constant('PATH'), $mod))) || (FILE_READABLE(sprintf("%s%s/%s.php", constant('PATH'), $extension, $mod)))) {
                        // Data is missing so we add it
-                       if (GET_EXT_VERSION("sql_patches") >= "0.3.6") {
+                       if (GET_EXT_VERSION('sql_patches') >= '0.3.6') {
                                // Since 0.3.6 we have a has_menu column, this took me a half hour
                                // to find a loop here... *sigh*
                                SQL_QUERY_ESC("INSERT INTO `{!_MYSQL_PREFIX!}_mod_reg`
@@ -235,9 +235,9 @@ function ADD_DESCR ($ACC_LVL, $FQFN, $return = false, $output = true) {
        $file = basename($FQFN);
 
        // Init variables
-       $LINK_ADD = "";
-       $OUT = "";
-       $AND = "";
+       $LINK_ADD = '';
+       $OUT = '';
+       $AND = '';
 
        // First we have to do some analysis...
        if (substr($file, 0, 7) == "action-") {
@@ -245,13 +245,13 @@ function ADD_DESCR ($ACC_LVL, $FQFN, $return = false, $output = true) {
                $type = "action";
                $search = substr($file, 7);
                switch ($ACC_LVL) {
-               case "admin":
-                       $modCheck = "admin";
+               case 'admin':
+                       $modCheck = 'admin';
                        break;
 
-               case "sponsor":
-               case "guest":
-               case "member":
+               case 'sponsor':
+               case 'guest':
+               case 'member':
                        $modCheck = $GLOBALS['module'];
                        break;
                }
@@ -260,14 +260,14 @@ function ADD_DESCR ($ACC_LVL, $FQFN, $return = false, $output = true) {
                // This is an admin what file!
                $type = "what";
                $search = substr($file, 5);
-               $AND = "";
+               $AND = '';
                switch ($ACC_LVL) {
-               case "admin":
-                       $modCheck = "admin";
+               case 'admin':
+                       $modCheck = 'admin';
                        break;
 
-               case "guest":
-               case "member":
+               case 'guest':
+               case 'member':
                        $modCheck = $GLOBALS['module'];
                        if (!IS_ADMIN()) {
                                $AND = " AND `visible`='Y' AND `locked`='N'";
@@ -276,18 +276,18 @@ function ADD_DESCR ($ACC_LVL, $FQFN, $return = false, $output = true) {
                }
                $dummy = substr($search, 0, -4);
                $AND .= " AND `action`='".GET_ACTION($ACC_LVL, $dummy)."'";
-       } elseif (($ACC_LVL == "sponsor") || ($ACC_LVL == "engine")) {
+       } elseif (($ACC_LVL == 'sponsor') || ($ACC_LVL == "engine")) {
                // Sponsor / engine menu
                $type     = "what";
                $search   = $file;
                $modCheck = $GLOBALS['module'];
-               $AND      = "";
+               $AND      = '';
        } else {
                // Other
                $type     = "menu";
                $search   = $file;
                $modCheck = $GLOBALS['module'];
-               $AND      = "";
+               $AND      = '';
        }
 
        // Begin the navigation line
@@ -296,7 +296,7 @@ function ADD_DESCR ($ACC_LVL, $FQFN, $return = false, $output = true) {
                $prefix = "<div class=\"you_are_here\">{--YOU_ARE_HERE--}&nbsp;<strong><a class=\"you_are_here\" href=\"{!URL!}/modules.php?module=".$GLOBALS['module'].$LINK_ADD."\">Home</a></strong>";
        } else {
                if (!$return) $GLOBALS['nav_depth']++;
-               $prefix = "";
+               $prefix = '';
        }
 
        $prefix .= "&nbsp;-&gt;&nbsp;";
@@ -320,7 +320,7 @@ function ADD_DESCR ($ACC_LVL, $FQFN, $return = false, $output = true) {
                if ($return === true) {
                        // Return title
                        return $ret;
-               } elseif (((GET_EXT_VERSION("sql_patches") >= "0.2.3") && (getConfig('youre_here') == "Y")) || ((IS_ADMIN()) && ($modCheck == "admin"))) {
+               } elseif (((GET_EXT_VERSION('sql_patches') >= '0.2.3') && (getConfig('youre_here') == 'Y')) || ((IS_ADMIN()) && ($modCheck == 'admin'))) {
                        // Output HTML code
                        $OUT = $prefix."<strong><a class=\"you_are_here\" href=\"{!URL!}/modules.php?module=".$modCheck."&amp;".$type."=".$search.$LINK_ADD."\">".$ret."</a></strong>\n";
 
@@ -356,9 +356,9 @@ function ADD_DESCR ($ACC_LVL, $FQFN, $return = false, $output = true) {
 function ADD_MENU ($MODE, $act, $wht) {
        // Init some variables
        $main_cnt = 0;
-       $AND = "";
-       $main_action = "";
-       $sub_what = "";
+       $AND = '';
+       $main_action = '';
+       $sub_what = '';
 
        // is the menu action valid?
        if (!VALIDATE_MENU_ACTION($MODE, $act, $wht, true)) {
@@ -404,7 +404,7 @@ function ADD_MENU ($MODE, $act, $wht) {
                                        $content = merge_array($content, $content2);
 
                                        // Init content
-                                       $OUT = "";
+                                       $OUT = '';
 
                                        // Full file name for checking menu
                                        //* DEBUG: */ echo __LINE__.":!!!!".$content['sub_what']."!!!<br />\n";
@@ -455,13 +455,13 @@ function ADD_MENU ($MODE, $act, $wht) {
                                $INC_BLOCK = sprintf("inc/modules/%s/action-%s.php", $MODE, $content['action']);
                                if (FILE_READABLE($INC_BLOCK)) {
                                        // Load include file
-                                       if ((!EXT_IS_ACTIVE($content['action'])) || ($content['action'] == "online")) OUTPUT_HTML("<tr>
+                                       if ((!EXT_IS_ACTIVE($content['action'])) || ($content['action'] == 'online')) OUTPUT_HTML("<tr>
 
   <td class=\"".$MODE."_menu_whats\">");
                                        //* DEBUG: */ echo __LINE__."/".$main_cnt."/".$content['action']."/".$content['sub_what'].":".$GLOBALS['what']."*<br />\n";
                                        LOAD_INC($INC_BLOCK);
                                        //* DEBUG: */ echo __LINE__."/".$main_cnt."/".$content['action']."/".$content['sub_what'].":".$GLOBALS['what']."*<br />\n";
-                                       if ((!EXT_IS_ACTIVE($content['action'])) || ($content['action'] == "online")) OUTPUT_HTML("  </td>
+                                       if ((!EXT_IS_ACTIVE($content['action'])) || ($content['action'] == 'online')) OUTPUT_HTML("  </td>
 </tr>");
                                }
                                //* DEBUG: */ echo __LINE__."/".$main_cnt."/".$content['action']."/".$content['sub_what'].":".$GLOBALS['what']."*<br />\n";
@@ -485,7 +485,7 @@ function ADD_MENU ($MODE, $act, $wht) {
 // This patched function will reduce many SELECT queries for the specified or current admin login
 function IS_ADMIN ($admin="") {
        // Init variables
-       $ret = false; $passCookie = ""; $valPass = "";
+       $ret = false; $passCookie = ''; $valPass = '';
        //* DEBUG: */ echo __LINE__."ADMIN:".$admin."<br />";
 
        // If admin login is not given take current from cookies...
@@ -509,13 +509,13 @@ function IS_ADMIN ($admin="") {
 
                // Count cache hits
                incrementConfigEntry('cache_hits');
-       } elseif ((!empty($admin)) && ((!EXT_IS_ACTIVE("cache"))) || (!isset($GLOBALS['cache_array']['admins']['password'][$admin]))) {
+       } elseif ((!empty($admin)) && ((!EXT_IS_ACTIVE('cache'))) || (!isset($GLOBALS['cache_array']['admins']['password'][$admin]))) {
                // Search for admin
                $result = SQL_QUERY_ESC("SELECT HIGH_PRIORITY password FROM `{!_MYSQL_PREFIX!}_admins` WHERE login='%s' LIMIT 1",
                        array($admin), __FUNCTION__, __LINE__);
 
                // Is he admin?
-               $passDB = "";
+               $passDB = '';
                if (SQL_NUMROWS($result) == 1) {
                        // Admin login was found so let's load password from DB
                        list($passDB) = SQL_FETCHROW($result);
@@ -534,7 +534,7 @@ function IS_ADMIN ($admin="") {
        if (!empty($valPass)) {
                // Check if password is valid
                //* DEBUG: */ print __FUNCTION__."*".$valPass."/".$passCookie."*<br />\n";
-               $ret = (($valPass == $passCookie) || ((strlen($valPass) == 32) && ($valPass == md5($passCookie))) || (($valPass == "*FAILED*") && (!EXT_IS_ACTIVE("cache"))));
+               $ret = (($valPass == $passCookie) || ((strlen($valPass) == 32) && ($valPass == md5($passCookie))) || (($valPass == "*FAILED*") && (!EXT_IS_ACTIVE('cache'))));
        }
 
        // Return result of comparision
@@ -544,17 +544,17 @@ function IS_ADMIN ($admin="") {
 
 // Generates a list of "max receiveable emails per day"
 function ADD_MAX_RECEIVE_LIST ($MODE, $default = "", $return = false) {
-       $OUT = "";
+       $OUT = '';
        $result = false;
 
        switch ($MODE) {
-               case "guest":
+               case 'guest':
                        // Guests (in the registration form) are not allowed to select 0 mails per day.
                        $result = SQL_QUERY("SELECT value, comment FROM `{!_MYSQL_PREFIX!}_max_receive` WHERE value > 0 ORDER BY value",
                                __FUNCTION__, __LINE__);
                        break;
 
-               case "member":
+               case 'member':
                        // Members are allowed to set to zero mails per day (we will change this soon!)
                        $result = SQL_QUERY("SELECT value, comment FROM `{!_MYSQL_PREFIX!}_max_receive` ORDER BY value",
                                __FUNCTION__, __LINE__);
@@ -567,7 +567,7 @@ function ADD_MAX_RECEIVE_LIST ($MODE, $default = "", $return = false) {
 
        // Some entries are found?
        if (SQL_NUMROWS($result) > 0) {
-               $OUT = "";
+               $OUT = '';
                while ($content = SQL_FETCHARRAY($result)) {
                        $OUT .= "      <option value=\"".$content['value']."\"";
                        if (REQUEST_POST('max_mails') == $content['value']) $OUT .= " selected=\"selected\"";
@@ -693,11 +693,11 @@ function VALIDATE_MENU_ACTION ($MODE, $act, $wht, $UPDATE=false) {
        $ret = false;
 
        // Look in all menus or only unlocked
-       $add = "";
-       if ((!IS_ADMIN()) && ($MODE != "admin")) $add = " AND `locked`='N'";
+       $add = '';
+       if ((!IS_ADMIN()) && ($MODE != 'admin')) $add = " AND `locked`='N'";
 
        //* DEBUG: */ echo __LINE__.":".$MODE."/".$act."/".$wht."*<br />\n";
-       if (($MODE != "admin") && ($UPDATE === true)) {
+       if (($MODE != 'admin') && ($UPDATE === true)) {
                // Update guest or member menu
                $sql = SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_%s_menu` SET counter=counter+1 WHERE `action`='%s' AND `what`='%s'".$add." LIMIT 1",
                        array($MODE, $act, $wht), __FUNCTION__, __LINE__, false);
@@ -787,22 +787,22 @@ function SEND_MODE_MAILS($mod, $modes) {
                                $DATA[0] = TRANSLATE_GENDER($DATA[0]);
 
                                // Clear/init the content variable
-                               $content = "";
-                               $DATA['info'] = "";
+                               $content = '';
+                               $DATA['info'] = '';
 
                                switch ($mod)
                                {
-                               case "mydata":
+                               case 'mydata':
                                        foreach ($modes as $mode) {
                                                switch ($mode)
                                                {
-                                               case "normal": break; // Do not add any special lines
+                                               case 'normal': break; // Do not add any special lines
 
-                                               case "email": // Email was changed!
+                                               case 'email': // Email was changed!
                                                        $content = MEMBER_CHANGED_EMAIL.": ".REQUEST_POST('old_addy')."\n";
                                                        break;
 
-                                               case "pass": // Password was changed
+                                               case 'pass': // Password was changed
                                                        $content = MEMBER_CHANGED_PASS."\n";
                                                        break;
 
@@ -813,7 +813,7 @@ function SEND_MODE_MAILS($mod, $modes) {
                                                } // END - switch
                                        } // END - if
 
-                                       if (EXT_IS_ACTIVE("country")) {
+                                       if (EXT_IS_ACTIVE('country')) {
                                                // Replace code with description
                                                $DATA[4] = COUNTRY_GENERATE_INFO(REQUEST_POST('country_code'));
                                        } // END - if
@@ -821,14 +821,14 @@ function SEND_MODE_MAILS($mod, $modes) {
                                        // Load template
                                        $msg = LOAD_EMAIL_TEMPLATE("member_mydata_notify", $content, getUserId());
 
-                                       if (getConfig('admin_notify') == "Y") {
+                                       if (getConfig('admin_notify') == 'Y') {
                                                // The admin needs to be notified about a profile change
                                                $msg_admin = "admin_mydata_notify";
                                                $sub_adm   = ADMIN_CHANGED_DATA;
                                        } else {
                                                // No mail to admin
-                                               $msg_admin = "";
-                                               $sub_adm   = "";
+                                               $msg_admin = '';
+                                               $sub_adm   = '';
                                        }
 
                                        // Set subject lines
@@ -867,7 +867,7 @@ function SEND_MODE_MAILS($mod, $modes) {
                if ((!empty($sub_adm)) && (!empty($msg_admin))) {
                        // Send admin mail
                        SEND_ADMIN_NOTIFICATION($sub_adm, $msg_admin, $content, getUserId());
-               } elseif (getConfig('admin_notify') == "Y") {
+               } elseif (getConfig('admin_notify') == 'Y') {
                        // Cannot send mails to admin!
                        $content = getMessage('CANNOT_SEND_ADMIN_MAILS');
                } else {
@@ -877,7 +877,7 @@ function SEND_MODE_MAILS($mod, $modes) {
        } // END - if
 
        // Load template
-       LOAD_TEMPLATE("admin_settings_saved", false, $content);
+       LOAD_TEMPLATE('admin_settings_saved', false, $content);
 }
 
 // Update module counter
@@ -892,15 +892,15 @@ function countModuleHit($mod) {
 // Get action value from mode (admin/guest/member) and what-value
 function GET_ACTION ($MODE, &$wht) {
        // Init status
-       $ret = "";
+       $ret = '';
 
        //* DEBUG: */ echo __LINE__."=".$MODE."/".$wht."/".$GLOBALS['action']."=<br />";
-       if ((empty($wht)) && ($MODE != "admin")) {
+       if ((empty($wht)) && ($MODE != 'admin')) {
                $wht = "welcome";
                if (getConfig('index_home') != "") $wht = getConfig('index_home');
        } // END - if
 
-       if ($MODE == "admin") {
+       if ($MODE == 'admin') {
                // Action value for admin area
                if (REQUEST_ISSET_GET('action')) {
                        // Use from request!
@@ -922,8 +922,8 @@ function GET_ACTION ($MODE, &$wht) {
        if (MODULE_HAS_MENU($MODE)) {
                // Rewriting modules to menu
                switch ($MODE) {
-                       case "index": $MODE = "guest";  break;
-                       case "login": $MODE = "member"; break;
+                       case 'index': $MODE = 'guest';  break;
+                       case "login": $MODE = 'member'; break;
                } // END - switch
 
                // Guest and member menu is "main" as the default
@@ -939,7 +939,7 @@ function GET_ACTION ($MODE, &$wht) {
 
                // Free memory
                SQL_FREERESULT($result);
-       } elseif ((GET_EXT_VERSION("sql_patches") == "") && ($MODE != "admin")) {
+       } elseif ((GET_EXT_VERSION('sql_patches') == "") && ($MODE != 'admin')) {
                // No sql_patches installed, but maybe we need to register an admin?
                if (isAdminRegistered()) {
                        // Redirect
@@ -1032,7 +1032,7 @@ function REMOVE_RECEIVER (&$receivers, $key, $uid, $pool_id, $stats_id="", $bonu
                if ($stats_id > 0) {
                        // Only when we got a real stats ID continue searching for the entry
                        $type = "NORMAL"; $rowName = "stats_id";
-                       if ($bonus) { $type = "BONUS"; $rowName = "bonus_id"; }
+                       if ($bonus) { $type = "BONUS"; $rowName = 'bonus_id'; }
 
                        // Try to look the entry up
                        $result = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_user_links` WHERE %s='%s' AND userid=%s AND link_type='%s' LIMIT 1",
@@ -1059,7 +1059,7 @@ function REMOVE_RECEIVER (&$receivers, $key, $uid, $pool_id, $stats_id="", $bonu
 }
 
 // Calculate sum (default) or count records of given criteria
-function GET_TOTAL_DATA ($search, $tableName, $lookFor = "id", $whereStatement = "userid", $countRows = false, $add = "") {
+function GET_TOTAL_DATA ($search, $tableName, $lookFor = "id", $whereStatement = 'userid', $countRows = false, $add = "") {
        $ret = 0;
        //* DEBUG: */ echo $search."/".$tableName."/".$lookFor."/".$whereStatement."/".$add."<br />\n";
        if ((empty($search)) && ($search != "0")) {
@@ -1073,7 +1073,7 @@ function GET_TOTAL_DATA ($search, $tableName, $lookFor = "id", $whereStatement =
                        $result = SQL_QUERY_ESC("SELECT SUM(`%s`) FROM `{!_MYSQL_PREFIX!}_%s`".$add,
                                array($lookFor, $tableName), __FUNCTION__, __LINE__);
                }
-       } elseif (($countRows === true) || ($lookFor == "userid")) {
+       } elseif (($countRows === true) || ($lookFor == 'userid')) {
                // Count rows
                //* DEBUG: */ echo "COUNT!<br />\n";
                $result = SQL_QUERY_ESC("SELECT COUNT(`%s`) FROM `{!_MYSQL_PREFIX!}_%s` WHERE `%s`='%s'".$add,
@@ -1092,7 +1092,7 @@ function GET_TOTAL_DATA ($search, $tableName, $lookFor = "id", $whereStatement =
        SQL_FREERESULT($result);
 
        // Fix empty values
-       if ((empty($ret)) && ($lookFor != "counter") && ($lookFor != "id") && ($lookFor != "userid")) {
+       if ((empty($ret)) && ($lookFor != "counter") && ($lookFor != "id") && ($lookFor != 'userid')) {
                // Float number
                $ret = "0.00000";
        } elseif ("".$ret."" == "") {
@@ -1109,7 +1109,7 @@ function GET_REF_LEVEL_PERCENTS ($level) {
        $per = 0;
 
        // Do we have cache?
-       if ((isset($GLOBALS['cache_array']['ref_depths']['level'])) && (EXT_IS_ACTIVE("cache"))) {
+       if ((isset($GLOBALS['cache_array']['ref_depths']['level'])) && (EXT_IS_ACTIVE('cache'))) {
                // First look for level
                $key = array_search($level, $GLOBALS['cache_array']['ref_depths']['level']);
                if ($key !== false) {
@@ -1119,7 +1119,7 @@ function GET_REF_LEVEL_PERCENTS ($level) {
                        // Count cache hit
                        incrementConfigEntry('cache_hits');
                }
-       } elseif (!EXT_IS_ACTIVE("cache")) {
+       } elseif (!EXT_IS_ACTIVE('cache')) {
                // Get referal data
                $result_lvl = SQL_QUERY_ESC("SELECT percents FROM `{!_MYSQL_PREFIX!}_refdepths` WHERE level='%s' LIMIT 1",
                        array(bigintval($level)), __FUNCTION__, __LINE__);
@@ -1165,9 +1165,9 @@ function ADD_POINTS_REFSYSTEM ($subject, $uid, $points, $send_notify=false, $rid
        } // END - if
 
        // Add booking record if extension is installed
-       if (EXT_IS_ACTIVE("booking")) {
+       if (EXT_IS_ACTIVE('booking')) {
                // Add record
-               ADD_BOOKING_RECORD($subject, $uid, $points, "add");
+               ADD_BOOKING_RECORD($subject, $uid, $points, 'add');
        } // END - if
 
        // Count up referal depth
@@ -1181,7 +1181,7 @@ function ADD_POINTS_REFSYSTEM ($subject, $uid, $points, $send_notify=false, $rid
                //* DEBUG: */ print __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>): Referal level increased. DEPTH={$GLOBALS['ref_level']}<br />\n";
        }
 
-       // Default is "normal" points
+       // Default is 'normal' points
        $data = "points";
 
        // Which points, locked or normal?
@@ -1208,7 +1208,7 @@ function ADD_POINTS_REFSYSTEM ($subject, $uid, $points, $send_notify=false, $rid
                        $ref_points = $points * $per / 100;
 
                        // Pay refback here if level > 0 and in ref-mode
-                       if ((EXT_IS_ACTIVE("refback")) && ($GLOBALS['ref_level'] > 0) && ($per < 100) && ($add_mode == "ref") && (isset($GLOBALS['cache_array']['add_uid'][$uid]))) {
+                       if ((EXT_IS_ACTIVE('refback')) && ($GLOBALS['ref_level'] > 0) && ($per < 100) && ($add_mode == "ref") && (isset($GLOBALS['cache_array']['add_uid'][$uid]))) {
                                //* DEBUG: */ print __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>):uid={$uid},data={$GLOBALS['cache_array']['add_uid'][$uid]},ref_points={$ref_points},depth={$GLOBALS['ref_level']} - BEFORE!<br />\n";
                                $ref_points = ADD_REFBACK_POINTS($GLOBALS['cache_array']['add_uid'][$uid], $uid, $points, $ref_points);
                                //* DEBUG: */ print __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>):uid={$uid},data={$GLOBALS['cache_array']['add_uid'][$uid]},ref_points={$ref_points},depth={$GLOBALS['ref_level']} - AFTER!<br />\n";
@@ -1228,9 +1228,9 @@ function ADD_POINTS_REFSYSTEM ($subject, $uid, $points, $send_notify=false, $rid
                        } // END - if
 
                        // Update mediadata as well
-                       if (GET_EXT_VERSION("mediadata") >= "0.0.4") {
+                       if (GET_EXT_VERSION('mediadata') >= '0.0.4') {
                                // Update database
-                               MEDIA_UPDATE_ENTRY(array("total_points"), "add", $ref_points);
+                               MEDIA_UPDATE_ENTRY(array('total_points'), 'add', $ref_points);
                        } // END - if
 
                        // Points updated, maybe I shall send him an email?
@@ -1262,7 +1262,7 @@ function ADD_POINTS_REFSYSTEM ($subject, $uid, $points, $send_notify=false, $rid
 
                                // And sent it away
                                SEND_EMAIL($email, getMessage('SUBJECT_DIRECT_PAYMENT'), $msg);
-                               if (!REQUEST_ISSET_GET(('mid'))) LOAD_TEMPLATE("admin_settings_saved", false, getMessage('ADMIN_POINTS_ADDED'));
+                               if (!REQUEST_ISSET_GET(('mid'))) LOAD_TEMPLATE('admin_settings_saved', false, getMessage('ADMIN_POINTS_ADDED'));
                        }
 
                        // Maybe there's another ref?
@@ -1313,7 +1313,7 @@ function UPDATE_REF_COUNTER ($uid) {
                // Move to next referal level and count his counter one up!
                //* DEBUG: */ print __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>):ref={$ref} - ADVANCE!<br />\n";
                $GLOBALS['cache_array']['ref_level'][$uid]++; UPDATE_REF_COUNTER($ref);
-       } elseif ((($ref == $uid) || ($ref == 0)) && (GET_EXT_VERSION("cache") >= "0.1.2")) {
+       } elseif ((($ref == $uid) || ($ref == 0)) && (GET_EXT_VERSION('cache') >= '0.1.2')) {
                // Remove cache here
                //* DEBUG: */ print __FUNCTION__."(<font color=\"#0000aa\">".__LINE__."</font>):ref={$ref} - CACHE!<br />\n";
                rebuildCacheFiles("refsystem", "refsystem");
@@ -1323,7 +1323,7 @@ function UPDATE_REF_COUNTER ($uid) {
        $GLOBALS['cache_array']['ref_level'][$uid]--;
 
        // Handle refback here if extension is installed
-       if (EXT_IS_ACTIVE("refback")) {
+       if (EXT_IS_ACTIVE('refback')) {
                UPDATE_REFBACK_table($uid);
        } // END - if
 }
@@ -1356,7 +1356,7 @@ function GET_ADMIN_ID ($login) {
 
                // Update cache hits
                incrementConfigEntry('cache_hits');
-       } elseif (!EXT_IS_ACTIVE("cache")) {
+       } elseif (!EXT_IS_ACTIVE('cache')) {
                // Load from database
                $result = SQL_QUERY_ESC("SELECT id FROM `{!_MYSQL_PREFIX!}_admins` WHERE login='%s' LIMIT 1",
                        array($login), __FUNCTION__, __LINE__);
@@ -1393,7 +1393,7 @@ function GET_ADMIN_HASH ($aid) {
 
                // Update cache hits
                incrementConfigEntry('cache_hits');
-       } elseif (!EXT_IS_ACTIVE("cache")) {
+       } elseif (!EXT_IS_ACTIVE('cache')) {
                // Load from database
                $result = SQL_QUERY_ESC("SELECT password FROM `{!_MYSQL_PREFIX!}_admins` WHERE id=%s LIMIT 1",
                 array($aid), __FUNCTION__, __LINE__);
@@ -1421,7 +1421,7 @@ function GET_ADMIN_LOGIN ($aid) {
 
                // Update cache hits
                incrementConfigEntry('cache_hits');
-       } elseif (!EXT_IS_ACTIVE("cache")) {
+       } elseif (!EXT_IS_ACTIVE('cache')) {
                // Load from database
                $result = SQL_QUERY_ESC("SELECT login FROM `{!_MYSQL_PREFIX!}_admins` WHERE id=%s LIMIT 1",
                        array(bigintval($aid)), __FUNCTION__, __LINE__);
@@ -1449,7 +1449,7 @@ function GET_ADMIN_EMAIL ($aid) {
 
                // Update cache hits
                incrementConfigEntry('cache_hits');
-       } elseif (!EXT_IS_ACTIVE("cache")) {
+       } elseif (!EXT_IS_ACTIVE('cache')) {
                // Load from database
                $result_aid = SQL_QUERY_ESC("SELECT email FROM `{!_MYSQL_PREFIX!}_admins` WHERE id=%s LIMIT 1",
                        array(bigintval($aid)), __FUNCTION__, __LINE__);
@@ -1474,7 +1474,7 @@ function GET_ADMIN_DEFAULT_ACL ($aid) {
        $ret = "***";
 
        // Is sql_patches there and was it found in cache?
-       if (!EXT_IS_ACTIVE("sql_patches")) {
+       if (!EXT_IS_ACTIVE('sql_patches')) {
                // Not found, which is bad, so we need to allow all
                $ret =  "allow";
        } elseif (isset($GLOBALS['cache_array']['admins']['def_acl'][$aid])) {
@@ -1483,7 +1483,7 @@ function GET_ADMIN_DEFAULT_ACL ($aid) {
 
                // Update cache hits
                incrementConfigEntry('cache_hits');
-       } elseif (!EXT_IS_ACTIVE("cache")) {
+       } elseif (!EXT_IS_ACTIVE('cache')) {
                // Load from database
                $result_aid = SQL_QUERY_ESC("SELECT default_acl FROM `{!_MYSQL_PREFIX!}_admins` WHERE id=%s LIMIT 1",
                        array(bigintval($aid)), __FUNCTION__, __LINE__);
@@ -1504,7 +1504,7 @@ function GET_ADMIN_DEFAULT_ACL ($aid) {
 }
 //
 function ADD_OPTION_LINES ($table, $id, $name, $default="", $special="", $where="") {
-       $ret = "";
+       $ret = '';
        if ($table == "/ARRAY/") {
                // Selection from array
                if (is_array($id) && is_array($name) && count($id) == count($name)) {
@@ -1520,14 +1520,14 @@ function ADD_OPTION_LINES ($table, $id, $name, $default="", $special="", $where=
                $SPEC = ", ".$id;
                if (!empty($special)) $SPEC = ", ".$special;
                $ORDER = $name.$SPEC;
-               if ($table == "country") $ORDER = $special;
+               if ($table == 'country') $ORDER = $special;
                $result = SQL_QUERY_ESC("SELECT %s, %s".$SPEC." FROM `{!_MYSQL_PREFIX!}_%s` ".$where." ORDER BY %s",
                        array($id, $ORDER, $table, $name), __FUNCTION__, __LINE__);
                if (SQL_NUMROWS($result) > 0) {
                        // Found data so add them as OPTION lines: $id is the value and $name is the "name" of the option
                        // @TODO Try to rewrite this to $content = SQL_FETCHARRAY()
                        while (list($value, $title, $add) = SQL_FETCHROW($result)) {
-                               if (empty($special)) $add = "";
+                               if (empty($special)) $add = '';
                                $ret .= "<option value=\"".$value."\"";
                                if ($default == $value) $ret .= " selected=\"selected\"";
                                if (!empty($add)) $add = " (".$add.")";
@@ -1548,18 +1548,18 @@ function ADD_OPTION_LINES ($table, $id, $name, $default="", $special="", $where=
 // Activate exchange
 function activateExchange () {
        // Is the extension 'user' there?
-       if (!EXT_IS_ACTIVE("user")) {
+       if (!EXT_IS_ACTIVE('user')) {
                // Silently abort here
                return false;
        } // END - if
 
        // Check total amount of users
-       $totalUsers = GET_TOTAL_DATA("CONFIRMED", "user_data", "userid", "status", true, " AND max_mails > 0");
+       $totalUsers = GET_TOTAL_DATA("CONFIRMED", "user_data", 'userid', "status", true, " AND max_mails > 0");
 
        if ($totalUsers >= getConfig('activate_xchange')) {
                // Activate System
                SET_SQLS(array(
-                       "UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', hidden='N', mem_only='Y' WHERE `module`='order' LIMIT 1",
+                       "UPDATE `{!_MYSQL_PREFIX!}_mod_reg` SET `locked`='N', `hidden`='N', `mem_only`='Y' WHERE `module`='order' LIMIT 1",
                        "UPDATE `{!_MYSQL_PREFIX!}_member_menu` SET `visible`='Y', `locked`='N' WHERE `what`='order' OR `what`='unconfirmed' LIMIT 2",
                        "UPDATE `{!_MYSQL_PREFIX!}_config` SET activate_xchange='0' WHERE config=0 LIMIT 1"
                ));
@@ -1590,9 +1590,9 @@ WHERE p.userid=%s", array(bigintval($uid)), __FUNCTION__, __LINE__);
                SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_user_points` WHERE userid=%s", array(bigintval($uid)), __FUNCTION__, __LINE__);
 
                // Update mediadata as well
-               if (GET_EXT_VERSION("mediadata") >= "0.0.4") {
+               if (GET_EXT_VERSION('mediadata') >= '0.0.4') {
                        // Update database
-                       MEDIA_UPDATE_ENTRY(array("total_points"), "sub", $points);
+                       MEDIA_UPDATE_ENTRY(array('total_points'), 'sub', $points);
                } // END - if
 
                // Now, when we have all his points adds them do the jackpot!
@@ -1604,7 +1604,7 @@ WHERE p.userid=%s", array(bigintval($uid)), __FUNCTION__, __LINE__);
                array(bigintval($uid)), __FUNCTION__, __LINE__);
 
        // Remove from rallye if found
-       if (EXT_IS_ACTIVE("rallye")) {
+       if (EXT_IS_ACTIVE('rallye')) {
                SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_rallye_users` WHERE userid=%s",
                        array(bigintval($uid)), __FUNCTION__, __LINE__);
        }
@@ -1620,9 +1620,9 @@ WHERE p.userid=%s", array(bigintval($uid)), __FUNCTION__, __LINE__);
 //
 function META_DESCRIPTION ($mod, $wht) {
        // Exclude admin and member's area
-       if (($mod != "admin") && ($mod != "login")) {
+       if (($mod != 'admin') && ($mod != "login")) {
                // Construct dynamic description
-               $DESCR = "{!MAIN_TITLE!} ".trim(getConfig('title_middle'))." ".ADD_DESCR("guest", "what-".$wht, true);
+               $DESCR = "{!MAIN_TITLE!} ".trim(getConfig('title_middle'))." ".ADD_DESCR('guest', "what-".$wht, true);
 
                // Output it directly
                OUTPUT_HTML("<meta name=\"description\" content=\"".$DESCR."\" />");
@@ -1672,7 +1672,7 @@ function SUB_JACKPOT($points) {
 }
 //
 function IS_DEMO () {
-       return ((EXT_IS_ACTIVE("demo")) && (get_session('admin_login') == "demo"));
+       return ((EXT_IS_ACTIVE('demo')) && (get_session('admin_login') == 'demo'));
 }
 
 // Gets the matching what name from module
@@ -1683,22 +1683,22 @@ function GET_WHAT ($modCheck) {
                return REQUEST_GET('what');
        } // END - if
 
-       $wht = "";
+       $wht = '';
        //* DEBUG: */ echo __LINE__."!".$modCheck."!<br />\n";
        switch ($modCheck)
        {
-       case "admin":
+       case 'admin':
                $wht = "overview";
                break;
 
        case "login":
-       case "index":
+       case 'index':
                $wht = "welcome";
-               if (($modCheck == "index") && (getConfig('index_home') != "")) $wht = getConfig('index_home');
+               if (($modCheck == 'index') && (getConfig('index_home') != "")) $wht = getConfig('index_home');
                break;
 
        default:
-               $wht = "";
+               $wht = '';
                break;
        }
 
@@ -1713,15 +1713,15 @@ function SUB_POINTS ($subject, $uid, $points) {
         array($points, bigintval($uid)), __FUNCTION__, __LINE__);
 
        // Insert booking record
-       if (EXT_IS_ACTIVE("booking")) {
+       if (EXT_IS_ACTIVE('booking')) {
                // Add record
-               ADD_BOOKING_RECORD($subject, $uid, $points, "sub");
+               ADD_BOOKING_RECORD($subject, $uid, $points, 'sub');
        } // END - if
 
        // Update mediadata as well
-       if (GET_EXT_VERSION("mediadata") >= "0.0.4") {
+       if (GET_EXT_VERSION('mediadata') >= '0.0.4') {
                // Update database
-               MEDIA_UPDATE_ENTRY(array("total_points"), "sub", $points);
+               MEDIA_UPDATE_ENTRY(array('total_points'), 'sub', $points);
        } // END - if
 }
 
@@ -1735,7 +1735,7 @@ function UPDATE_CONFIG ($entries, $values, $updateMode="") {
        // Do we have multiple entries?
        if (is_array($entries)) {
                // Walk through all
-               $all = "";
+               $all = '';
                foreach ($entries as $idx => $entry) {
                        // Update mode set?
                        if (!empty($updateMode)) {
@@ -1789,11 +1789,11 @@ function UPDATE_CONFIG ($entries, $values, $updateMode="") {
 // Prepares an SQL statement part for HTML mail and/or holiday depency
 function PREPARE_SQL_HTML_HOLIDAY ($mode) {
        // Exclude no users by default
-       $MORE = "";
+       $MORE = '';
 
        // HTML mail?
-       if ($mode == "html") $MORE = " AND html='Y'";
-       if (GET_EXT_VERSION("holiday") >= "0.1.3") {
+       if ($mode == 'html') $MORE = " AND html='Y'";
+       if (GET_EXT_VERSION('holiday') >= '0.1.3') {
                // Add something for the holiday extension
                $MORE .= " AND holiday_active='N'";
        } // END - if
@@ -1803,7 +1803,7 @@ function PREPARE_SQL_HTML_HOLIDAY ($mode) {
 }
 
 // "Getter" for total available receivers
-function GET_TOTAL_RECEIVERS ($mode="normal") {
+function GET_TOTAL_RECEIVERS ($mode='normal') {
        // Query database
        $result_all = SQL_QUERY("SELECT userid
 FROM `{!_MYSQL_PREFIX!}_user_data`
@@ -1824,7 +1824,7 @@ WHERE `status`='CONFIRMED' AND receive_mails > 0 ".PREPARE_SQL_HTML_HOLIDAY($mod
 function ADD_CATEGORY_OPTIONS ($mode) {
        // Prepare WHERE statement
        $whereStatement = " WHERE `visible`='Y'";
-       if (IS_ADMIN()) $whereStatement = "";
+       if (IS_ADMIN()) $whereStatement = '';
 
        // Initialize array...
        $CATS = array(
@@ -1872,7 +1872,7 @@ WHERE userid=%s AND `status`='CONFIRMED' AND receive_mails > 0".PREPARE_SQL_HTML
                SQL_FREERESULT($result);
 
                // Generate options
-               $OUT = "";
+               $OUT = '';
                foreach ($CATS['id'] as $key => $value) {
                        if (strlen($CATS['name'][$key]) > 20) $CATS['name'][$key] = substr($CATS['name'][$key], 0, 17)."...";
                        $OUT .= "      <option value=\"".$value."\">".$CATS['name'][$key]." (".$CATS['uids'][$key]." {--USER_IN_CAT--})</option>\n";
@@ -1887,18 +1887,18 @@ WHERE userid=%s AND `status`='CONFIRMED' AND receive_mails > 0".PREPARE_SQL_HTML
 }
 
 // Add bonus mail to queue
-function ADD_BONUS_MAIL_TO_QUEUE ($subject, $text, $receiverList, $points, $seconds, $url, $cat, $mode="normal", $receiver=0) {
+function ADD_BONUS_MAIL_TO_QUEUE ($subject, $text, $receiverList, $points, $seconds, $url, $cat, $mode='normal', $receiver=0) {
        // Is admin or bonus extension there?
        if (!IS_ADMIN()) {
                // Abort here
                return false;
-       } elseif (!EXT_IS_ACTIVE("bonus")) {
+       } elseif (!EXT_IS_ACTIVE('bonus')) {
                // Abort here
                return false;
        }
 
        // Calculcate target sent
-       $target = SELECTION_COUNT(explode(";", $receiverList));
+       $target = SELECTION_COUNT(explode(';', $receiverList));
 
        // Receiver is zero?
        if ($receiver == 0) {
@@ -1907,12 +1907,12 @@ function ADD_BONUS_MAIL_TO_QUEUE ($subject, $text, $receiverList, $points, $seco
        } // END - if
 
        // HTML extension active?
-       if (EXT_IS_ACTIVE("html")) {
+       if (EXT_IS_ACTIVE('html_mail')) {
                // No HTML by default
                $HTML = "N";
 
                // HTML mode?
-               if ($mode == "html") $HTML = "Y";
+               if ($mode == 'html') $HTML = "Y";
 
                // Add HTML mail
                SQL_QUERY_ESC("INSERT INTO `{!_MYSQL_PREFIX!}_bonus`
@@ -1953,8 +1953,8 @@ VALUES ('%s','%s','%s','%s','%s','NEW', UNIX_TIMESTAMP(),'%s','%s','%s','%s')",
 function GENERATE_RECEIVER_LIST ($cat, $receiver, $mode="") {
        // Init variables
        $CAT_TABS     = "%s";
-       $CAT_WHERE    = "";
-       $receiverList = "";
+       $CAT_WHERE    = '';
+       $receiverList = '';
        $result       = false;
 
        // Secure data
@@ -1975,12 +1975,12 @@ function GENERATE_RECEIVER_LIST ($cat, $receiver, $mode="") {
        } // END - if
 
        // Exclude users in holiday?
-       if (GET_EXT_VERSION("holiday") >= "0.1.3") {
+       if (GET_EXT_VERSION('holiday') >= '0.1.3') {
                // Add something for the holiday extension
                $CAT_WHERE .= " AND d.holiday_active='N'";
        } // END - if
 
-       if ((EXT_IS_ACTIVE("html_mail")) && ($mode == "html")) {
+       if ((EXT_IS_ACTIVE('html_mail')) && ($mode == 'html')) {
                // Only include HTML receivers
                $result = SQL_QUERY_ESC("SELECT d.userid FROM `{!_MYSQL_PREFIX!}_user_data` AS d ".$CAT_TABS." WHERE d.`status`='CONFIRMED' AND d.html='Y'".$CAT_WHERE." ORDER BY d.%s %s LIMIT %s",
                        array($cat, getConfig('order_select'), getConfig('order_mode'), $receiver), __FUNCTION__, __LINE__);
@@ -1995,7 +1995,7 @@ function GENERATE_RECEIVER_LIST ($cat, $receiver, $mode="") {
                // Load all entries
                while ($content = SQL_FETCHARRAY($result)) {
                        // Add receiver when not empty
-                       if (!empty($content['userid'])) $receiverList .= $content['userid'].";";
+                       if (!empty($content['userid'])) $receiverList .= $content['userid'] . ';';
                } // END - while
 
                // Free memory
@@ -2020,7 +2020,7 @@ function USER_STATS_GET_TIMESTAMP ($type, $data, $uid = 0) {
        } // END - if
 
        // Is the extension installed and updated?
-       if ((!EXT_IS_ACTIVE("sql_patches")) || (EXT_VERSION_IS_OLDER("sql_patches", "0.5.6"))) {
+       if ((!EXT_IS_ACTIVE('sql_patches')) || (EXT_VERSION_IS_OLDER('sql_patches', '0.5.6'))) {
                // Return zero here
                return $stamp;
        } // END - if
@@ -2048,7 +2048,7 @@ LIMIT 1",
 // Inserts user stats
 function USER_STATS_INSERT_RECORD ($uid, $type, $data) {
        // Is the extension installed and updated?
-       if ((!EXT_IS_ACTIVE("sql_patches")) || (EXT_VERSION_IS_OLDER("sql_patches", "0.5.6"))) {
+       if ((!EXT_IS_ACTIVE('sql_patches')) || (EXT_VERSION_IS_OLDER('sql_patches', '0.5.6'))) {
                // Return zero here
                return false;
        } // END - if
@@ -2068,11 +2068,11 @@ function USER_STATS_INSERT_RECORD ($uid, $type, $data) {
 function GET_USER_REF_POINTS ($uid, $level) {
        //* DEBUG: */ print "----------------------- <font color=\"#00aa00\">".__FUNCTION__." - ENTRY</font> ------------------------<ul><li>\n";
        // Default is no refs and no nickname
-       $add = "";
+       $add = '';
        $refs = array();
 
        // Do we have nickname extension installed?
-       if (EXT_IS_ACTIVE("nickname")) {
+       if (EXT_IS_ACTIVE('nickname')) {
                $add = ", ud.nickname";
        } // END - if
 
@@ -2095,7 +2095,7 @@ ORDER BY ur.refid ASC",
                        $row['points'] = GET_TOTAL_DATA($row['refid'], "user_points", "points") - GET_TOTAL_DATA($row['refid'], "user_data", "used_points");
 
                        // Get unconfirmed mails
-                       $row['unconfirmed']  = GET_TOTAL_DATA($row['refid'], "user_links", "id", "userid", true);
+                       $row['unconfirmed']  = GET_TOTAL_DATA($row['refid'], "user_links", "id", 'userid', true);
 
                        // Init clickrate with zero
                        $row['clickrate'] = 0;
@@ -2106,11 +2106,11 @@ ORDER BY ur.refid ASC",
                                $row['clickrate'] = ($row['mails_confirmed'] / $row['emails_received'] * 100);
                        } // END - if
 
-                       // Activity is "active" by default because if autopurge is not installed
+                       // Activity is 'active' by default because if autopurge is not installed
                        $row['activity'] = MEMBER_ACTIVITY_ACTIVE;
 
                        // Is autopurge installed and the user inactive?
-                       if ((EXT_IS_ACTIVE("autopurge")) && ((time() - getConfig('ap_inactive_since')) >= $row['last_online']))  {
+                       if ((EXT_IS_ACTIVE('autopurge')) && ((time() - getConfig('ap_inactive_since')) >= $row['last_online']))  {
                                // Inactive user!
                                $row['activity'] = MEMBER_ACTIVITY_INACTIVE;
                        } // END - if
index 256e16109e0cca3f026053a3f75f6d9c89a0ce58..ef5fab6c075e849ae2b0f767e74ec4f8e49fe261 100644 (file)
@@ -53,7 +53,7 @@ $GLOBALS['pool_cnt'] = 0;
 
 // Init & set the include pool
 INIT_INC_POOL();
-SET_INC_POOL(GET_DIR_AS_ARRAY("inc/pool/", "pool-"));
+SET_INC_POOL(GET_DIR_AS_ARRAY('inc/pool/', 'pool-'));
 
 // Run the filter
 runFilterChain('load_includes');
index 928808d36921313c2a207219bdf087e17ac247e5..1ec6dadf44ad6b1165b8f4f6af68fcf3b3609f7c 100644 (file)
@@ -46,7 +46,7 @@ if (!defined('__SECURITY')) {
 if (isResetModeEnabled()) {
        // Skip here
        return false;
-} elseif (!EXT_IS_ACTIVE("bonus")) {
+} elseif (!EXT_IS_ACTIVE('bonus')) {
        // Abort if extension bonus is not active
        return false;
 }
@@ -55,7 +55,7 @@ if (isResetModeEnabled()) {
 // Only send bonus mail when bonus extension is active and maximum send-mails is not reached
 if ($GLOBALS['pool_cnt'] < getConfig('max_send')) {
        // Do we need to send out bonus mails?
-       if (EXT_IS_ACTIVE("html_mail")) {
+       if (EXT_IS_ACTIVE('html_mail')) {
                //                                 0     1       2        3        4      5       6          7       8      9         10         11
                $result_bonus = SQL_QUERY("SELECT id, subject, text, receivers, points, time, data_type, timestamp, url, cat_id, target_send, html_msg FROM `{!_MYSQL_PREFIX!}_bonus` WHERE data_type='NEW' ORDER BY timestamp DESC", __FILE__, __LINE__);
        } else {
@@ -65,7 +65,7 @@ if ($GLOBALS['pool_cnt'] < getConfig('max_send')) {
 
        if (SQL_NUMROWS($result_bonus) > 0) {
                // Send these mails away...
-               $cnt2 = "";
+               $cnt2 = '';
                while ($DATA = SQL_FETCHARRAY($result_bonus)) {
                        // Compile URL
                        $DATA['url'] = COMPILE_CODE($DATA['url']);
@@ -75,9 +75,9 @@ if ($GLOBALS['pool_cnt'] < getConfig('max_send')) {
                                array(bigintval($DATA['id'])), __FILE__, __LINE__);
 
                        // "Explode" all receivers into an array
-                       if (ereg(";", $DATA['receivers'])) {
+                       if (ereg(';', $DATA['receivers'])) {
                                // There's more than one receiver in the list...
-                               $RECEIVERS = explode(";", $DATA['receivers']);
+                               $RECEIVERS = explode(';', $DATA['receivers']);
                        } elseif (!empty($DATA['points'])) {
                                // Only one user left
                                $RECEIVERS = array($DATA['receivers']);
@@ -133,7 +133,7 @@ if ($GLOBALS['pool_cnt'] < getConfig('max_send')) {
                                                // Count one up and remove entry from dummy array
                                                $GLOBALS['pool_cnt']++; unset($dummy[$key]);
 
-                                               if (GET_EXT_VERSION("user") >= "0.1.4") {
+                                               if (GET_EXT_VERSION('user') >= '0.1.4') {
                                                        // Update mails received for receiver
                                                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET emails_received=emails_received+1 WHERE userid=%s LIMIT 1",
                                                                array(bigintval($uid)), __FILE__, __LINE__);
@@ -153,12 +153,12 @@ if ($GLOBALS['pool_cnt'] < getConfig('max_send')) {
                        }
 
                        // Update mediadata if version is 0.0.4 or higher
-                       if (GET_EXT_VERSION("mediadata") >= "0.0.4") {
+                       if (GET_EXT_VERSION('mediadata') >= '0.0.4') {
                                // Update entry (or add missing
                                $P = $GLOBALS['pool_cnt'];
                                if (!empty($cnt2) && empty($GLOBALS['pool_cnt'])) $P = $cnt2;
                                //* DEBUG: */ echo "+MEDIA/L:".__LINE__."/".$P."+<br />";
-                               MEDIA_UPDATE_ENTRY(array("total_send", "bonus_send"), "add", $P);
+                               MEDIA_UPDATE_ENTRY(array("total_send", "bonus_send"), 'add', $P);
                        } // END - if
 
                        // Close sending system
@@ -170,15 +170,15 @@ if ($GLOBALS['pool_cnt'] < getConfig('max_send')) {
                                //* DEBUG: */ echo "*L:".__LINE__."*<br />";
 
                                // Update mediadata if version is 0.0.4 or higher
-                               if (GET_EXT_VERSION("mediadata") >= "0.0.4") {
+                               if (GET_EXT_VERSION('mediadata') >= '0.0.4') {
                                        // Update entry (or add missing)
                                        //* DEBUG: */ echo "*MEDIA/L:".__LINE__."*<br />";
-                                       MEDIA_UPDATE_ENTRY(array("total_orders", "bonus_orders"), "add", 1);
+                                       MEDIA_UPDATE_ENTRY(array("total_orders", "bonus_orders"), 'add', 1);
                                } // END - if
                        } elseif ($GLOBALS['pool_cnt'] >= getConfig('max_send')) {
                                // Update bonus pool
                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_bonus` SET data_type='NEW', target_send=%s, receivers='%s' WHERE id=%s LIMIT 1",
-                                       array(SELECTION_COUNT($dummy), implode(";", $dummy), bigintval($DATA['id'])), __FILE__, __LINE__);
+                                       array(SELECTION_COUNT($dummy), implode(';', $dummy), bigintval($DATA['id'])), __FILE__, __LINE__);
                                //* DEBUG: */ echo "*L:".__LINE__."<pre>";
                                //* DEBUG: */ print_r($dummy);
                                //* DEBUG: */ echo "</pre>\n!!!<br />";
index 78434638f5fe999d643da4eb9ec1b86bbfc0975f..5cedc2ca6ab1a89c33f66deecf82fbef537c41bc 100644 (file)
@@ -46,14 +46,14 @@ if (!defined('__SECURITY')) {
 if (isResetModeEnabled()) {
        // Skip here
        return false;
-} elseif (!EXT_IS_ACTIVE("user")) {
+} elseif (!EXT_IS_ACTIVE('user')) {
        // Abort here if extension user is not active
        return false;
 }
 
 // Need this here
 // Check for freed mail orders to send out
-if (EXT_IS_ACTIVE("html_mail")) {
+if (EXT_IS_ACTIVE('html_mail')) {
        //                                0     1        2      3       4          5            6      7        8          9       10
        $result_main = SQL_QUERY("SELECT id, sender, subject, text, receivers, payment_id, timestamp, url, target_send, cat_id, html_msg FROM `{!_MYSQL_PREFIX!}_pool` WHERE data_type='NEW' ORDER BY timestamp DESC", __FILE__, __LINE__);
 } else {
@@ -66,7 +66,7 @@ $cnt2 = 0; $lastSentId = 0; $cnt_back = array("0"); $pointsBack = array("0");
 if (SQL_NUMROWS($result_main) > 0) {
        // Parse all mails
        while ($DATA = SQL_FETCHROW($result_main)) {
-               // Set mail order as "active". That means it will be sent out
+               // Set mail order as 'active'. That means it will be sent out
                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_pool` SET data_type='ACTIVE' WHERE id=%s AND data_type='NEW' LIMIT 1",
                        array($DATA[0]), __FILE__, __LINE__);
 
@@ -79,9 +79,9 @@ if (SQL_NUMROWS($result_main) > 0) {
                // Entry updated?
                if (SQL_AFFECTEDROWS() == 1) {
                        // "Explode" all receivers into an array
-                       if (ereg(";", $DATA[4])) {
+                       if (ereg(';', $DATA[4])) {
                                // There's more than one receiver in the list...
-                               $RECEIVERS = explode(";", $DATA[4]);
+                               $RECEIVERS = explode(';', $DATA[4]);
                        } elseif (!empty($DATA[4])) {
                                // Only one user left
                                $RECEIVERS = array($DATA[4]);
@@ -165,17 +165,17 @@ if (SQL_NUMROWS($result_main) > 0) {
                                                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET emails_sent=emails_sent+1 WHERE userid=%s LIMIT 1",
                                                                array(bigintval($DATA[1])), __FILE__, __LINE__);
 
-                                                       if (GET_EXT_VERSION("user") >= "0.1.4") {
+                                                       if (GET_EXT_VERSION('user') >= '0.1.4') {
                                                                // Update mails received for receiver
                                                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET emails_received=emails_received+1 WHERE userid=%s LIMIT 1",
                                                                        array(bigintval($uid)), __FILE__, __LINE__);
                                                        } // END - if
 
                                                        // Update mediadata if version is 0.0.4 or higher
-                                                       if (GET_EXT_VERSION("mediadata") >= "0.0.4") {
+                                                       if (GET_EXT_VERSION('mediadata') >= '0.0.4') {
                                                                // Update entry (or add missing)
                                                                //* DEBUG: */ echo "*MEDIA/L:".__LINE__."*<br />";
-                                                               MEDIA_UPDATE_ENTRY(array("total_send", "normal_send"), "add", 1);
+                                                               MEDIA_UPDATE_ENTRY(array("total_send", "normal_send"), 'add', 1);
                                                        } // END - if
 
                                                        // And count up the mail
@@ -237,10 +237,10 @@ if (SQL_NUMROWS($result_main) > 0) {
                                                $cnt2 += $GLOBALS['pool_cnt'];
 
                                                // Update mediadata if version is 0.0.4 or higher
-                                               if (GET_EXT_VERSION("mediadata") >= "0.0.4") {
+                                               if (GET_EXT_VERSION('mediadata') >= '0.0.4') {
                                                        // Update entry (or add missing)
                                                        //* DEBUG: */ echo "*MEDIA/L:".__LINE__."*<br />";
-                                                       MEDIA_UPDATE_ENTRY(array("total_orders", "normal_orders"), "add", 1);
+                                                       MEDIA_UPDATE_ENTRY(array("total_orders", "normal_orders"), 'add', 1);
                                                } // END - if
 
                                                //* DEBUG: */ echo"*EXIT/L:".__LINE__."/".$P."<br />";
@@ -249,10 +249,10 @@ if (SQL_NUMROWS($result_main) > 0) {
                                        // Do we have send maximum mails?
                                         elseif (($GLOBALS['pool_cnt'] >= getConfig('max_send')) || ($cnt2 >= getConfig('max_send'))) {
                                                // There are some mails left to send for next round, so we reset the status back to NEW (=still not fully delivered)
-                                               $add = "";
+                                               $add = '';
                                                if ($GLOBALS['pool_cnt'] <= $DATA[8]) $add = ", target_send=target_send-".$GLOBALS['pool_cnt'];
                                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_pool` SET data_type='NEW', receivers='%s'".$add." WHERE id=%s LIMIT 1",
-                                                array(implode(";", $dummy), bigintval($DATA[0])), __FILE__, __LINE__);
+                                                array(implode(';', $dummy), bigintval($DATA[0])), __FILE__, __LINE__);
 
                                                //* DEBUG: */ echo"*EXIT/L:".__LINE__."*<br />";
                                                break;
@@ -286,7 +286,7 @@ if (SQL_NUMROWS($result_main) > 0) {
 
                                        // Update receivers
                                        SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_pool` SET receivers='%s' WHERE id=%s LIMIT 1",
-                                               array(implode(";", $dummy), bigintval($DATA[0])), __FILE__, __LINE__);
+                                               array(implode(';', $dummy), bigintval($DATA[0])), __FILE__, __LINE__);
                                }
                        }
                }
@@ -323,7 +323,7 @@ if (SQL_NUMROWS($result_main) > 0) {
                                        ADD_JACKPOT($PB);
 
                                        // Send mail out to admin
-                                       SEND_ADMIN_NOTIFICATION(ADMIN_BACK_JACKPOT." (".$uid.")", "back-admin", $content, "admin");
+                                       SEND_ADMIN_NOTIFICATION(ADMIN_BACK_JACKPOT." (".$uid.")", "back-admin", $content, 'admin');
                                }
                        } // END - if
                } // END - foreach
index 091cc6ffb322f8cb3145bf57c15cea727daf2cea..4371a5e57f48517ca3ffbd552e968e599052c2a3 100644 (file)
@@ -43,7 +43,7 @@ if (!defined('__SECURITY')) {
        require($INC);
 }
 
-if ((getConfig('send_prof_update') == "Y") && (getConfig('profile_update') > 0) && (getConfig('resend_profile_update'))) {
+if ((getConfig('send_prof_update') == 'Y') && (getConfig('profile_update') > 0) && (getConfig('resend_profile_update'))) {
        // Load personal data              0      1        2          3
        $result = SQL_QUERY_ESC("SELECT userid, email, last_update, joined
 FROM
@@ -70,7 +70,7 @@ ORDER BY userid", array(getConfig('profile_update'), getConfig('resend_profile_u
                        }
 
                        // Load email template and send mail away
-                       $msg = LOAD_EMAIL_TEMPLATE("profile-updte", "", bigintval($content['userid']));
+                       $msg = LOAD_EMAIL_TEMPLATE("profile-updte", '', bigintval($content['userid']));
                        SEND_EMAIL($content['email'], getMessage('PROFILE_OUTDATED'), $msg);
 
                        // Update profile data
index 6465f68041fe513af76f5041ec51eabc561519fb..a2b709e94c16c423078c4cd40366326511d7e09b 100644 (file)
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("beg")) {
+} elseif (!EXT_IS_ACTIVE('beg')) {
        return;
 }
 
 // Do not execute when script is in CSS mode or no daily reset
-if (($GLOBALS['output_mode'] == 1) || (!isResetModeEnabled()) || (getConfig('beg_rallye') == "Y")) return;
+if (($GLOBALS['output_mode'] == 1) || (!isResetModeEnabled()) || (getConfig('beg_rallye') == 'Y')) return;
 //* DEBUG: */ echo basename(__FILE__)."<br />\n";
 
 // Reset accounts
index 307d9d31e5805ddfffc0fb44413548d06955ec98..94574d00af969940cb5e52d204aa4ff5be3dce41 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("bonus")) {
+} elseif (!EXT_IS_ACTIVE('bonus')) {
        return;
 }
 
index 9c72d9b5de8c1d2f91b97aa8bc8f46904ab8f7df..f4270b0c255afe95f07cf14523e0b5bc07b6e57d 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("sql_patches")) {
+} elseif (!EXT_IS_ACTIVE('sql_patches')) {
        return;
 }
 
@@ -49,7 +49,7 @@ if (($GLOBALS['output_mode'] == 1) || (!isResetModeEnabled())) return;
 //* DEBUG: */ echo basename(__FILE__)."<br />\n";
 
 // Update user profiles
-if (GET_EXT_VERSION("order") >= "0.1.1") {
+if (GET_EXT_VERSION('order') >= '0.1.1') {
        // Latest version
        $result_daily = SQL_QUERY("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET receive_mails=max_mails, mail_orders=0 WHERE receive_mails != max_mails", __FILE__, __LINE__);
 } else {
@@ -86,9 +86,9 @@ LIMIT 1",
                                        array($content['locked_points'], bigintval($content['userid']), $content['ref_depth']), __FILE__, __LINE__, false));
 
                                // Update mediadata as well
-                               if (GET_EXT_VERSION("mediadata") >= "0.0.4") {
+                               if (GET_EXT_VERSION('mediadata') >= '0.0.4') {
                                        // Update database
-                                       MEDIA_UPDATE_ENTRY(array("total_points"), "add", $content['locked_points']);
+                                       MEDIA_UPDATE_ENTRY(array('total_points'), 'add', $content['locked_points']);
                                } // END - if
                        } // END - while
                } // END - if
index 715e9d4e534d1823c0dd683f016ce12de1ec2fce..13d1203a7980b007bfb04896c0edf7a3991bce09 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("holiday")) {
+} elseif (!EXT_IS_ACTIVE('holiday')) {
        return;
 }
 
index f8e1c7c8c3e6e2ef614fe170ecad84f592e1ba00..b2e09b56decaf56e0ae8c4c1b7c91fff24ca876a 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("surfbar")) {
+} elseif (!EXT_IS_ACTIVE('surfbar')) {
        return;
 }
 
index db88e730ffd38d6b7a968b44774203c402d7a96f..e09c22e04465331bdb4e4094b3adc3d2efa3f9ca 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("yoomedia")) {
+} elseif (!EXT_IS_ACTIVE('yoomedia')) {
        return;
 }
 
index 5433011dc4517729f25d38d709d3c65b1e624eab..df1bd2f1c09cb41dfc6888eb98f562b6837f5ded 100644 (file)
@@ -108,16 +108,16 @@ function destroy_user_session () {
        setUserId(0);
 
        // Remove all user data from session
-       return ((set_session('userid', "")) && (set_session('u_hash', "")));
+       return ((set_session('userid', '')) && (set_session('u_hash', '')));
 }
 
 // Destroys the admin session
 function destroyAdminSession ($destroy = true) {
        // Kill maybe existing session variables including array elements
-       set_session('admin_login', "");
-       set_session('admin_md5'  , "");
-       set_session('admin_last' , "");
-       set_session('admin_to'   , "");
+       set_session('admin_login', '');
+       set_session('admin_md5'  , '');
+       set_session('admin_last' , '');
+       set_session('admin_to'   , '');
 
        // Destroy session and return status
        if ($destroy) {
index 600db9681788984120f3a80a13f64fa7edae7bd3..e2f7fbe0813c3d6082005107ec32cb45dd2abee7 100644 (file)
@@ -40,7 +40,7 @@
 if (!defined('__SECURITY')) {
        $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
        require($INC);
-} elseif (!EXT_IS_ACTIVE("surfbar")) {
+} elseif (!EXT_IS_ACTIVE('surfbar')) {
        return;
 }
 
index f4c8ab5e9a1811a14a23081031c2152e2c057fe4..11e2b2f5c6db3931e4358d543efdc24edde2b5de 100644 (file)
--- a/index.php
+++ b/index.php
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "index";
+$GLOBALS['module'] = 'index';
 
-// Set "CSS-Mode"
-$GLOBALS['output_mode'] = "0";
+// Set 'CSS-Mode'
+$GLOBALS['output_mode'] = '0';
 
 // Load config.php
-require("inc/config.php");
+require('inc/config.php');
 
 // Is the script installed?
 if (isInstalled()) {
        // Header
-       LOAD_INC("inc/header.php");
+       LOAD_INC('inc/header.php');
 
        // Fix missing array elements here
        if (!isConfigEntrySet('index_delay'))  setConfigEntry('index_delay' , 0);
@@ -67,32 +67,32 @@ if (isInstalled()) {
                // Is the index page configured for redirect pr not?
                if (getConfig('index_cookie') > 0) {
                        // Set cookie and remeber it for specified time
-                       set_session('visited', "true");
+                       set_session('visited', 'true');
                } elseif (isSessionVariableSet('visited')) {
                        // Remove cookie when admin set 0 in setup
-                       set_session('visited', "");
+                       set_session('visited', '');
                }
 
                // Template laden
-               LOAD_TEMPLATE("index", false, ADD_URL_DATA(""));
+               LOAD_TEMPLATE('index', false, ADD_URL_DATA(''));
 
                // Shall I insert an automated forward?
                if (getConfig('index_delay') > 0) {
                        // This will be a JavaScript-redirect!
                        define('__DELAY_VALUE', (getConfig('index_delay') * 1000 + 500));
-                       define('__MOD_VALUE'  , ADD_URL_DATA("index"));
-                       LOAD_TEMPLATE("index_forward");
+                       define('__MOD_VALUE'  , ADD_URL_DATA('index'));
+                       LOAD_TEMPLATE('index_forward');
                } // END - if
        } else {
                // Redirect to main page
-               LOAD_URL("modules.php?module=index");
+               LOAD_URL('modules.php?module=index');
        }
 
        // Footer
-       LOAD_INC("inc/footer.php");
+       LOAD_INC('inc/footer.php');
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // All done here...
index 03594bbc1e8f43ec97f8a2178d6522142a003fdb..0253d0e1d423a73aa2d8c1b59e4ee8f8deaaa8ec 100644 (file)
  ************************************************************************/
 
 // Load security system
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Tell every module / include file we are installing
 $GLOBALS['mxchange_installing'] = true;
 
 // Init "action" and "what"
-$GLOBALS['what']   = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what']   = '';
+$GLOBALS['action'] = '';
 
 // Set CSS variable for "normal mode"
 $GLOBALS['output_mode'] = 0;
 
 // Set module
-$GLOBALS['module'] = "install";
+$GLOBALS['module'] = 'install';
 
 // Load config file
-require("inc/config.php");
+require('inc/config.php');
 
 // Header
-LOAD_INC("inc/header.php");
+LOAD_INC('inc/header.php');
 
 // Reload page to page=welcome when it is not specified
 if (!REQUEST_ISSET_GET('page')) {
-       LOAD_URL("install.php?page=welcome");
+       LOAD_URL('install.php?page=welcome');
 } // END - if
 
 // Already installed?
@@ -82,17 +82,17 @@ if ((isInstalled()) && (isAdminRegistered())) {
 // Does something goes wrong?
 if (getTotalFatalErrors() == 0) {
        // Add main installation table
-       LOAD_TEMPLATE("install_header");
+       LOAD_TEMPLATE('install_header');
 
        // Here start's our installtion stuff
-       LOAD_INC_ONCE("inc/install-inc.php");
+       LOAD_INC_ONCE('inc/install-inc.php');
 
        // Close main installation table
-       LOAD_TEMPLATE("install_footer");
+       LOAD_TEMPLATE('install_footer');
 }
 
 // Footer
-LOAD_INC("inc/footer.php");
+LOAD_INC('inc/footer.php');
 
 //
 ?>
diff --git a/js.php b/js.php
index f2ea7676a51dcaee0e6f768d75cc79a907cbba50..e86211a103d0a767e2e42bd2dd6ec5016d279588 100644 (file)
--- a/js.php
+++ b/js.php
 define('_OB_CACHING', "old");
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what']   = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what']   = '';
+$GLOBALS['action'] = '';
 
 // This is a fake-CSS file loader, more a JavaScript loader...
 // This is in one way good and in one not. The whole reset part will be
@@ -53,19 +53,19 @@ $GLOBALS['action'] = "";
 // pattern is given...
 //
 // But mxchange 0.3.0 will show that in better way! :D :D :D
-$GLOBALS['output_mode'] = "1";
-$GLOBALS['module'] = "js";
+$GLOBALS['output_mode'] = '1';
+$GLOBALS['module'] = 'js';
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Is this script installed and a JavaScript tag is provied?
 if ((isInstalled()) && (REQUEST_ISSET_GET(('tag')))) {
        // Set header
-       header("Content-type: text/javascript");
+       header('Content-type: text/javascript');
 
        // Load header
-       LOAD_INC_ONCE("inc/header.php");
+       LOAD_INC_ONCE('inc/header.php');
 
        // Prepare include file for looking
        $INC = sprintf("inc/js/tag-%s.php",
@@ -79,7 +79,7 @@ if ((isInstalled()) && (REQUEST_ISSET_GET(('tag')))) {
        } // END - if 
 
        // Load footer
-       LOAD_INC_ONCE("inc/footer.php");
+       LOAD_INC_ONCE('inc/footer.php');
 } // END - if
 
 // Shutdown
index cc81336563276dc7f413eb87cc5dfafec2ac015d..1fb03bf8ab260fc88129a322cf131a0983e69ba6 100644 (file)
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
 $GLOBALS['startTime'] = microtime(true);
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "lead-confirm";
+$GLOBALS['module'] = 'lead-confirm';
 
 // Set "CSS-Mode"
-$GLOBALS['output_mode'] = "0";
+$GLOBALS['output_mode'] = '0';
 
 // Load config.php
-require("inc/config.php");
+require('inc/config.php');
 
 // Is the script installed?
 if (isInstalled()) {
        // Header
-       LOAD_INC("inc/header.php");
+       LOAD_INC('inc/header.php');
 
        // Initialize the array for the template
        $content = array(
                'lead_uid'   => -1,
-               'lead_email' => "INVALID@EMAIL"
+               'lead_email' => 'INVALID@EMAIL'
        );
 
        // Is the cookie set?
@@ -88,13 +88,13 @@ if (isInstalled()) {
        }
 
        // Load the lead template
-       LOAD_TEMPLATE("lead_code", false, $content);
+       LOAD_TEMPLATE('lead_code', false, $content);
 
        // Footer
-       LOAD_INC("inc/footer.php");
+       LOAD_INC('inc/footer.php');
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // All done here...
index 57ca9d4027fb799618e539f7c8830c194e4409d3..eabaef64e219cbee1949370291b8c7722f37a842 100644 (file)
--- a/login.php
+++ b/login.php
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "login";
+$GLOBALS['module'] = 'login';
 
-// Set "CSS-Mode"
-$GLOBALS['output_mode'] = "0";
+// Set 'CSS-Mode'
+$GLOBALS['output_mode'] = '0';
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Is the script installed?
 if (isInstalled()) {
        // Is this a member?
        if (IS_MEMBER()) {
                // Then redirect into login area
-               LOAD_URL("modules.php?module=login");
+               LOAD_URL('modules.php?module=login');
        } else {
                // Guests will be redirected to login form
-               LOAD_URL("modules.php?module=index&amp;what=login");
+               LOAD_URL('modules.php?module=index&amp;what=login');
        }
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
index 7b3128bff2a2013aaf60c4ad2c636b0f7e42b3d2..5a176e4410fa06ab59ac4537a65f4656bf8cdf80 100644 (file)
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Tell everyone we are in this module
-$GLOBALS['module'] = "mailid";
+$GLOBALS['module'] = 'mailid';
 $GLOBALS['output_mode'] = -1;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 if (isInstalled()) {
        // Is the extension active?
-       REDIRECT_ON_UNINSTALLED_EXTENSION("mailid");
+       REDIRECT_ON_UNINSTALLED_EXTENSION('mailid');
 
        // Init
        $url_uid = 0; $url_bid = 0; $url_mid = 0;
 
        // Secure all data
-       if (REQUEST_ISSET_GET(('uid')))     $url_uid = bigintval(REQUEST_GET('uid'));
-       if (REQUEST_ISSET_GET(('mailid')))  $url_mid = bigintval(REQUEST_GET('mailid'));
-       if (REQUEST_ISSET_GET(('bonusid'))) $url_bid = bigintval(REQUEST_GET('bonusid'));
+       if (REQUEST_ISSET_GET('uid'))     $url_uid = bigintval(REQUEST_GET('uid'));
+       if (REQUEST_ISSET_GET('mailid'))  $url_mid = bigintval(REQUEST_GET('mailid'));
+       if (REQUEST_ISSET_GET('bonusid')) $url_bid = bigintval(REQUEST_GET('bonusid'));
 
        // 01        1        12            3    32           21    1                   22     10
        if (($url_uid) > 0 && (($url_mid > 0) || ($url_bid > 0)) && (getTotalFatalErrors() == 0)) {
@@ -69,15 +69,15 @@ if (isInstalled()) {
                        // Normal-Mails
                        $result = SQL_QUERY_ESC("SELECT link_type FROM `{!_MYSQL_PREFIX!}_user_links` WHERE stats_id=%s AND userid=%s LIMIT 1",
                                array($url_mid, $url_uid), __FILE__, __LINE__);
-                       $type = "mailid"; $urlId = $url_mid;
+                       $type = 'mailid'; $urlId = $url_mid;
                } elseif ($url_bid > 0) {
                        // Bonus-Mail
                        $result = SQL_QUERY_ESC("SELECT link_type FROM `{!_MYSQL_PREFIX!}_user_links` WHERE bonus_id=%s AND userid=%s LIMIT 1",
                                array($url_bid, $url_uid), __FILE__, __LINE__);
-                       $type = "bonusid"; $urlId = $url_bid;
+                       $type = 'bonusid'; $urlId = $url_bid;
                } else {
                        // Problem: No ID entered
-                       LOAD_URL("index.php");
+                       LOAD_URL('index.php');
                }
 
                if (SQL_NUMROWS($result) == 1) {
@@ -89,15 +89,15 @@ if (isInstalled()) {
 
                        switch ($ltype)
                        {
-                       case "NORMAL":
+                       case 'NORMAL':
                                // Is the stats ID valid?
                                $result = SQL_QUERY_ESC("SELECT pool_id, url, subject FROM `{!_MYSQL_PREFIX!}_user_stats` WHERE id=%s LIMIT 1",
                                        array($url_mid), __FILE__, __LINE__);
                                break;
 
-                       case "BONUS":
+                       case 'BONUS':
                                // Is the bonus extension active?
-                               REDIRECT_ON_UNINSTALLED_EXTENSION("bonus");
+                               REDIRECT_ON_UNINSTALLED_EXTENSION('bonus');
 
                                // Bonus-Mails
                                $result = SQL_QUERY_ESC("SELECT id, url, subject FROM `{!_MYSQL_PREFIX!}_bonus` WHERE id=%s LIMIT 1",
@@ -121,17 +121,17 @@ if (isInstalled()) {
                                if (SQL_NUMROWS($result) == 1) {
                                        list($status, $gender, $sname, $fname) = SQL_FETCHROW($result);
                                        SQL_FREERESULT($result);
-                                       if ($status == "CONFIRMED") {
+                                       if ($status == 'CONFIRMED') {
                                                // User has confirmed his account so we can procede...
                                                switch ($ltype)
                                                {
-                                               case "NORMAL":
+                                               case 'NORMAL':
                                                        $result = SQL_QUERY_ESC("SELECT payment_id FROM `{!_MYSQL_PREFIX!}_user_stats` WHERE pool_id=%s LIMIT 1",
                                                                array(bigintval($pool)), __FILE__, __LINE__);
                                                        if (SQL_NUMROWS($result) == 1) {
                                                                list($pay) = SQL_FETCHROW($result);
-                                                               $time      = GET_PAY_POINTS($pay, "time");
-                                                               $payment   = GET_PAY_POINTS($pay, "payment");
+                                                               $time      = GET_PAY_POINTS($pay, 'time');
+                                                               $payment   = GET_PAY_POINTS($pay, 'payment');
                                                                $isValid   = true;
                                                        }
 
@@ -139,12 +139,12 @@ if (isInstalled()) {
                                                        SQL_FREERESULT($result);
                                                        break;
 
-                                               case "BONUS":
+                                               case 'BONUS':
                                                        $result = SQL_QUERY_ESC("SELECT points, time FROM `{!_MYSQL_PREFIX!}_bonus` WHERE id=%s LIMIT 1",
                                                                array($url_bid), __FILE__, __LINE__);
                                                        if (SQL_NUMROWS($result) == 1) {
                                                                list($points, $time) = SQL_FETCHROW($result);
-                                                               $payment = "0.00000";
+                                                               $payment = '0.00000';
                                                                $isValid = true;
                                                        }
 
@@ -154,12 +154,12 @@ if (isInstalled()) {
                                                }
 
                                                // Add header
-                                               LOAD_INC_ONCE("inc/header.php");
+                                               LOAD_INC_ONCE('inc/header.php');
 
                                                // Was that mail a valid one?
                                                if ($isValid === true) {
                                                        // If time is zero seconds we have a sponsor mail. 1 Second shall be set to avoid problems
-                                                       if (($time == "0") && ($payment > 0)) { $URL = constant('URL'); $time = "1"; }
+                                                       if (($time == '0') && ($payment > 0)) { $URL = constant('URL'); $time = '1'; }
                                                        if (($time > 0) && (($payment > 0) || ($points > 0))) {
                                                                // He can confirm this mail!
                                                                // Export data into constants for the template
@@ -169,7 +169,7 @@ if (isInstalled()) {
                                                                define('_URL_VALUE' , DEREFERER($URL));
 
                                                                // Load template
-                                                               LOAD_TEMPLATE("mailid_frames");
+                                                               LOAD_TEMPLATE('mailid_frames');
                                                        } else {
                                                                $msg = getCode('DATA_INVALID');
                                                        }
@@ -199,26 +199,26 @@ if (isInstalled()) {
        // Error code is set?
        if (!empty($msg)) {
                switch (getConfig('mailid_error_redirect')) {
-                       case "INDEX": // Redirect to index page
-                               LOAD_URL("modules.php?module=index&amp;msg=".$msg."&amp;ext=mailid");
+                       case 'INDEX': // Redirect to index page
+                               LOAD_URL('modules.php?module=index&amp;msg='.$msg.'&amp;ext=mailid');
                                break;
 
-                       case "REJECT": // Redirect to rejection page
+                       case 'REJECT': // Redirect to rejection page
                                LOAD_CONFIGURED_URL('reject_url');
                                break;
 
                        default:
                                DEBUG_LOG(__FILE__, __LINE__, sprintf("Unknown status %s detected in mailid_error_redirect.", getConfig('mailid_error_redirect')));
-                               LOAD_URL("modules.php?module=index&amp;msg=".getCode('UNKNOWN_STATUS')."&amp;ext=mailid");
+                               LOAD_URL('modules.php?module=index&amp;msg=' . getCode('UNKNOWN_STATUS') . '&amp;ext=mailid');
                                break;
                }
        } else {
                // Include footer
-               LOAD_INC_ONCE("inc/footer.php");
+               LOAD_INC_ONCE('inc/footer.php');
        }
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Shutdown
index 572b59acc05700f30b858ff709d91116153e1910..04f65fbea750cd390375a00d9c46b087e1ca957a 100644 (file)
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Tell everyone we are in this module
-$GLOBALS['module'] = "mailid"; 
+$GLOBALS['module'] = 'mailid';
 $GLOBALS['output_mode'] = 0;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 if (isInstalled()) {
        // Is the extension active
-       if (!EXT_IS_ACTIVE("mailid", true)) {
+       if (!EXT_IS_ACTIVE('mailid', true)) {
                // Is not activated/installed yet!
-               addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "mailid");
+               addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'mailid');
        } // END - if
 
        // Secure all data
-       $url_uid = 0; $url_bid = 0; $url_mid = 0; $code = 0; $mode = "";
-       if (REQUEST_ISSET_GET(('uid')))     $url_uid = bigintval(REQUEST_GET('uid'));
-       if (REQUEST_ISSET_GET(('mailid')))  $url_mid = bigintval(REQUEST_GET('mailid'));
-       if (REQUEST_ISSET_GET(('bonusid'))) $url_bid = bigintval(REQUEST_GET('bonusid'));
-       if (REQUEST_ISSET_GET(('code')))    $code    = bigintval(REQUEST_GET('code'));
-       if (REQUEST_ISSET_GET(('mode')))    $mode    = REQUEST_GET('mode');
+       $url_uid = 0; $url_bid = 0; $url_mid = 0; $code = 0; $mode = '';
+       if (REQUEST_ISSET_GET('uid'))     $url_uid = bigintval(REQUEST_GET('uid'));
+       if (REQUEST_ISSET_GET('mailid'))  $url_mid = bigintval(REQUEST_GET('mailid'));
+       if (REQUEST_ISSET_GET('bonusid')) $url_bid = bigintval(REQUEST_GET('bonusid'));
+       if (REQUEST_ISSET_GET('code'))    $code    = bigintval(REQUEST_GET('code'));
+       if (REQUEST_ISSET_GET('mode'))    $mode    = REQUEST_GET('mode');
 
        // 01        1        12            2    2            21    1                   22     10
        if (($url_uid) > 0 && (($url_mid > 0) || ($url_bid > 0)) && (getTotalFatalErrors() == 0)) {
                // No image? Then output header
-               if ($mode != "img") LOAD_INC_ONCE("inc/header.php");
+               if ($mode != 'img') LOAD_INC_ONCE('inc/header.php');
 
                // Maybe he wants to confirm an email?
                if ($url_mid > 0) {
                        $result = SQL_QUERY_ESC("SELECT id, link_type FROM `{!_MYSQL_PREFIX!}_user_links` WHERE stats_id=%s AND userid=%s LIMIT 1",
                         array($url_mid, $url_uid), __FILE__, __LINE__);
-                       $type = "mailid"; $urlId = $url_mid;
-               } elseif ($url_bid > 0)         {
+                       $type = 'mailid'; $urlId = $url_mid;
+               } elseif ($url_bid > 0) {
                        $result = SQL_QUERY_ESC("SELECT id, link_type FROM `{!_MYSQL_PREFIX!}_user_links` WHERE bonus_id=%s AND userid=%s LIMIT 1",
                         array($url_bid, $url_uid), __FILE__, __LINE__);
-                       $type = "bonusid"; $urlId = $url_bid;
+                       $type = 'bonusid'; $urlId = $url_bid;
                }
 
                if (SQL_NUMROWS($result) == 1) {
@@ -87,12 +87,12 @@ if (isInstalled()) {
                        SQL_FREERESULT($result);
                        switch ($ltype)
                        {
-                       case "NORMAL":
+                       case 'NORMAL':
                                $result_mailid = SQL_QUERY_ESC("SELECT pool_id, userid, id FROM `{!_MYSQL_PREFIX!}_user_stats` WHERE id=%s LIMIT 1",
                                        array($url_mid), __FILE__, __LINE__);
                                break;
 
-                       case "BONUS":
+                       case 'BONUS':
                                $result_mailid = SQL_QUERY_ESC("SELECT id, id, is_notify FROM `{!_MYSQL_PREFIX!}_bonus` WHERE id=%s LIMIT 1",
                                        array($url_bid), __FILE__, __LINE__);
                                break;
@@ -104,13 +104,13 @@ if (isInstalled()) {
                                list($pool, $sender, $notify) = SQL_FETCHROW($result_mailid);
 
                                // Correct notification switch in non-bonus mails
-                               if (($notify != "Y") && ($notify != "N")) $notify = "N";
+                               if (($notify != 'Y') && ($notify != 'N')) $notify = 'N';
 
                                // Free some memory
                                SQL_FREERESULT($result_mailid);
 
                                // Set sender to 0 when we have a bonus mail
-                               if ($ltype == "BONUS") $sender = 0;
+                               if ($ltype == 'BONUS') $sender = 0;
 
                                // Is the user's ID unlocked?
                                $result = SQL_QUERY_ESC("SELECT status, gender, surname, family, ref_payout FROM `{!_MYSQL_PREFIX!}_user_data` WHERE userid=%s LIMIT 1",
@@ -122,7 +122,7 @@ if (isInstalled()) {
                                        // Free some memory
                                        SQL_FREERESULT($result);
 
-                                       if ($status == "CONFIRMED") {
+                                       if ($status == 'CONFIRMED') {
                                                // Update last activity
                                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET last_online=UNIX_TIMESTAMP(), `last_module`='mailid_top' WHERE userid=%s LIMIT 1",
                                                        array($url_uid), __FILE__, __LINE__);
@@ -130,15 +130,15 @@ if (isInstalled()) {
                                                // User has confirmed his account so we can procede...
                                                switch ($ltype)
                                                {
-                                               case "NORMAL":
+                                               case 'NORMAL':
                                                        $result = SQL_QUERY_ESC("SELECT payment_id FROM `{!_MYSQL_PREFIX!}_user_stats` WHERE pool_id=%s LIMIT 1",
                                                                array(bigintval($pool)), __FILE__, __LINE__);
 
                                                        // Entry found?
                                                        if (SQL_NUMROWS($result) == 1) {
                                                                list($pay) = SQL_FETCHROW($result);
-                                                               $time      = GET_PAY_POINTS($pay, "time");
-                                                               $payment   = GET_PAY_POINTS($pay, "payment");
+                                                               $time      = GET_PAY_POINTS($pay, 'time');
+                                                               $payment   = GET_PAY_POINTS($pay, 'payment');
                                                                $isValid   = true;
                                                        } // END - if
 
@@ -146,7 +146,7 @@ if (isInstalled()) {
                                                        SQL_FREERESULT($result);
                                                        break;
 
-                                               case "BONUS":
+                                               case 'BONUS':
                                                        $result = SQL_QUERY_ESC("SELECT time, points FROM `{!_MYSQL_PREFIX!}_bonus` WHERE id=%s LIMIT 1",
                                                                array(bigintval($pool)), __FILE__, __LINE__);
 
@@ -163,7 +163,7 @@ if (isInstalled()) {
 
                                                // Is this entry valid?
                                                if ($isValid) {
-                                                       if (($time == "0") && ($payment > 0)) $time = "1";
+                                                       if (($time == '0') && ($payment > 0)) $time = '1';
                                                        if (($time > 0) && ($payment > 0)) {
                                                                if (!empty($code)) {
                                                                        // Generate code
@@ -171,33 +171,33 @@ if (isInstalled()) {
                                                                } // END - if
 
                                                                switch ($mode) {
-                                                               case "add":
+                                                               case 'add':
                                                                        // Init stats data
                                                                        $stats_data = 0;
 
                                                                        // Count clicks
                                                                        switch ($ltype)
                                                                        {
-                                                                       case "NORMAL":
+                                                                       case 'NORMAL':
                                                                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_stats` SET clicks=clicks + 1 WHERE id=%s LIMIT 1",
                                                                                        array($url_mid), __FILE__, __LINE__);
 
                                                                                // Update mediadata as well
-                                                                               if (GET_EXT_VERSION("mediadata") >= "0.0.4") {
+                                                                               if (GET_EXT_VERSION('mediadata') >= '0.0.4') {
                                                                                        // Update database
-                                                                                       MEDIA_UPDATE_ENTRY(array("total_clicks", "normal_clicks"), "add", 1);
+                                                                                       MEDIA_UPDATE_ENTRY(array('total_clicks', 'normal_clicks'), 'add', 1);
                                                                                }
                                                                                $stats_data = $url_mid;
                                                                                break;
 
-                                                                       case "BONUS":
+                                                                       case 'BONUS':
                                                                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_bonus` SET clicks=clicks + 1 WHERE id=%s LIMIT 1",
                                                                                        array($url_bid), __FILE__, __LINE__);
 
                                                                                // Update mediadata as well
-                                                                               if (GET_EXT_VERSION("mediadata") >= "0.0.4") {
+                                                                               if (GET_EXT_VERSION('mediadata') >= '0.0.4') {
                                                                                        // Update database
-                                                                                       MEDIA_UPDATE_ENTRY(array("total_clicks", "bonus_clicks"), "add", 1);
+                                                                                       MEDIA_UPDATE_ENTRY(array('total_clicks', 'bonus_clicks'), 'add', 1);
                                                                                }
                                                                                $stats_data = $url_bid;
                                                                                break;
@@ -205,19 +205,19 @@ if (isInstalled()) {
 
                                                                        // Export data into constants for the template
                                                                        define('_POINTS_VALUE'   , TRANSLATE_COMMA($payment));
-                                                                       define('_TEMPLATE_BANNER', LOAD_TEMPLATE("mailid_banner", true));
+                                                                       define('_TEMPLATE_BANNER', LOAD_TEMPLATE('mailid_banner', true));
 
                                                                        // Only when user extension = v0.1.2: Update mails-confirmed counter
                                                                        // @TODO Rewrite these blocks to filter
-                                                                       if (GET_EXT_VERSION("user") >= "0.1.2") {
+                                                                       if (GET_EXT_VERSION('user') >= '0.1.2') {
                                                                                // Update counter
                                                                                SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET mails_confirmed=mails_confirmed + 1 WHERE userid=%s LIMIT 1",
                                                                                        array($url_uid), __FILE__, __LINE__);
 
                                                                                // Update random confirmed as well?
-                                                                               if (GET_EXT_VERSION("user") >= "0.3.4") {
+                                                                               if (GET_EXT_VERSION('user') >= '0.3.4') {
                                                                                        // Update second counter
-                                                                                       SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET rand_confirmed=rand_confirmed + 1 WHERE userid=%s LIMIT 1",
+                                                                                       SQL_QUERY_ESC(OB"UPDATE `{!_MYSQL_PREFIX!}_user_data` SET rand_confirmed=rand_confirmed + 1 WHERE userid=%s LIMIT 1",
                                                                                                array($url_uid), __FILE__, __LINE__);
                                                                                } // END - if
                                                                        } // END - if
@@ -229,13 +229,13 @@ if (isInstalled()) {
                                                                        if (bigintval(REQUEST_POST('gfx_check')) == $img_code) {
                                                                                // Add points over referal system is the default
                                                                                $locked = false;
-                                                                               $template = "mailid_points_done";
+                                                                               $template = 'mailid_points_done';
 
                                                                                // Right code entered add points and remove entry
-                                                                               if (($ref_pay > 0) && (getConfig('allow_direct_pay') != "Y")) {
+                                                                               if (($ref_pay > 0) && (getConfig('allow_direct_pay') != 'Y')) {
                                                                                        // Don't add points over the referal system
                                                                                        $locked = true;
-                                                                                       $template = "mailid_points_locked";
+                                                                                       $template = 'mailid_points_locked';
                                                                                } // END - if
 
                                                                                // Count down ref_payout value
@@ -244,20 +244,20 @@ if (isInstalled()) {
 
                                                                                // Add points
                                                                                unset($GLOBALS['ref_level']);
-                                                                               ADD_POINTS_REFSYSTEM("mailid_okay", $url_uid, $payment, false, "0", $locked);
+                                                                               ADD_POINTS_REFSYSTEM('mailid_okay', $url_uid, $payment, false, '0', $locked);
 
                                                                                // Shall I add bonus points for "turbo clickers" ?
-                                                                               if (GET_EXT_VERSION("bonus") >= "0.2.2") {
+                                                                               if (GET_EXT_VERSION('bonus') >= '0.2.2') {
                                                                                        // Is an active-rallye running and this is not a notification mail?
-                                                                                       if ((getConfig('bonus_active') == "Y") && ($notify == "N")) {
+                                                                                       if ((getConfig('bonus_active') == 'Y') && ($notify == 'N')) {
                                                                                                // Shall I exclude the webmaster's own userid from the active-rallye?
-                                                                                               if ((((getConfig('bonus_uid') == $url_uid) && (getConfig('bonus_include_own') == "Y")) || (getConfig('bonus_uid') != $url_uid)) && (getConfig('def_refid') != $url_uid)) {
+                                                                                               if ((((getConfig('bonus_uid') == $url_uid) && (getConfig('bonus_include_own') == 'Y')) || (getConfig('bonus_uid') != $url_uid)) && (getConfig('def_refid') != $url_uid)) {
                                                                                                        // Add points and remember ranking are done in this function....
                                                                                                        BONUS_ADD_TURBO_POINTS($urlId, $url_uid, $type);
 
                                                                                                        // Set template to mailid_points_done2 which contains a link to the ranking list
-                                                                                                       $template = "mailid_points_done2";
-                                                                                                       if ($locked) $template = "mailid_points_locked2";
+                                                                                                       $template = 'mailid_points_done2';
+                                                                                                       if ($locked) $template = 'mailid_points_locked2';
                                                                                                        define('_UID_VALUE' , $url_uid);
                                                                                                        define('_TYPE_VALUE', $type);
                                                                                                        define('_DATA_VALUE', TRANSLATE_COMMA($urlId));
@@ -267,8 +267,8 @@ if (isInstalled()) {
 
                                                                                // Load total points
                                                                                define('__TOTAL_POINTS', TRANSLATE_COMMA(
-                                                                                       GET_TOTAL_DATA($url_uid, "user_points", "points") -
-                                                                                       GET_TOTAL_DATA($url_uid, "user_data", "used_points"))
+                                                                                       GET_TOTAL_DATA($url_uid, 'user_points', 'points') -
+                                                                                       GET_TOTAL_DATA($url_uid, 'user_data', 'used_points'))
                                                                                );
 
                                                                                // Load template
@@ -276,10 +276,10 @@ if (isInstalled()) {
                                                                        } else {
                                                                                // Wrong image code! So add points to sender's account
                                                                                unset($GLOBALS['ref_level']);
-                                                                               ADD_POINTS_REFSYSTEM("mailid_payback", $sender, $payment, false, 0, false, "direct");
+                                                                               ADD_POINTS_REFSYSTEM('mailid_payback', $sender, $payment, false, 0, false, 'direct');
 
                                                                                // Load template
-                                                                               LOAD_TEMPLATE("mailid_points_failed");
+                                                                               LOAD_TEMPLATE('mailid_points_failed');
                                                                        }
 
                                                                        // Remove link from table
@@ -287,26 +287,26 @@ if (isInstalled()) {
                                                                                array(bigintval($lid)), __FILE__, __LINE__);
                                                                        break;
 
-                                                               case "img":
+                                                               case 'img':
                                                                        GENERATE_IMAGE($img_code);
                                                                        break;
 
-                                                               case "confirm":
+                                                               case 'confirm':
                                                                        if ($code > 0) {
                                                                                // Export data into constants for the template
                                                                                define('_CODE_VALUE', $code);
                                                                                define('_UID_VALUE' , $url_uid );
                                                                                define('_TYPE_VALUE', $type);
                                                                                define('_DATA_VALUE', $urlId);
-                                                                               define('_TEMPLATE_BANNER', LOAD_TEMPLATE("mailid_banner", true));
+                                                                               define('_TEMPLATE_BANNER', LOAD_TEMPLATE('mailid_banner', true));
                                                                                if (getConfig('code_length') > 0) {
                                                                                        // Generate Code
                                                                                        define('_IMAGE_CODE', IMG_CODE($code, $type, $urlId, $url_uid));
-                                                                                       $templ = "mailid_enter_code";
+                                                                                       $templ = 'mailid_enter_code';
                                                                                } else {
                                                                                        // Disabled code
                                                                                        define('__GFX_CODE', $img_code);
-                                                                                       $templ = "mailid_confirm_buttom";
+                                                                                       $templ = 'mailid_confirm_buttom';
                                                                                }
 
                                                                                // Load template
@@ -314,7 +314,7 @@ if (isInstalled()) {
                                                                        }
                                                                        break;
 
-                                                               case "":
+                                                               case '':
                                                                        // Ok, all data is valid and loaded. Finally let's output the timer... :-)
                                                                        // Export data into constants for the template
                                                                        define('_TIME_VALUE', $time);
@@ -323,43 +323,43 @@ if (isInstalled()) {
                                                                        define('_TYPE_VALUE', $type);
                                                                        define('_DATA_VALUE', $urlId);
                                                                        define('_RAND_VALUE', mt_rand(0, 99999));
-                                                                       define('_TEMPLATE_BANNER', LOAD_TEMPLATE("mailid_banner", true));
+                                                                       define('_TEMPLATE_BANNER', LOAD_TEMPLATE('mailid_banner', true));
 
                                                                        // Load template
-                                                                       LOAD_TEMPLATE("mailid_timer");
+                                                                       LOAD_TEMPLATE('mailid_timer');
                                                                        break;
                                                                } // END - switch
                                                        } else {
-                                                               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (6)</div>");
+                                                               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (6)</div>");
                                                        }
                                                } else {
-                                                       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (5)</div>");
+                                                       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (5)</div>");
                                                }
                                        } else {
-                                               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (4)</div>");
+                                               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (4)</div>");
                                        }
                                } else {
                                        SQL_FREERESULT($result);
-                                       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (3)</div>");
+                                       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (3)</div>");
                                }
                        } else {
                                SQL_FREERESULT($result);
-                               LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (2)</div>");
+                               LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (2)</div>");
                        }
                } else {
                        SQL_FREERESULT($result);
-                       LOAD_TEMPLATE("admin_settings_saved", false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (1)</div>");
+                       LOAD_TEMPLATE('admin_settings_saved', false, "<div class=\"member_failed\">{--MAIL_ALREADY_CONFIRMED--} (1)</div>");
                }
 
                // Insert footer if no image
-               if ($mode != "img") {
+               if ($mode != 'img') {
                        // Write footer
-                       LOAD_INC_ONCE("inc/footer.php");
+                       LOAD_INC_ONCE('inc/footer.php');
                } // END - if
        }
-} elseif ($mode != "img") {
+} elseif ($mode != 'img') {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
index ae7948fe925fecc02de1fd34cbee5d45cf6cb9ab..f079d6e11a47819e032cad62f379c14bbffc82a9 100644 (file)
 //xdebug_start_trace();
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
 $GLOBALS['startTime'] = microtime(true);
 $GLOBALS['output_mode'] = 0;
-$GLOBALS['what']   = "";
-$GLOBALS['action'] = "";
-$GLOBALS['module'] = "";
+$GLOBALS['what']   = '';
+$GLOBALS['action'] = '';
+$GLOBALS['module'] = '';
 
 // Needed include files
-require("inc/config.php");
+require('inc/config.php');
 
-// Fix missing module to "index"
-if (!REQUEST_ISSET_GET(('module'))) REQUEST_SET_GET('module', "index");
+// Fix missing module to 'index'
+if (!REQUEST_ISSET_GET('module')) REQUEST_SET_GET('module', 'index');
 
 // Check if logged in
 if (IS_MEMBER()) {
@@ -63,16 +63,16 @@ if (IS_MEMBER()) {
        if (SQL_NUMROWS($result) == 1) {
                // Load surname and family's name and build the username
                list($s, $f) = SQL_FETCHROW($result);
-               $username = $s." ".$f;
+               $username = $s.' '.$f;
 
                // Additionally admin?
                if (IS_ADMIN()) {
                        // Add it
-                       $username .= " ({--_ADMIN_SHORT--})";
+                       $username .= ' ({--_ADMIN_SHORT--})';
                } // END - if
        } else {
                // Hmmm, logged in and no valid userid?
-               $username = "<em>{--_UNKNOWN--}</em>";
+               $username = '<em>{--_UNKNOWN--}</em>';
 
                // Destroy session
                destroy_user_session();
@@ -92,11 +92,11 @@ if (IS_MEMBER()) {
 }
 
 // The header file
-LOAD_INC_ONCE("inc/header.php");
+LOAD_INC_ONCE('inc/header.php');
 
 // Modules are by default not valid!
-$MOD_VALID = false; $check = "failed";
-if ((getConfig('maintenance') == "Y") && (!IS_ADMIN()) && ($GLOBALS['module'] != "admin")) {
+$MOD_VALID = false; $check = 'failed';
+if ((getConfig('maintenance') == 'Y') && (!IS_ADMIN()) && ($GLOBALS['module'] != 'admin')) {
        // Maintain mode is active and you are no admin
        addFatalMessage(__FILE__, __LINE__, getMessage('LANG_DOWN_MAINTAINCE'));
 } elseif ((SQL_IS_LINK_UP()) && (getTotalFatalErrors() == 0)) {
@@ -107,9 +107,9 @@ if ((getConfig('maintenance') == "Y") && (!IS_ADMIN()) && ($GLOBALS['module'] !=
        $check = checkModulePermissions($GLOBALS['module']);
        switch ($check)
        {
-       case "admin_only":
-       case "mem_only":
-       case "done":
+       case 'admin_only':
+       case 'mem_only':
+       case 'done':
                // Does the module exists on local file system?
                if ((FILE_READABLE(constant('__MODULE'))) && (getTotalFatalErrors() == 0)) {
                        // Module is valid, active and located on the local disc...
@@ -122,11 +122,11 @@ if ((getConfig('maintenance') == "Y") && (!IS_ADMIN()) && ($GLOBALS['module'] !=
                }
                break;
 
-       case "404":
+       case '404':
                addFatalMessage(__FILE__, __LINE__, sprintf(getMessage('LANG_MOD_REG_404'), $GLOBALS['module']));
                break;
 
-       case "locked":
+       case 'locked':
                if (!FILE_READABLE(constant('__MODULE'))) {
                        // Module does addionally not exists
                        addFatalMessage(__FILE__, __LINE__, sprintf(getMessage('LANG_MOD_REG_404'), $GLOBALS['module']));
@@ -156,7 +156,7 @@ if (($MOD_VALID) && (defined('__MODULE'))) {
 } // END - if
 
 // Next-to-end add the footer
-LOAD_INC_ONCE("inc/footer.php");
+LOAD_INC_ONCE('inc/footer.php');
 
 //
 ?>
diff --git a/ref.php b/ref.php
index f71fae3686cc16ed2007f15a1331a24e9c9026fe..91274c2382b19c819afa410057adbb5fb15dd25b 100644 (file)
--- a/ref.php
+++ b/ref.php
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "ref";
+$GLOBALS['module'] = 'ref';
 $GLOBALS['output_mode'] = -1;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Redirect only to registration page when this script is installed
 if (isInstalled()) {
        // Base URL for redirection
        switch (getConfig('refid_target'))
        {
-       case "register":
-               $URL = "modules.php?module=index&amp;what=register&amp;refid=";
+       case 'register':
+               $URL = 'modules.php?module=index&amp;what=register&amp;refid=';
                break;
 
-       case "index":
-               $URL = "index.php?refid=";
+       case 'index':
+               $URL = 'index.php?refid=';
                break;
        }
 
@@ -70,8 +70,8 @@ if (isInstalled()) {
 
        if (!empty($ref)) {
                // Test if nickname or numeric id
-               if ($ref != "".($ref + 0)."") {
-                       if (EXT_IS_ACTIVE("nickname")) {
+               if ($ref != ''.($ref + 0).'') {
+                       if (EXT_IS_ACTIVE('nickname')) {
                                // Nickname in URL, so load the ID
                                $result = SQL_QUERY_ESC("SELECT userid FROM `{!_MYSQL_PREFIX!}_user_data` WHERE nickname='%s' LIMIT 1",
                                        array($ref), __FILE__, __LINE__);
@@ -104,14 +104,14 @@ if (isInstalled()) {
                } // END - if
        } else {
                // No refid and we add our refid (don't forget to set $def_refid!)
-               $URL = "index.php";
+               $URL = 'index.php';
        }
 
        // Load the URL
        LOAD_URL($URL);
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
index 968967b23f1e20da8df93d80028e905508610cd1..c41dc5b5cd2bd73602232b0d9d2db76dcb24955b 100644 (file)
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
 $GLOBALS['startTime'] = microtime(true);
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set this because we have no module in URI
-$GLOBALS['module'] = "show_bonus";
+$GLOBALS['module'] = 'show_bonus';
 $GLOBALS['output_mode'] = 0;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
-// Is the "bonus" extension active?
-REDIRECT_ON_UNINSTALLED_EXTENSION("bonus");
+// Is the 'bonus' extension active?
+REDIRECT_ON_UNINSTALLED_EXTENSION('bonus');
 
 // List only rankings when script is installed
 if (isInstalled()) {
        // Include header
-       LOAD_INC("inc/header.php");
+       LOAD_INC('inc/header.php');
 
        if ((REQUEST_GET('uid') > 0) && (REQUEST_GET('d') > 0) && (REQUEST_ISSET_GET(('t')))) {
                // Set row name
-               $t = "";
+               $t = '';
                switch (REQUEST_GET('t')) {
-                       case "bonusid": // Bonus mail
-                               $t = "bonus_id";
+                       case 'bonusid': // Bonus mail
+                               $t = 'bonus_id';
                                break;
 
-                       case "mailid": // Regular member mail
-                               $t = "mail_id";
+                       case 'mailid': // Regular member mail
+                               $t = 'mail_id';
                                break;
 
                        default: // Invalid type
@@ -105,7 +105,7 @@ LIMIT 1",
                                //   __YOUR_RANKING_LINE
 
                                // Load pre-template
-                               define('__BONUS_MSG', LOAD_TEMPLATE("show_bonus_msg", true));
+                               define('__BONUS_MSG', LOAD_TEMPLATE('show_bonus_msg', true));
                        } else {
                                // No data found
                                define('__BONUS_MSG', "<span class=\"guest_failed\">{--BONUS_SHOW_NO_DATA--}</span>");
@@ -123,22 +123,22 @@ LIMIT 1",
        }
 
        // Load send_bonus header template (for your banners, e.g.?)
-       define('__BONUS_HEADER', LOAD_TEMPLATE("show_bonus_header", true));
+       define('__BONUS_HEADER', LOAD_TEMPLATE('show_bonus_header', true));
 
        // Load show_bonus footer template (for your banners, e.g.?)
-       define('__BONUS_FOOTER', LOAD_TEMPLATE("show_bonus_footer", true));
+       define('__BONUS_FOOTER', LOAD_TEMPLATE('show_bonus_footer', true));
 
        // Total ranks who can win
        define('__BONUS_TOTAL_RANKS', getConfig('bonus_ranks'));
 
        // Load final template
-       LOAD_TEMPLATE("show_bonus");
+       LOAD_TEMPLATE('show_bonus');
 
        // Include footer
-       LOAD_INC("inc/footer.php");
+       LOAD_INC('inc/footer.php');
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
index 5906d8893d7ec0cfb73baefdf3eb858ff119ba3e..a93348c753e9c177b69b682a8f2269462adb603e 100644 (file)
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "sponsor_confirm";
+$GLOBALS['module'] = 'sponsor_confirm';
 
-// Set "CSS-Mode"
-$GLOBALS['output_mode'] = "0";
+// Set 'CSS-Mode'
+$GLOBALS['output_mode'] = '0';
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Is the script installed?
 if (isInstalled()) {
        // Base URL for redirection
-       $URL = "modules.php?module=index&amp;what=sponsor_login&amp;hash=";
+       $URL = 'modules.php?module=index&amp;what=sponsor_login&amp;hash=';
        if (!REQUEST_ISSET_GET(('hash'))) {
                // No refid and we add our refid (don't forget to set $def_refid!)
-               $URL = "modules.php?module=index";
+               $URL = 'modules.php?module=index';
        } else {
                // We have an refid here. So we simply add it
                $URL .= REQUEST_GET(('hash'));
@@ -67,7 +67,7 @@ if (isInstalled()) {
        LOAD_URL($URL);
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
index ee538e5f0ef45b186fc234de9013fb9ffa3b2dfd..1f9a3eec0a9482264242f69f632223e54c20f143 100644 (file)
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = ""; $GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "sponsor_ref";
+$GLOBALS['module'] = 'sponsor_ref';
 
-// Set "CSS-Mode"
-$GLOBALS['output_mode'] = "0";
+// Set 'CSS-Mode'
+$GLOBALS['output_mode'] = '0';
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Redirect only to registration page when this script is installed
 if (isInstalled()) {
        // Base URL for redirection
-       $URL = "modules.php?module=index&amp;what=sponsor_reg&amp;refid=";
+       $URL = 'modules.php?module=index&amp;what=sponsor_reg&amp;refid=';
 
        // Get referal ID from ref or refid variable
        $ref = 0;
@@ -65,14 +66,14 @@ if (isInstalled()) {
                $URL .= $ref;
        } else {
                // No refid so we redirect to the index page
-               $URL = "index.php";
+               $URL = 'index.php';
        }
 
        // Load the URL
        LOAD_URL($URL);
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
index adfa099fe0d94abc9b67ca2a536e15943c804c72..13e583ca25841ef4905b584a53d63698c7132a0d 100644 (file)
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
 $GLOBALS['cache_array']['surfbar'] = array();
 $GLOBALS['startTime'] = microtime(true);
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "surfbar";
+$GLOBALS['module'] = 'surfbar';
 $GLOBALS['refid']  = 0;
 $GLOBALS['output_mode'] = 0;
 $msg = null;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 // Is the script installed?
 if (isInstalled()) {
        // Only logged in users may use this surfbar!
-       REDIRECT_ON_UNINSTALLED_EXTENSION("surfbar");
+       REDIRECT_ON_UNINSTALLED_EXTENSION('surfbar');
 
        // No member?
        if (!IS_MEMBER()) {
                // Redirect
                // @TODO Display quick login form here or redirect as configured
-               LOAD_URL("modules.php?module=index");
+               LOAD_URL('modules.php?module=index');
        } // END - if
 
        // Handle tasks on self-maintenance
        SURFBAR_HANDLE_SELF_MAINTENANCE();
 
        // Is there a check value?
-       if ((SURFBAR_CHECK_RELOAD_FULL()) || ((REQUEST_ISSET_GET(('frame'))) && (in_array(REQUEST_GET('frame'), array("stop", "stop2", "stats", "textlinks"))))) {
+       if ((SURFBAR_CHECK_RELOAD_FULL()) || ((REQUEST_ISSET_GET(('frame'))) && (in_array(REQUEST_GET('frame'), array('stop', 'stop2', 'stats', 'textlinks'))))) {
                // Reload-lock is full, surfbar stopped so...
                // Load header
-               LOAD_INC_ONCE("inc/header.php");
+               LOAD_INC_ONCE('inc/header.php');
 
                // Load template
-               if (((REQUEST_ISSET_GET(('frame'))) && (REQUEST_GET('frame') == "stop")) || (!REQUEST_ISSET_GET(('frame')))) {
+               if (((REQUEST_ISSET_GET(('frame'))) && (REQUEST_GET('frame') == 'stop')) || (!REQUEST_ISSET_GET(('frame')))) {
                        // Load template for "start" page
-                       LOAD_TEMPLATE("surfbar_frame_start");
+                       LOAD_TEMPLATE('surfbar_frame_start');
 
                        // Load banner
-                       LOAD_TEMPLATE("surfbar_start_banner");
+                       LOAD_TEMPLATE('surfbar_start_banner');
 
                        // This makes the footer appear again
                        REQUEST_UNSET_GET(('frame'));
-               } elseif ((REQUEST_ISSET_GET(('frame'))) && (REQUEST_GET('frame') == "stats")) {
+               } elseif ((REQUEST_ISSET_GET(('frame'))) && (REQUEST_GET('frame') == 'stats')) {
                        // Get total points amount
-                       $points = GET_TOTAL_DATA(getUserId(), "user_points", "points") - GET_TOTAL_DATA(getUserId(), "user_data", "used_points");
+                       $points = GET_TOTAL_DATA(getUserId(), 'user_points', 'points') - GET_TOTAL_DATA(getUserId(), 'user_data', 'used_points');
 
                        // Prepare content
                        $content = array(
@@ -102,8 +102,8 @@ if (isInstalled()) {
                        );
 
                        // Load template for "stats" page
-                       LOAD_TEMPLATE("surfbar_frame_stats", false, $content);
-               } elseif ((REQUEST_ISSET_GET(('frame'))) && (REQUEST_GET('frame') == "textlinks")) {
+                       LOAD_TEMPLATE('surfbar_frame_stats', false, $content);
+               } elseif ((REQUEST_ISSET_GET(('frame'))) && (REQUEST_GET('frame') == 'textlinks')) {
                        // Prepare content
                        $content = array(
                                'online'   => SURFBAR_DETERMINE_TOTAL_ONLINE(),
@@ -111,17 +111,17 @@ if (isInstalled()) {
                        );
 
                        // Load template for "stats" page
-                       LOAD_TEMPLATE("surfbar_frame_textlinks", false, $content);
+                       LOAD_TEMPLATE('surfbar_frame_textlinks', false, $content);
                } else {
                        // Prepare content
                        $content = array(
                                'restart'   => getConfig('surfbar_restart_time'),
-                               'start'     => str_repeat("X", strlen(getConfig('surfbar_restart_time'))),
-                               'autostart' => (getConfig('surfbar_autostart') == "Y") ? "true" : "false"
+                               'start'     => str_repeat('X', strlen(getConfig('surfbar_restart_time'))),
+                               'autostart' => (getConfig('surfbar_autostart') == 'Y') ? 'true' : 'false'
                        );
 
                        // Load template for stopped surfbar
-                       LOAD_TEMPLATE("surfbar_stopped", false, $content);
+                       LOAD_TEMPLATE('surfbar_stopped', false, $content);
                }
        } elseif ((REQUEST_ISSET_GET(('check'))) && (REQUEST_ISSET_GET(('id'))) && (REQUEST_ISSET_GET(('salt')))) {
                // Dummy next id get
@@ -149,13 +149,13 @@ if (isInstalled()) {
                $GLOBALS['footer_sent'] = 1;
        } else {
                // Prepare content
-               $content = "";
+               $content = '';
 
                // Determine template name
                $templateName = SURFBAR_DETERMINE_TEMPLATE_NAME();
 
                // Frame "top" set?
-               if ((REQUEST_ISSET_GET(('frame'))) && (REQUEST_GET('frame') == "top")) {
+               if ((REQUEST_ISSET_GET(('frame'))) && (REQUEST_GET('frame') == 'top')) {
                        // Determine next id
                        $nextId = SURFBAR_DETERMINE_NEXT_ID();
 
@@ -171,16 +171,16 @@ if (isInstalled()) {
                                        'curr_reload' => SURFBAR_GET_USER_LOCKS(),
                                        'max_urls'    => SURFBAR_GET_TOTAL_URLS(),
                                        'reload'      => SURFBAR_GET_RELOAD_TIME($nextId),
-                                       'xxx'         => str_repeat("X", strlen(SURFBAR_GET_RELOAD_TIME($nextId)))
+                                       'xxx'         => str_repeat('X', strlen(SURFBAR_GET_RELOAD_TIME($nextId)))
                                );
 
                                // Update salt (double-call lock!) and statistics
                                SURFBAR_UPDATE_SALT_STATS();
                        } else {
                                // Load new URL
-                               SURFBAR_RELOAD_TO_STOP_PAGE("stop2");
+                               SURFBAR_RELOAD_TO_STOP_PAGE('stop2');
                        }
-               } elseif ((REQUEST_ISSET_GET(('frame'))) && (REQUEST_GET('frame') == "start")) {
+               } elseif ((REQUEST_ISSET_GET(('frame'))) && (REQUEST_GET('frame') == 'start')) {
                        // Starter frame found so let the footer display
                        REQUEST_UNSET_GET(('frame'));
                } else {
@@ -189,7 +189,7 @@ if (isInstalled()) {
                }
 
                // Load header
-               LOAD_INC_ONCE("inc/header.php");
+               LOAD_INC_ONCE('inc/header.php');
 
                // Load that template
                //* DEBUG: */ die("templateName={$templateName}<br />\n<strong>content</strong>=<pre>".print_r($content, true)."</pre>");
@@ -197,10 +197,10 @@ if (isInstalled()) {
        }
 
        // Load footer
-       LOAD_INC_ONCE("inc/footer.php");
+       LOAD_INC_ONCE('inc/footer.php');
 } else {
        // You have to install first!
-       LOAD_URL("install.php");
+       LOAD_URL('install.php');
 }
 
 // Really all done here... ;-)
index a90427ac0e414d4c77c1f87b511c333eb6bf66bb..843d681f5236b33ec9a2922f679280dec8aeed84 100644 (file)
@@ -46,29 +46,29 @@ if (!defined('__SECURITY')) {
 // Theme definitions
 //
 // The name of your theme
-$GLOBALS['theme_data']['name'] = "Solid-Business";
+$GLOBALS['theme_data']['name'] = 'Solid-Business';
 
 // Only your name please!
-$GLOBALS['theme_data']['author'] = "Roland H&auml;der";
+$GLOBALS['theme_data']['author'] = 'Roland H&auml;der';
 
 // Your email address
-$GLOBALS['theme_data']['email'] = "webmaster@mxchange.org";
+$GLOBALS['theme_data']['email'] = 'webmaster@mxchange.org';
 
 // URL where you have uploaded it
-$GLOBALS['theme_data']['url'] = "http://www.mxchange.org";
+$GLOBALS['theme_data']['url'] = 'http://www.mxchange.org';
 
 // Version number
-$GLOBALS['theme_data']['version'] = "0.0";
+$GLOBALS['theme_data']['version'] = '0.0';
 
 // Switch mode
-if (empty($GLOBALS['theme_mode'])) $GLOBALS['theme_mode'] = "load";
+if (empty($GLOBALS['theme_mode'])) $GLOBALS['theme_mode'] = 'load';
 
 switch ($GLOBALS['theme_mode'])
 {
-case "test": // Do stuff while testing the theme: The admin clicked on "Import"
+case 'test': // Do stuff while testing the theme: The admin clicked on 'Import'
        break;
 
-case "load": // Do stuff while theme is loaded normally
+case 'load': // Do stuff while theme is loaded normally
        break;
 }
 //
index b42cb8ada3f347898318ee9d5dcba0495ff136e1..be4895b935481c5ed9debb7f77b4719f09422c08 100644 (file)
@@ -46,29 +46,29 @@ if (!defined('__SECURITY')) {
 // Theme definitions
 //
 // The name of your theme
-$GLOBALS['theme_data']['name'] = "Standart-Theme";
+$GLOBALS['theme_data']['name'] = 'Standart-Theme';
 
 // Only your name please!
-$GLOBALS['theme_data']['author'] = "Roland H&auml;der";
+$GLOBALS['theme_data']['author'] = 'Roland H&auml;der';
 
 // Your email address
-$GLOBALS['theme_data']['email'] = "webmaster@mxchange.org";
+$GLOBALS['theme_data']['email'] = 'webmaster@mxchange.org';
 
 // URL where you have uploaded it
-$GLOBALS['theme_data']['url'] = "http://www.mxchange.org";
+$GLOBALS['theme_data']['url'] = 'http://www.mxchange.org';
 
 // Version number
-$GLOBALS['theme_data']['version'] = "0.0";
+$GLOBALS['theme_data']['version'] = '0.0';
 
 // Switch mode
-if (empty($GLOBALS['theme_mode'])) $GLOBALS['theme_mode'] = "load";
+if (empty($GLOBALS['theme_mode'])) $GLOBALS['theme_mode'] = 'load';
 
 switch ($GLOBALS['theme_mode'])
 {
-case "test": // Do stuff while testing the theme: The admin clicked on "Import"
+case 'test': // Do stuff while testing the theme: The admin clicked on 'Import'
        break;
 
-case "load": // Do stuff while theme is loaded normally
+case 'load': // Do stuff while theme is loaded normally
        break;
 }
 //
index 55aaa018369b9922d001e2ccff8391d27a3921ce..aad9f6d9c08d21e15a439a91eac35a12284e7179 100644 (file)
@@ -46,29 +46,29 @@ if (!defined('__SECURITY')) {
 // Theme definitions
 //
 // The name of your theme
-$GLOBALS['theme_data']['name'] = "Desert-Storm";
+$GLOBALS['theme_data']['name'] = 'Desert-Storm';
 
 // Only your name please!
-$GLOBALS['theme_data']['author'] = "Roland H&auml;der";
+$GLOBALS['theme_data']['author'] = 'Roland H&auml;der';
 
 // Your email address
-$GLOBALS['theme_data']['email'] = "webmaster@mxchange.org";
+$GLOBALS['theme_data']['email'] = 'webmaster@mxchange.org';
 
 // URL where you have uploaded it
-$GLOBALS['theme_data']['url'] = "http://www.mxchange.org";
+$GLOBALS['theme_data']['url'] = 'http://www.mxchange.org';
 
 // Version number
-$GLOBALS['theme_data']['version'] = "0.0.1";
+$GLOBALS['theme_data']['version'] = '0.0.1';
 
 // Switch mode
-if (empty($GLOBALS['theme_mode'])) $GLOBALS['theme_mode'] = "load";
+if (empty($GLOBALS['theme_mode'])) $GLOBALS['theme_mode'] = 'load';
 
 switch ($GLOBALS['theme_mode'])
 {
-case "test": // Do stuff while testing the theme: The admin clicked on "Import"
+case 'test': // Do stuff while testing the theme: The admin clicked on 'Import'
        break;
 
-case "load": // Do stuff while theme is loaded normally
+case 'load': // Do stuff while theme is loaded normally
        break;
 }
 //
index d379f41dc87ae7a312ff3fd0f877d942157a1e1f..304460de25763f318bdd3acbeace9ffa0efb749b 100644 (file)
--- a/view.php
+++ b/view.php
  ************************************************************************/
 
 // Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
-require("inc/libs/security_functions.php");
+require('inc/libs/security_functions.php');
 
 // Init "action" and "what"
-$GLOBALS['what'] = "";
-$GLOBALS['action'] = "";
+$GLOBALS['what'] = '';
+$GLOBALS['action'] = '';
 
 // Set module
-$GLOBALS['module'] = "view";
+$GLOBALS['module'] = 'view';
 $GLOBALS['output_mode'] = -1;
 
 // Load the required file(s)
-require("inc/config.php");
+require('inc/config.php');
 
 if (((REQUEST_ISSET_GET(('user'))) || (REQUEST_ISSET_GET(('reseller')))) && (REQUEST_ISSET_GET(('banner')))) {
        // for later things... ;-)
@@ -61,7 +61,7 @@ if (((REQUEST_ISSET_GET(('user'))) || (REQUEST_ISSET_GET(('reseller')))) && (REQ
                        array(bigintval(REQUEST_GET('banner'))), __FILE__, __LINE__);
 
                $type = substr($url, -3);
-               header ("Content-Type: image/".$type);
+               header ('Content-Type: image/' . $type);
                LOAD_URL($url, false);
        } else {
                // Free memory
@@ -69,7 +69,7 @@ if (((REQUEST_ISSET_GET(('user'))) || (REQUEST_ISSET_GET(('reseller')))) && (REQ
        }
 } else {
        // Do nothing for now
-       LOAD_URL (URL."/index.php");
+       LOAD_URL('index.php');
 }
 
 // Shutdown