inc/extensions/ext-transfer.php -text
inc/extensions/ext-user.php -text
inc/extensions/ext-wernis.php -text
+inc/extensions/ext-yoomedia.php -text
inc/fatal_errors.php -text
inc/footer.php -text
inc/functions.php -text
inc/modules/admin/what-config_other.php -text
inc/modules/admin/what-config_payouts.php -text
inc/modules/admin/what-config_points.php -text
+inc/modules/admin/what-config_proxy.php -text
inc/modules/admin/what-config_rallye_prices.php -text
inc/modules/admin/what-config_refid.php -text
inc/modules/admin/what-config_reg.php -text
templates/de/html/admin/admin_config_payouts_row.tpl -text
templates/de/html/admin/admin_config_point_settings.tpl -text
templates/de/html/admin/admin_config_points.tpl -text
+templates/de/html/admin/admin_config_proxy.tpl -text
templates/de/html/admin/admin_config_rallye_del.tpl -text
templates/de/html/admin/admin_config_rallye_del_row.tpl -text
templates/de/html/admin/admin_config_rallye_edit.tpl -text
templates/de/html/ext/ext_transfer.tpl -text
templates/de/html/ext/ext_user.tpl -text
templates/de/html/ext/ext_wernis.tpl -text
+templates/de/html/ext/ext_yoomedia.tpl -text
templates/de/html/fatal_footer.tpl -text
templates/de/html/fatal_header.tpl -text
templates/de/html/guest/.htaccess -text
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- $_CONFIG['active_limit'] = $dummy['active_limit']; // Only display X most active users for today
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
break;
}
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- // Transfer all to the $_CONFIG array...
- $_CONFIG['ap_inactive'] = $dummy['autopurge_inactive']; // Autopurge inactive accounts (yes/no)
- $_CONFIG['ap_unconfirmed'] = $dummy['autopurge_unconfirmed']; // Autopurge unconfirmed accounts (yes/no)
- $_CONFIG['ap_tasks'] = $dummy['autopurge_tasks']; // Autopurge out-dated tasks (yes/no)
- $_CONFIG['ap_in_mail'] = $dummy['ap_in_notify']; // Send email to admin when purging inactive accounts (yes/no)
- $_CONFIG['ap_un_mail'] = $dummy['ap_un_notify']; // Send email to admin when purging unconfirmed accounts (yes/no)
- $_CONFIG['ap_tasks_mail'] = $dummy['ap_tasks_notify']; // Send email to admin when purging out-dated tasks (yes/no)
- $_CONFIG['ap_in_since'] = $dummy['ap_inactive_since']; // Timeout for confirmed accounts when they become inactive (seconds)
- $_CONFIG['ap_in_time'] = $dummy['ap_inactive_time']; // Timeout for inactive accounts when they are automatically deleted (seconds)
- $_CONFIG['ap_un_time'] = $dummy['ap_unconfirmed_time']; // Timeout for unconfirmed accounts when they are automatically deleted (seconds)
- $_CONFIG['ap_tasks_time'] = $dummy['ap_tasks_time']; // Timeout for out-dated tasks
- $_CONFIG['ap_del_mails'] = $dummy['ap_del_mails']; // Autopurge mails from deleted users?
- $_CONFIG['ap_dm_notify'] = $dummy['ap_dm_notify']; // Send email to admin when purging mails from deleted users (yes/no)
- $_CONFIG['ap_dm_timeout'] = $dummy['ap_dm_timeout']; // Timeout for mails from deleted users
-
- // Save some RAM...
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
// Do we have a daily-reset-run?
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- $_CONFIG['beg_timeout'] = $dummy['beg_timeout']; // Global timeout
- $_CONFIG['beg_uid_timeout'] = $dummy['beg_uid_timeout']; // Timeout for one userid
- $_CONFIG['beg_ip_timeout'] = $dummy['beg_ip_timeout']; // Timeout for one IP number
- $_CONFIG['beg_points'] = $dummy['beg_points']; // Minimum beggable points
- $_CONFIG['beg_points_max'] = $dummy['beg_points_max']; // Maximum beggable points
- $_CONFIG['beg_uid'] = $dummy['beg_uid']; // Account to subtract begged points from
- $_CONFIG['beg_mode'] = $dummy['beg_mode']; // Payment mode: direct or over referral system?
- $_CONFIG['beg_month'] = $dummy['beg_month']; // Current month
- $_CONFIG['beg_ranks'] = $dummy['beg_ranks']; // Maximum member who will win
- $_CONFIG['beg_active'] = $dummy['beg_active']; // Only active members can win?
- $_CONFIG['beg_rallye'] = $dummy['beg_rallye']; // Is the begging rallye activated?
- $_CONFIG['beg_ral_en_notify'] = $dummy['beg_ral_en_notify']; // Notify members on enabled rallye?
- $_CONFIG['beg_ral_di_notify'] = $dummy['beg_ral_di_notify']; // Notify members on disabled rallye?
- $_CONFIG['beg_notify_bonus'] = $dummy['beg_notify_bonus']; // When points are > 0 and bonus extension is installed, a bonus mail with this amount of points will be send instead of an enable-notification!
- $_CONFIG['beg_new_mem_notify'] = $dummy['beg_new_mem_notify']; // Notify members on disabled rallye?
- $_CONFIG['beg_notify_wait'] = $dummy['beg_notify_wait']; // Time to wait in seconds for bonus mails
- $_CONFIG['beg_include_own'] = $dummy['beg_include_own']; // Include webmaster's own userid in rallye?
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
// Remove old entries
$dummy = LOAD_CONFIG();
// Copy config to main array
- $_CONFIG['birthday_points'] = $dummy['birthday_points'];
- $_CONFIG['birthday_mode'] = $dummy['birthday_mode'];
- $_CONFIG['birthday_active'] = $dummy['birthday_active'];
+ $_CONFIG = array_merge($_CONFIG, $dummy);
// Save some RAM...
unset($dummy);
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- $_CONFIG['login_bonus'] = $dummy['login_bonus']; // Bonus points for successfull logins
- $_CONFIG['turbo_bonus'] = $dummy['turbo_bonus']; // Bonus points for the fastest clicker, No. 1
- $_CONFIG['bonus_rates'] = $dummy['turbo_rates']; // Points for clicker no. 2 to x
- $_CONFIG['bonus_ranks'] = $dummy['bonus_ranks']; // Total ranks who can win
- $_CONFIG['login_timeout'] = $dummy['login_timeout']; // Time in seconds between two logins
- $_CONFIG['bonus_month'] = $dummy['last_bonus_month']; // Last month where click-bonus are "paid"
- $_CONFIG['bonus_mode'] = $dummy['bonus_mode']; // Mode for adding points for login/click bonus
- $_CONFIG['bonus_uid'] = $dummy['bonus_uid']; // Member account to take points from
- $_CONFIG['bonus_lines'] = $dummy['bonus_lines']; // Number of lines to display in show_bonus.php
- $_CONFIG['bonus_timeout'] = $dummy['bonus_timeout']; // Auto-Purge timeout for bonus lines in mxchange_bonus_turbo
- $_CONFIG['bonus_order'] = $dummy['bonus_order']; // Bonus points for ordering mails
- $_CONFIG['bonus_ref'] = $dummy['bonus_ref']; // Bonus points for "making" a referral
- $_CONFIG['bonus_stats'] = $dummy['bonus_stats']; // Bonus points for 100% clickrate in mail stats
- $_CONFIG['bonus_active'] = $dummy['bonus_active']; // De/activate bonus active rallye
- $_CONFIG['bonus_order_yn'] = $dummy['bonus_order_yn']; // Include order bonus in analysis?
- $_CONFIG['bonus_ref_yn'] = $dummy['bonus_ref_yn']; // Include referral bonus in analysis?
- $_CONFIG['bonus_stats_yn'] = $dummy['bonus_stats_yn']; // Include statistics bonus in analysis?
- $_CONFIG['bonus_login_yn'] = $dummy['bonus_login_yn']; // Include login bonus in analysis?
- $_CONFIG['bonus_click_yn'] = $dummy['bonus_click_yn']; // Include "mailid" bonus in analysis?
- $_CONFIG['bonus_en_notify'] = $dummy['bonus_en_notify']; // Notify members about enabled active rallye?
- $_CONFIG['bonus_di_notify'] = $dummy['bonus_di_notify']; // Notify members about disabled active rallye?
- $_CONFIG['bonus_new_mem_notify'] = $dummy['bonus_new_mem_notify']; // Notify members about disabled active rallye?
- $_CONFIG['bonus_notify_points'] = $dummy['bonus_notify_points']; // Bonus points for the enable-notification mail? 0 = disable!
- $_CONFIG['bonus_notify_wait'] = $dummy['bonus_notify_wait']; // Time to wait in seconds for bonus mails
- $_CONFIG['bonus_include_own'] = $dummy['bonus_include_own']; // Include webmaster's own userid in active rallye?
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
if (defined('__DAILY_RESET') && (!DEBUG_MODE) && ($CSS != 1))
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
-
- // Load config and destroy dummy array
- $_CONFIG['cache_update'] = $dummy['cache_update']; // Last time the cache files are been re-created
- $_CONFIG['cache_path'] = $dummy['cache_path']; // Relative path for the cache files to 'inc/'
- $_CONFIG['cache_tested'] = $dummy['cache_tested']; // Says if cache path is tested or not
- $_CONFIG['db_hits'] = $dummy['db_hits']; // Counted hits on the database (all!)
- $_CONFIG['cache_hits'] = $dummy['cache_hits']; // Counted hits on the cache arrays in memory
- $_CONFIG['cache_admins'] = $dummy['cache_admins']; // Is the table '_admins' cacheable?
- $_CONFIG['cache_acls'] = $dummy['cache_acls']; // Is the table '_admins_acls' cacheable?
- $_CONFIG['cache_exts'] = $dummy['cache_exts']; // Is the table '_extensions' cacheable?
- $_CONFIG['cache_config'] = $dummy['cache_config']; // Is the table '_config' cacheable?
- $_CONFIG['cache_modreg'] = $dummy['cache_modreg']; // Is the table '_mod_reg' cacheable?
- $_CONFIG['cache_refdepth'] = $dummy['cache_refdepth']; // Is the table '_refdepths' cacheable?
- $_CONFIG['cache_refsys'] = $dummy['cache_refsys']; // Is the table '_refsystem' cacheable?
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
// Create instance on class
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- $_CONFIG['doubler_charge'] = $dummy['doubler_charge'];
- $_CONFIG['doubler_jackpot'] = $dummy['doubler_jackpot'];
- $_CONFIG['doubler_own'] = $dummy['doubler_own'];
- $_CONFIG['doubler_uid'] = $dummy['doubler_uid'];
- $_CONFIG['doubler_points'] = $dummy['doubler_points'];
- $_CONFIG['doubler_used'] = $dummy['doubler_used'];
- $_CONFIG['doubler_send_mode'] = $dummy['doubler_send_mode'];
- $_CONFIG['doubler_timeout'] = $dummy['doubler_timeout'];
- $_CONFIG['doubler_display_new'] = $dummy['doubler_display_new'];
- $_CONFIG['doubler_display_pay'] = $dummy['doubler_display_pay'];
- $_CONFIG['doubler_display_old'] = $dummy['doubler_display_old'];
- $_CONFIG['doubler_ref'] = $dummy['doubler_ref'];
- $_CONFIG['doubler_min'] = $dummy['doubler_min'];
- $_CONFIG['doubler_max'] = $dummy['doubler_max'];
- $_CONFIG['doubler_left'] = $dummy['doubler_left'];
- $_CONFIG['doubler_counter'] = $dummy['doubler_counter'];
- $_CONFIG['doubler_max_sent'] = $dummy['doubler_max_sent'];
- $_CONFIG['doubler_group_sent'] = $dummy['doubler_group_sent'];
- $_CONFIG['doubler_sent_all'] = $dummy['doubler_sent_all'];
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
if ((defined('__DAILY_RESET')) && ($_CONFIG['doubler_send_mode'] == "RESET"))
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- // Copy data to config array
- $_CONFIG['holiday_max'] = $dummy['holiday_max']; // Maximum days for holiday
- $_CONFIG['holiday_lock'] = $dummy['holiday_lock']; // Lock deactivation in member area for X seconds
- $_CONFIG['holiday_mode'] = $dummy['holiday_mode']; // Mode for activating holiday
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
// Do we have a daily-reset-run?
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- $_CONFIG['maintenance'] = $dummy['maintenance'];
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
break;
}
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- $_CONFIG['mt_start'] = $dummy['mt_start'];
- $_CONFIG['mt_stage'] = $dummy['mt_stage'];
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
break;
}
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- $_CONFIG['nl_charge'] = $dummy['nl_charge']; // Charge for your members to switch off the newsletter
- $_CONFIG['nl_month'] = $dummy['nl_month']; // Last month of check interval
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
// URL ends which are used to indentify the end of an URL or email link
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- $_CONFIG['order_min'] = $dummy['order_min']; // Order at least X mails
- $_CONFIG['order_max'] = $dummy['order_max_full']; // Ordering mode: as much as possible or as much as the user want's to receive
- $_CONFIG['order_select'] = $dummy['order_select']; // Sorting mode for selecting users while looking some up for mail delivery
- $_CONFIG['order_mode'] = $dummy['order_mode']; // Ascending or descending sort order for above
- $_CONFIG['repay_deleted_mails'] = $dummy['repay_deleted_mails']; // Wether repay points or send them to jackpot/shreder on mail order deletion
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
// Do daily reset only when installed and extension version is at least 0.1.1
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- // Copy data to config array
- $_CONFIG['register_default'] = $dummy['register_default']; // Is Yes/No the default selection in category selection?
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
break;
}
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- $_CONFIG['rewrite_skipped_mods'] = $dummy['rewrite_skip'];
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
break;
}
//
// Add default entries
//
- $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_sponsor_registry (ext_name, is_active, aid, stamp_added) VALUES ('sponsor', 'N', '".GET_ADMIN_ID($_COOKIE['admin_login'])."', '".time()."')";
+ $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_sponsor_registry (ext_name, is_active, aid, stamp_added) VALUES ('sponsor', 'N', '".GET_ADMIN_ID(get_session('admin_login'))."', 'UNIX_TIMESTAMP()')";
$SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_sponsor_action_convert (ext_name, conv_rate, conv_name) VALUES('sponsor', '10', 'Mails')";
$SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_sponsor_paytypes (pay_name, pay_min_count, pay_rate, pay_currency) VALUES ('Standart-Paket', 5, 1000.00000, '€')";
$SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_sponsor_paytypes (pay_name, pay_min_count, pay_rate, pay_currency) VALUES ('Spar-Paket', 1, 200.00000, '€')";
}
// Version number
-$EXT_VERSION = "0.4.2";
+$EXT_VERSION = "0.4.3";
// Auto-set extension version
if (!isset($EXT_VER)) $EXT_VER = $EXT_VERSION;
// Version history array (add more with , "0.1" and so on)
-$EXT_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");
+$EXT_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");
switch ($EXT_LOAD_MODE)
{
what='config_title' OR
what='sub_points' OR
what='config_admin' OR
-what='list_norefs' LIMIT 12";
+what='config_proxy' OR
+what='list_norefs'
+LIMIT 13";
$SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_themes";
$SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_guest_menu WHERE action='themes' LIMIT 1";
$SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_member_menu WHERE
case "0.4.2": // SQL queries for v0.4.2
$SQLs[] = "ALTER TABLE `"._MYSQL_PREFIX."_online` ADD INDEX `admin_member` (`is_admin`, `is_member`)";
break;
+
+ case "0.4.3": // SQL queries for v0.4.3
+ $SQLs[] = "ALTER TABLE `"._MYSQL_PREFIX."_config` ADD `proxy_host` VARCHAR(255) NOT NULL DEFAULT ''";
+ $SQLs[] = "ALTER TABLE `"._MYSQL_PREFIX."_config` ADD `proxy_port` INT(5) NOT NULL DEFAULT '0'";
+ $SQLs[] = "ALTER TABLE `"._MYSQL_PREFIX."_config` ADD `proxy_username` VARCHAR(255) NOT NULL DEFAULT ''";
+ $SQLs[] = "ALTER TABLE `"._MYSQL_PREFIX."_config` ADD `proxy_password` VARCHAR(255) NOT NULL DEFAULT ''";
+ $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES ('setup', 'config_proxy', 'Proxy-Einstellungen', 'Sollte Ihr Webserver sich hinter einem Proxy befinden, so können Sie hier MXChange so konfigurieren, dass es Updates durch diesen hindurch sucht!', 15)";
+ break;
}
break;
// When the sql_patches is not installed we cannot load it's configuration... *sigh*
if (GET_EXT_VERSION("sql_patches") != '') {
- $_CONFIG['ext_autopurge'] = $dummy['ext_autopurge'];
- $_CONFIG['mails_page'] = $dummy['mails_page'];
- $_CONFIG['index_home'] = $dummy['index_home'];
- $_CONFIG['verbose_sql'] = $dummy['verbose_sql'];
- $_CONFIG['middot'] = $dummy['menu_blur_spacer'];
- $_CONFIG['reg_points_mode'] = $dummy['reg_points_mode'];
- $_CONFIG['index_delay'] = $dummy['index_delay'];
- $_CONFIG['index_cookie'] = $dummy['index_cookie'];
- $_CONFIG['def_refid'] = $dummy['def_refid'];
- $_CONFIG['refid_target'] = $dummy['refid_target'];
- $_CONFIG['default_theme'] = $dummy['default_theme'];
- $_CONFIG['title_decoration'] = $dummy['enable_title_deco'];
- $_CONFIG['title_mod_show'] = $dummy['enable_mod_title'];
- $_CONFIG['title_what_show'] = $dummy['enable_what_title'];
- $_CONFIG['title_left'] = $dummy['title_left'];
- $_CONFIG['title_middle'] = $dummy['title_middle'];
- $_CONFIG['title_right'] = $dummy['title_right'];
- $_CONFIG['mad_counter'] = $dummy['mad_count'];
- $_CONFIG['last_mad'] = $dummy['mad_timestamp'];
- $_CONFIG['css_php'] = $dummy['css_php'];
- $_CONFIG['guest_menu'] = $dummy['guest_menu'];
- $_CONFIG['member_menu'] = $dummy['member_menu'];
- $_CONFIG['youre_here'] = $dummy['youre_here'];
- $_CONFIG['img_type'] = $dummy['img_type'];
- $_CONFIG['stats_limit'] = $dummy['stats_limit'];
- $_CONFIG['admin_menu'] = $dummy['admin_menu'];
- $_CONFIG['admin_menu_sorter'] = $dummy['admin_menu_sorter'];
- $_CONFIG['salt_length'] = $dummy['salt_length'];
- $_CONFIG['pass_scramble'] = trim($dummy['pass_scramble']);
- $_CONFIG['file_hash'] = trim($dummy['file_hash']);
- $_CONFIG['master_salt'] = trim($dummy['master_salt']);
$_CONFIG['secret_key'] = "";
- $_CONFIG['show_timings'] = $dummy['show_timings'];
+ //die("<pre>".print_r($dummy, true)."</pre>");
+ $_CONFIG = array_merge($_CONFIG, $dummy);
// Read key from secret file
if ((empty($_CONFIG['file_hash'])) || (empty($_CONFIG['master_salt'])) || (empty($_CONFIG['pass_scramble']))) {
} else {
// Set some lame ;-) default settings
$_CONFIG['def_refid'] = 0;
- $_CONFIG['title_decoration'] = 'N';
- $_CONFIG['title_mod_show'] = 'Y';
- $_CONFIG['title_middle'] = "-";
- //$_CONFIG['verbose_sql'] = 'N';
+ $_CONFIG['enable_title_deco'] = 'N';
+ $_CONFIG['title_mod_show'] = 'Y';
+ $_CONFIG['title_middle'] = "-";
+ //$_CONFIG['verbose_sql'] = 'N';
define('MT_WORD' , DEFAULT_MT_WORD );
define('MT_WORD2', DEFAULT_MT_WORD2);
define('POINTS' , DEFAULT_POINTS);
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- $_CONFIG['top10_max'] = $dummy['top10_max'];
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
break;
}
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- // Maximum of listed transfers for out- and in-transfers
- $_CONFIG['transfer_max'] = $dummy['transfer_max'];
- // Age in seconds
- $_CONFIG['transfer_age'] = $dummy['transfer_age'];
- // Lock timeout for member settings
- $_CONFIG['transfer_timeout'] = $dummy['transfer_timeout'];
- // Balance after points transfer
- $_CONFIG['transfer_balance'] = $dummy['transfer_balance'];
- // Length of touring code
- $_CONFIG['transfer_code'] = $dummy['transfer_code'];
- // Length of touring code
- $_CONFIG['ap_transfer'] = $dummy['ap_transfer'];
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
if ((defined('__DAILY_RESET')) && ($_CONFIG['ap_transfer'] == 'Y'))
default: // Do stuff when extension is loaded
$dummy = LOAD_CONFIG();
- $_CONFIG['user_limit'] = $dummy['user_limit'];
- $_CONFIG['user_alpha'] = $dummy['user_alpha'];
+ $_CONFIG = array_merge($_CONFIG, $dummy);
unset($dummy);
break;
}
--- /dev/null
+<?php
+/************************************************************************
+ * MXChange v0.2.1 Start: 08/27/2008 *
+ * ================ Last change: 08/27/2008 *
+ * *
+ * -------------------------------------------------------------------- *
+ * File : ext-yoomedia.php *
+ * -------------------------------------------------------------------- *
+ * Short description : Extension for contacting the API of Yoo!Media *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung : Erweitertung zur Anbindung an die API von *
+ * Yoo!Media *
+ * -------------------------------------------------------------------- *
+ * *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003, 2004, 2005, 2006, 2007 by Roland Haeder *
+ * For more information visit: http://www.mxchange.org *
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ * This program is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
+ * GNU General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU General Public License *
+ * along with this program; if not, write to the Free Software *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, *
+ * MA 02110-1301 USA *
+ ************************************************************************/
+
+// Some security stuff...
+if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])))
+{
+ $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+ require($INC);
+}
+
+// Version number
+$EXT_VERSION = "0.0";
+
+// Auto-set extension version
+if (empty($EXT_VER)) $EXT_VER = $EXT_VERSION;
+
+// Version history array (add more with , "0.1" and so on)
+$EXT_VER_HISTORY = array("0.0");
+
+switch ($EXT_LOAD_MODE)
+{
+case "register": // Do stuff when installtion is running (modules.php?module=admin&action=login is called)
+ // SQL commands to run
+ $SQLs[] = "";
+
+ // Load CSS file?
+ $EXT_CSS = 'Y';
+ break;
+
+case "remove": // Do stuff when removing extension
+ // SQL commands to run
+ break;
+
+case "activate": // Do stuff when admin activates this extension
+ // SQL commands to run
+ break;
+
+case "deactivate": // Do stuff when admin deactivates this extension
+ // SQL commands to run
+ break;
+
+case "update": // Update an extension
+ switch ($EXT_VER)
+ {
+ case "0.0.1": // SQL queries for v0.0.1
+ $SQLs[] = "";
+
+ // Update notes (these will be set as task text!)
+ $UPDATE_NOTES = "";
+ break;
+ }
+ break;
+
+default: // Do stuff when extension is loaded
+ $DUMMY = LOAD_CONFIG("0");
+ unset($DUMMY);
+ break;
+}
+
+// Language file prefix
+$EXT_LANG_PREFIX = "yoomedia";
+
+// Extension is always active?
+$EXT_ALWAYS_ACTIVE = 'N';
+
+//
+?>
// Compile and run finished rendered HTML code
while (strpos($OUTPUT, '{!') > 0) {
- $eval = "\$OUTPUT = \"" . COMPILE_CODE(addslashes($OUTPUT)) . "\";";
- eval($eval);
+ // Prepare the content and eval() it...
+ $newContent = "";
+ $eval = "\$newContent = \"" . COMPILE_CODE(addslashes($OUTPUT)) . "\";";
+ @eval($eval);
+
+ if (empty($newContent)) {
+ // Something went wrong!
+ die("Evaluation error:<pre>".htmlentities($eval)."</pre>");
+ }
+ $OUTPUT = $newContent;
}
// Output code here, DO NOT REMOVE! ;-)
//
function MXCHANGE_OPEN ($script) {
+ global $_CONFIG;
+ // Default is not to use proxy
+ $useProxy = true;
+
+ // Are proxy settins set?
+ if ((!empty($_CONFIG['proxy_host'])) && ($_CONFIG['proxy_port'] > 0)) {
+ // Then use it
+ $useProxy = true;
+ }
+
//* DEBUG */ print("SCRIPT=".$script."<br />\n");
// Compile the script name
$script = COMPILE_CODE($script);
$extract = explode("/", $url);
$url = $extract[0];
// Done extracting the URL :)
- }
+ } // END - if
// Extract host name
$host = str_replace("http://", "", $url);
// Open connection
//* DEBUG */ die("SCRIPT=".$script."<br />\n");
- $fp = @fsockopen($host, 80, $errno, $errdesc, 30);
- if (!$fp) {
- // Failed!
- return array("", "", "");
+ if ($useProxy) {
+ $fp = @fsockopen(COMPILE_CODE($_CONFIG['proxy_host']), $_CONFIG['proxy_port'], $errno, $errdesc, 30);
+ } else {
+ $fp = @fsockopen($host, 80, $errno, $errdesc, 30);
}
- // Generate request header
- $request = "GET /".trim($script)." HTTP/1.0\r\n";
+ // Is there a link?
+ if (!is_resource($fp)) {
+ // Failed!
+ return array("", "", "");
+ } // END - if
+
+ // Do we use proxy?
+ if ($useProxy) {
+ // Generate CONNECT request header
+ $request = "CONNECT ".$host.":80 HTTP/1.1\r\n";
+ $request .= "Host: ".$host."\r\n";
+
+ // Use login data to proxy? (username at least!)
+ if (!empty($_CONFIG['proxy_username'])) {
+ // Add it as well
+ $encodedAuth = base64_encode(COMPILE_CODE($_CONFIG['proxy_username']).":".COMPILE_CODE($_CONFIG['proxy_password']));
+ $request .= "Proxy-Authorization: Basic ".$encodedAuth."\r\n";
+ } // END - if
+
+ // Add last new-line
+ $request .= "\r\n";
+ //* DEBUG: */ print("<strong>Request:</strong><pre>".$request."</pre>");
+
+ // Write request
+ fputs($fp, $request);
+
+ // Got response?
+ if (feof($fp)) {
+ // No response received
+ return array("", "", "");
+ } // END - if
+
+ // Read the first line
+ $resp = trim(fgets($fp, 10240));
+ $respArray = explode(" ", $resp);
+ if ((strtolower($respArray[0]) !== "http/1.0") || ($respArray[1] != "200")) {
+ // Invalid response!
+ return array("", "", "");
+ } // END - if
+ } // END - if
+
+ // Generate GET request header
+ $request = "GET /".trim($script)." HTTP/1.1\r\n";
$request .= "Host: ".$host."\r\n";
$request .= "Referer: ".URL."/admin.php\r\n";
- $request .= "User-Agent: ".TITLE."/".FULL_VERSION."\r\n\r\n";
+ $request .= "User-Agent: ".TITLE."/".FULL_VERSION."\r\n";
+ $request .= "Content-Type: text/plain\r\n";
+ $request .= "Cache-Control: no-cache\r\n";
+ $request .= "Connection: Close\r\n\r\n";
+ //* DEBUG: */ print("<strong>Request:</strong><pre>".$request."</pre>");
// Initialize array
$response = array();
// Read response
while(!feof($fp)) {
$response[] = trim(fgets($fp, 1024));
- }
+ } // END - while
// Close socket
fclose($fp);
+ //* DEBUG: */ print("<strong>Response:</strong><pre>".print_r($response, true)."</pre>");
+
+ // Proxy agent found?
+ if ((substr(strtolower($response[0]), 0, 11) == "proxy-agent") && ($useProxy)) {
+ // Proxy header detected, so remove two lines
+ array_shift($response);
+ array_shift($response);
+ } // END - if
+
// Was the request successfull?
- if ((!ereg("200 OK", $response[0])) && (empty($response[0]))) {
+ if ((!ereg("200 OK", $response[0])) || (empty($response[0]))) {
// Not found / access forbidden
$response = array("", "", "");
- }
+ } // END - if
// Return response
return $response;
// Unset/set session variables
function set_session ($var, $value) {
global $CSS;
+
// Abort in CSS mode here
if ($CSS == 1) return true;
//* DEBUG: */ echo "SET:".$var."=".$value."<br />\n";
$_SESSION[$var] = $value;
return session_register($var);
+ } elseif (!empty($value)) {
+ // Update session
+ $_SESSION[$var] = $value;
}
// Return always true if the session variable is already set.
// Returns wether the value of the session variable or NULL if not set
function get_session($var) {
- if (!isset($_SESSION)) session_start();
-
// Default is not found! ;-)
$value = null;
}
//
-//////////////////////////////////////////////
-// //
-// AUTOMATICALLY RE-GNERATED FUNCTIONS ONLY //
-// //
-//////////////////////////////////////////////
+//////////////////////////////////////////////////
+// //
+// AUTOMATICALLY RE-GENERATED MISSING FUNCTIONS //
+// //
+//////////////////////////////////////////////////
//
-if (!function_exists('html_entity_decode'))
-{
+if (!function_exists('html_entity_decode')) {
// Taken from documentation on www.php.net
- function html_entity_decode($string)
- {
+ function html_entity_decode($string) {
$trans_tbl = get_html_translation_table(HTML_ENTITIES);
$trans_tbl = array_flip($trans_tbl);
return strtr($string, $trans_tbl);
}
}
+
//
?>
// Add title decorations? (left)
if (!defined('__PAGE_TITLE')) {
if ((count($_CONFIG) > 1) && (is_resource($link)) && (isset($db))) {
- if (($_CONFIG['title_decoration'] == 'Y') && (trim(!empty($_CONFIG['title_left'])))) $TITLE .= trim($_CONFIG['title_left'])." ";
+ if (($_CONFIG['enable_title_deco'] == 'Y') && (trim(!empty($_CONFIG['title_left'])))) $TITLE .= trim($_CONFIG['title_left'])." ";
$TITLE .= MAIN_TITLE;
// Add title of module? (middle decoration will also be added!)
- if (($_CONFIG['title_mod_show'] == 'Y') || ((empty($GLOBALS['what'])) && (empty($GLOBALS['action']))) || ($GLOBALS['module'] == "admin")) $TITLE .= " ".trim($_CONFIG['title_middle'])." ".ADD_MODULE_TITLE($GLOBALS['module']);
+ if (($_CONFIG['enable_mod_title'] == 'Y') || ((empty($GLOBALS['what'])) && (empty($GLOBALS['action']))) || ($GLOBALS['module'] == "admin")) $TITLE .= " ".trim($_CONFIG['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)) && (isset($_CONFIG['title_what_show'])) && ($_CONFIG['title_what_show'] == 'Y')) $TITLE .= " ".trim($_CONFIG['title_middle'])." ".GET_MOD_DESCR($MODE, $GLOBALS['what']);
+ if ((!empty($MODE)) && (isset($_CONFIG['enable_what_title'])) && ($_CONFIG['enable_what_title'] == 'Y')) $TITLE .= " ".trim($_CONFIG['title_middle'])." ".GET_MOD_DESCR($MODE, $GLOBALS['what']);
// Add title decorations? (right)
- if (($_CONFIG['title_decoration'] == 'Y') && (!empty($_CONFIG['title_right']))) $TITLE .= " ".trim($_CONFIG['title_right']);
+ if (($_CONFIG['enable_title_deco'] == 'Y') && (!empty($_CONFIG['title_right']))) $TITLE .= " ".trim($_CONFIG['title_right']);
// Remember title in constant for the template
define('__PAGE_TITLE', html_entity_decode($TITLE));
define('ADMIN_POINTS_SHREDDED', "Es wurden <u>%s</u> {!POINTS!} geschrettert.");
define('EXTENSION_WARNING_EXT_INACTIVE', "Die Erweiterung <u>%s</u> ist nicht aktiv. Dies kann zu Störungen führen.<br />\nBitte aktivieren Sie diese unter <em>Verschiedenes->Erweiterungen</em>.");
define('EXTENSION_WARNING_USER_LIMIT', "Die Erweiterung <u>user</u> ist nicht aktiv. Die Anzahl User pro Seite wurde auf 100 gesetzt. Bitte aktivieren Sie diese unter <em>Verschiedenes->Erweiterungen</em>.");
+define('ADMIN_PROXY_SETTINGS_INVALID', "Ihre Proxy-Einstellungen scheinen ungültig zu sein!");
+define('ADMIN_EDIT_PROXY_SETTINGS', "Proxy-Einstellungen ändern");
+define('ADMIN_CONFIG_PROXY_HOST', "Hostname oder IP-Nummer:");
+define('ADMIN_CONFIG_PROXY_PORT', "Port-Nummer (z.B. 8085):");
+define('ADMIN_CONFIG_PROXY_USERNAME', "Benuztername (falls vorhanden):");
+define('ADMIN_CONFIG_PROXY_PASSWORD', "Passwort (falls vorhanden):");
//
?>
}
}
}
+// Checks proxy settins by fetching check-updates2.php from www.mxchange.org
+function ADMIN_TEST_PROXY_SETTINGS ($settingsArray) {
+ global $_CONFIG;
+ // By default they are invalid
+ $valid = false;
+
+ // Set temporary the new settings
+ $_CONFIG = array_merge($_CONFIG, $settingsArray);
+
+ // Now get the test URL
+ $content = MXCHANGE_OPEN("check-updates2.php");
+
+ // Is the first line with "200 OK"?
+ $valid = ereg("200 OK", $content[0]);
+
+ // Return result
+ return $valid;
+}
//
?>
--- /dev/null
+<?php
+/************************************************************************
+ * MXChange v0.2.1 Start: 08/27/2008 *
+ * ================ Last change: 08/27/2008 *
+ * *
+ * -------------------------------------------------------------------- *
+ * File : what-config_proxy.php *
+ * -------------------------------------------------------------------- *
+ * Short description : Proxy settings *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung : Proxy-Einstellungenent *
+ * -------------------------------------------------------------------- *
+ * *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder *
+ * For more information visit: http://www.mxchange.org *
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ * This program is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
+ * GNU General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU General Public License *
+ * along with this program; if not, write to the Free Software *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, *
+ * MA 02110-1301 USA *
+ ************************************************************************/
+
+// Some security stuff...
+if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) || (!IS_ADMIN())) {
+ $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+ require($INC);
+}
+
+// Add description as navigation point
+ADD_DESCR("admin", basename(__FILE__));
+
+if (isset($_POST['ok'])) {
+ // Test proxy settings
+ if (ADMIN_TEST_PROXY_SETTINGS($_POST)) {
+ // Save configuration
+ ADMIN_SAVE_SETTINGS($_POST);
+ } else {
+ // Invalid!
+ LOAD_TEMPLATE("admin_settings_saved", false, ADMIN_PROXY_SETTINGS_INVALID);
+ }
+} else {
+ // Prepare content
+ $content = array(
+ 'proxy_host' => $_CONFIG['proxy_host'],
+ 'proxy_port' => $_CONFIG['proxy_port'],
+ 'proxy_username' => $_CONFIG['proxy_username'],
+ 'proxy_password' => $_CONFIG['proxy_password'],
+ );
+
+ // Load template
+ LOAD_TEMPLATE("admin_config_proxy", false, $content);
+}
+
+//
+?>
define('__CFG_TITLE_LEFT' , $_CONFIG['title_left']);
define('__CFG_TITLE_MIDDLE' , $_CONFIG['title_middle']);
define('__CFG_TITLE_RIGHT' , $_CONFIG['title_right']);
- define('__CFG_TITLE_DECOS' , ADD_SELECTION("yn", $_CONFIG['title_decoration'], "enable_title_deco"));
- define('__CFG_TITLE_MOD_SHOW' , ADD_SELECTION("yn", $_CONFIG['title_mod_show'] , "enable_mod_title" ));
+ define('__CFG_TITLE_DECOS' , ADD_SELECTION("yn", $_CONFIG['enable_title_deco'], "enable_title_deco"));
+ define('__CFG_TITLE_MOD_SHOW' , ADD_SELECTION("yn", $_CONFIG['enable_mod_title'] , "enable_mod_title" ));
define('__CFG_TITLE_WHAT_SHOW', ADD_SELECTION("yn", $_CONFIG['title_what_show'] , "enable_what_title"));
// Load template
************************************************************************/
// Some security stuff...
-if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) || (!is_admin()))
-{
+if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) || (!is_admin())) {
$INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
require($INC);
}
+
// Add description as navigation point
ADD_DESCR("admin", basename(__FILE__));
// Check for selected themes
$SEL = 0;
if (!empty($_POST['sel'])) $SEL = SELECTION_COUNT($_POST['sel']);
-if ($SEL > 0)
-{
+if ($SEL > 0) {
$OUT = "";
- foreach ($_POST['sel'] as $id=>$sel)
- {
+ foreach ($_POST['sel'] as $id=>$sel) {
$SQL = "";
// Shall I de-/activate or delete themes?
- if (isset($_POST['status']))
- {
+ if (isset($_POST['status'])) {
// Change status
- if ($_POST['active'][$id] == 'Y')
- {
+ if ($_POST['active'][$id] == 'Y') {
$SQL = "UPDATE "._MYSQL_PREFIX."_themes SET theme_active='N' WHERE id='".$id."' LIMIT 1";
- }
- else
- {
+ } else {
$SQL = "UPDATE "._MYSQL_PREFIX."_themes SET theme_active='Y' WHERE id='".$id."' LIMIT 1";
}
$OUT = ADMIN_THEMES_UPDATED;
- }
- elseif (isset($_POST['del']))
- {
+ } elseif (isset($_POST['del'])) {
// Delete themes
$SQL = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_themes WHERE id='".$id."' LIMIT 1";
$OUT = ADMIN_THEMES_DELETED;
// Output generated?
if (empty($OUT)) ADMIN_THEME_NO_OUTPUT;
} elseif (!empty($_GET['default_theme'])) {
- // Save theme
+ // Escape string from input
$POST['default_theme'] = SQL_ESCAPE($_GET['default_theme']);
- set_session("mxchange_theme", $POST['default_theme'], (time() + 60*60*24*365), COOKIE_PATH);
+
+ // Set session
+ set_session("mxchange_theme", $POST['default_theme']);
+
+ // Save theme
ADMIN_SAVE_SETTINGS($POST);
}
// Free memory
SQL_FREERESULT($result);
-}
- else
-{
+} else {
// No themes found???
$OUT .= "<TR>
<TD colspan=\"7\" class=\"bottom2\" height=\"60\">
SQL_FREERESULT($result);
// Change to new theme
- set_session("mxchange_theme", $NewTheme, (time() + 60*60*24*365), COOKIE_PATH);
+ set_session("mxchange_theme", $NewTheme);
$bonus = false;
if ((GET_EXT_VERSION("sql_patches") >= "0.2.8") && (GET_EXT_VERSION("bonus") >= "0.2.1") && ($_CONFIG['bonus_login_yn'] == 'N') && ($_CONFIG['bonus_login_yn'] == 'Y')) {
// Account confirmed!
if (defined('LEAD_CODE_ENABLED') && defined('LEAD_EXPIRY_TIME')) {
// Set special lead cookie
- set_session("lead_uid", bigintval($uid), (time() + LEAD_EXPIRY_TIME), COOKIE_PATH);
+ set_session("lead_uid", bigintval($uid));
// Lead-Code mode enabled
LOAD_URL("lead-confirm.php");
}
} elseif (defined('LEAD_CODE_ENABLED') && defined('LEAD_EXPIRY_TIME')) {
// Set special lead cookie
- set_session("lead_uid", bigintval($uid), (time() + LEAD_EXPIRY_TIME), COOKIE_PATH);
+ set_session("lead_uid", bigintval($uid));
// Lead-Code mode enabled
LOAD_URL("lead-confirm.php");
$NewTheme = $_POST['member_theme'];
// Change to new theme
- set_session("mxchange_theme", $NewTheme, (time() + 60*60*24*365), COOKIE_PATH);
+ set_session("mxchange_theme", $NewTheme);
// Theme saved!
LOAD_TEMPLATE("admin_settings_saved", false, MEMBER_THEME_SAVED);
require_once(PATH."inc/extensions.php");
require_once(PATH."inc/language.php");
-// Load "databases" aka static arrays
-require_once(PATH."inc/databases.php"); // Several hard-coded databases (arrays, constants)
-
// Check if the user setups his MySQL stuff...
if ((empty($MySQL['login'])) && (!isBooleanConstantAndTrue('mxchange_installing')) && (!isset($_GET['installing'])) && (isBooleanConstantAndTrue('mxchange_installed'))) {
// No login entered and outside installation mode
echo "<STRONG>".LANG_WARNING.":</STRONG> ".WARN_NULL_PASSWORD;
}
-// Init configuration arrays
-$_CONFIG = array(
- 'code_length' => 0
-);
-
// Check if this file is writeable or read-only and warn the user
if ((!isBooleanConstantAndTrue('mxchange_installing')) && (isBooleanConstantAndTrue('mxchange_installed'))) {
// Check for write-permission for config.php and inc directory
// Load all extensions
require_once(PATH."inc/load_extensions.php");
+ // Load "databases" aka static arrays
+ require_once(PATH."inc/databases.php");
+
// Loading patching system is required here...
require_once(PATH."inc/patch-system.php"); // Initialize patch system
// Functions which are related to themes
require_once(PATH."inc/theme-manager.php");
- // Initialize session management
- require_once(PATH."inc/session.php");
-
// Load admin include file if he is admin
if (IS_ADMIN()) {
// Administrative functions
require_once(PATH."inc/databases.php");
require_once(PATH."inc/theme-manager.php");
require_once(PATH."inc/load_extensions.php");
- require_once(PATH."inc/session.php");
// Check if we are in installation routine
$installPhp = basename($_SERVER['PHP_SELF']);
require($INC);
}
+// Always make sure the session management is initialized first
+require_once(PATH."inc/session.php");
+
//
function GET_CURR_THEME() {
global $INC_POOL, $_CONFIG, $CSS;
if (!isSessionVariableSet('mxchange_theme')) {
// Set default theme
- set_session("mxchange_theme", $ret, (time() + 60*60*24*365), COOKIE_PATH);
+ set_session("mxchange_theme", $ret);
} elseif ((isSessionVariableSet('mxchange_theme')) && (GET_EXT_VERSION("sql_patches") >= "0.1.4")) {
// Get theme from cookie
$result = SQL_QUERY_ESC("SELECT id FROM "._MYSQL_PREFIX."_themes WHERE theme_path='%s' LIMIT 1", array(get_session('mxchange_theme')), __FILE__, __LINE__);
// Installation mode active
if ((!empty($_GET['theme'])) && (file_exists($theme)) && (is_readable($theme))) {
// Set cookie from URL data
- set_session("mxchange_theme", $_GET['theme'], (time() + 60*60*24*365), COOKIE_PATH);
+ set_session("mxchange_theme", $_GET['theme']);
} elseif (file_exists(PATH."theme/".$_POST['theme']."/theme.php")) {
// Set cookie from posted data
- set_session("mxchange_theme", $_POST['theme'], (time() + 60*60*24*365), COOKIE_PATH);
+ set_session("mxchange_theme", $_POST['theme']);
}
// Set return value
$ret = get_session('mxchange_theme');
} else {
// Invalid design, reset cookie
- set_session("mxchange_theme", $ret, (time() + 60*60*24*365), COOKIE_PATH);
+ set_session("mxchange_theme", $ret);
}
// Add (maybe) found theme.php file to inclusion list
$NewTheme = $_POST['new_theme'];
// Change to new theme
- set_session("mxchange_theme", $NewTheme, (time() + 60*60*24*365), COOKIE_PATH);
+ set_session("mxchange_theme", $NewTheme);
// Remove current from array and set new
$theme = PATH."theme/".$CurrTheme."/theme.php";
// Is the index page configured for redirect pr not?
if ($_CONFIG['index_cookie'] > 0) {
// Set cookie and remeber it for specified time
- set_session("visited", "true", (time() + $_CONFIG['index_cookie']), COOKIE_PATH);
+ set_session("visited", "true");
} elseif (isSessionVariableSet('visited')) {
// Remove cookie when admin set 0 in setup
set_session("visited", "");
--- /dev/null
+<FORM action="{!URL!}/modules.php?module=admin&what=config_proxy" method="POST">
+<TABLE border="0" cellspacing="0" cellpadding="0" align="center" class="admin_table dashed" width="500">
+ <TR>
+ <TD colspan="2" align="center" class="admin_title bottom2" height="30">
+ <STRONG>{--ADMIN_EDIT_PROXY_SETTINGS--}</STRONG></TD>
+ </TR>
+ <TR><TD colspan="2" class="seperator" height="5"> </TD></TR>
+ <TR>
+ <TD align="right" style="padding-right:10px">
+ {--ADMIN_CONFIG_PROXY_HOST--}
+ </TD>
+ <TD>
+ <INPUT type="text" name="proxy_host" value="$content[proxy_host]" />
+ </TD>
+ </TR>
+ <TR><TD colspan="2" class="seperator" height="5"> </TD></TR>
+ <TR>
+ <TD align="right" style="padding-right:10px">
+ {--ADMIN_CONFIG_PROXY_PORT--}
+ </TD>
+ <TD>
+ <INPUT type="text" name="proxy_port" value="$content[proxy_port]" />
+ </TD>
+ </TR>
+ <TR><TD colspan="2" class="seperator" height="5"> </TD></TR>
+ <TR>
+ <TD align="right" style="padding-right:10px">
+ {--ADMIN_CONFIG_PROXY_USERNAME--}
+ </TD>
+ <TD>
+ <INPUT type="text" name="proxy_username" value="$content[proxy_username]" />
+ </TD>
+ </TR>
+ <TR><TD colspan="2" class="seperator" height="5"> </TD></TR>
+ <TR>
+ <TD align="right" style="padding-right:10px">
+ {--ADMIN_CONFIG_PROXY_PASSWORD--}
+ </TD>
+ <TD>
+ <INPUT type="password" name="proxy_password" value="$content[proxy_password]" />
+ </TD>
+ </TR>
+ <TR><TD colspan="2" class="bottom2 seperator" height="5"> </TD></TR>
+ <TR>
+ <TD colspan="2" align="center" class="admin_footer">
+ <INPUT type="reset" class="admin_reset" value="{--CLEAR_FORM--}" /> *
+ <INPUT type="submit" name="ok" class="admin_submit" value="{--SAVE_SETTINGS--}" />
+ </TD>
+ </TR>
+</TABLE>
+</FORM>
--- /dev/null
+Erweiterung zur Anbindung an die API (Interface 2.0!) von <a href="http://www.yoomedia.de?ref=1715" target="_blank" rel="external" title="Referral-Link, bitte ID stehen lassen!">Yoo!Media</a>.