./inc/mysql-manager.php:1959:// @TODO Fix inconsistency between last_module and getWhat()
./inc/mysql-manager.php:368: // @TODO Try to rewrite this to one or more functions
./inc/mysql-manager.php:44:// @TODO Can we cache this?
-./inc/reset/reset_beg.php:49:// @TODO This should be converted in a daily beg rallye
-./inc/reset/reset_birthday.php:89: // @TODO 4 is hard-coded here, should we move it out in config?
+./inc/reset/reset_beg.php:52:// @TODO This should be converted in a daily beg rallye
+./inc/reset/reset_birthday.php:92: // @TODO 4 is hard-coded here, should we move it out in config?
./inc/revision-functions.php:169:// @TODO This function does also set and get in 'cache_array'
./inc/template-functions.php:1044: // @TODO Deprecate this thing
./inc/template-functions.php:1055: // @TODO Deprecate this thing
$currMonth = getMonth();
// Has it changed?
- if ((getConfig('last_month') != $currMonth) || (isMonthlyResetDebugEnabled())) {
+ if ((getLastMonth() != $currMonth) || (isMonthlyResetDebugEnabled())) {
// Include monthly reset scripts
mergeIncludePool('reset', getArrayFromDirectory('inc/monthly/', 'monthly_'));
'ADMIN_OPTION_POINTS_WORD' => "Währung Ihres Tausches (Klammlose, Wernis, Primera, FuCo, etc.)",
'ADMIN_OPTION_MAX_COMMA' => "Angezeigte Stellen hinter dem Komma",
'ADMIN_OPTION_CSS_PHP' => "Sollen die CSS-Dateien direkt ausgegeben werden oder von css.php angezeigt werden?",
- 'ADMIN_CSS_PHP_DIRECT' => "Per <link>-Tag ausgeben (Debug!)",
- 'ADMIN_CSS_PHP_FILE' => "Per css.php ausgeben (<strong>empfohlen</strong>)",
- 'ADMIN_CSS_PHP_INLINE' => "In <style>-Tag eingeschlossen ausgeben (Debug!)",
+ 'ADMIN_SELECT_CSS_OUTPUT_MODE_DIRECT' => "Per <link>-Tag ausgeben (Debug!)",
+ 'ADMIN_SELECT_CSS_OUTPUT_MODE_FILE' => "Per css.php ausgeben",
+ 'ADMIN_SELECT_CSS_OUTPUT_MODE_INLINE' => "In <style>-Tag ausgeben",
'ADMIN_OPTION_GUEST_MENU' => "Gastmenü ein-/ausblenden",
'ADMIN_OPTION_MEMBER_MENU' => "Mitgliedsmenü ein-/ausblenden",
'ADMIN_OPTION_YOURE_HERE' => "Navigation "Sie sind hier" ein-/ausblenden",
- 'ADMIN_GUEST_MENU_ACTIVE' => "Einblenden",
- 'ADMIN_GUEST_MENU_INACTIVE' => "Ausblenden",
- 'ADMIN_MEMBER_MENU_ACTIVE' => "Einblenden",
- 'ADMIN_MEMBER_MENU_INACTIVE' => "Ausblenden",
- 'ADMIN_YOURE_HERE_ACTIVE' => "Einblenden",
- 'ADMIN_YOURE_HERE_INACTIVE' => "Ausblenden",
+ 'ADMIN_IS_SHOWN' => "Einblenden",
+ 'ADMIN_IS_NOT_SHOWN' => "Ausblenden",
'ADMIN_OPTION_MT_WORD' => "Art Ihres Tausches (1. Fall)",
'ADMIN_OPTION_MT_WORD2' => "Art Ihres Tausches (2. Fall)",
'ADMIN_OPTION_MT_WORD3' => "Art Ihres Tausches (1. Fall, Plural)",
if (!isHtmlOutputMode()) return;
// Create timemark from saved month
-$mark = mktime(0, 0, 0, getConfig('last_month'), getDay(), getYear());
+$mark = mktime(0, 0, 0, getLastMonth(), getDay(), getYear());
$sql = ''; $mode = '';
// Shall I sent activation or deactivation mail?
if (!isHtmlOutputMode()) return;
// Create timemark from saved month
-$mark = mktime(0, 0, 0, getConfig('last_month'), getDay(), getYear());
+$mark = mktime(0, 0, 0, getLastMonth(), getDay(), getYear());
$sql = ''; $mode = '';
// Shall I sent activation or deactivation mail?
$content['total'] = $total;
// Check if we need to display form or not with manuel withdraw
- if (getConfig('last_month') == getMonth()) {
+ if (getLastMonth() == getMonth()) {
// Load form
$content['withdraw_form'] = loadTemplate('admin_list_beg_form', true);
} else {
$content['total'] = $total;
// Check if we need to display form or not with manuel withdraw
- if (getConfig('last_month') == getMonth()) {
+ if (getLastMonth() == getMonth()) {
// Load form
$content['withdraw_form'] = loadTemplate('admin_list_bonus_form', true);
} else {
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Monthly reset started.');
+
// Do your monthly-reset things here
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Monthly reset ended.');
+
// [EOF]
?>
return;
}
-// Get current month (2 digits)
-$curr = getMonth();
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Monthly reset started.');
// Check if month is done
-if (($curr != getConfig('last_month')) && (getConfig('last_month') > 0) && (getConfig('beg_ranks') > 0) && (!isCssOutputMode())) {
+if ((getConfig('beg_ranks') > 0) && (!isCssOutputMode())) {
// Extension 'autopurge' is inactive or purging of inactive accounts is deactivated
$whereStatement1 = '';
SQL_FREERESULT($result_main);
} // END - if
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Monthly reset ended.');
+
// [EOF]
?>
return;
}
-// Get current month (2 digits)
-$curr = getMonth();
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Monthly reset started.');
-if (($curr != getConfig('last_month')) && (getConfig('bonus_ranks') > 0) && (!isCssOutputMode())) {
+if ((getConfig('bonus_ranks') > 0) && (!isCssOutputMode())) {
// Extension 'autopurge' is inactive or purging of inactive accounts is deactivated
$whereStatement1 = "WHERE `status`='CONFIRMED'";
SQL_FREERESULT($result_main);
} // END - if
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Monthly reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Monthly reset started.');
+
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Monthly reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Monthly reset started.');
+
// Reset surfbar counter
updateConfiguration('surfbar_monthly_counter', 0);
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Monthly reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
// Check for 100% klickrate mails
$result_bonus = SQL_QUERY("SELECT
`id`, `userid`, `subject`, `timestamp_ordered`, `clicks`, `url`
// Free memory
SQL_FREERESULT($result_bonus);
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
// Init & set the include pool
initIncludePool('autopurge');
setIncludePool('autopurge', getArrayFromDirectory('inc/autopurge/', 'purge-'));
// Run filters for extra autopurge
runFilterChain('extra_autopurge');
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
// @TODO This should be converted in a daily beg rallye
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
// Get current day (01 to 31), month (01 to 12) and year (4-digits year)
$day = getDay();
$month = getMonth();
// @TODO 4 is hard-coded here, should we move it out in config?
for ($idx = '0'; $idx < 4; $idx++) {
- $content['check'] .= generateRandomCode('8', mt_rand(0, $month.$day), $content['userid'], ($age * ($idx + 1)));
+ $content['check'] .= generateRandomCode('8', mt_rand(0, $month . $day), $content['userid'], ($age * ($idx + 1)));
} // END - for
// Insert row into database
SQL_FREERESULT($result_birthday);
} // END - if
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
// Purge expired entries in _bonus_turbo
purgeExpiredTurboBonus();
`bonus_ref`=0',
__FILE__, __LINE__);
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
// Update user profiles
if (isExtensionInstalledAndNewer('order', '0.1.1')) {
// Latest version
// Free memory
SQL_FREERESULT($result_daily);
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
// Include it
loadIncludeOnce('inc/mails/doubler_mails.php');
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
// Check for holidays we need to enable and send email to user
$result_main = SQL_QUERY("SELECT
`userid`, `holiday_activated`
// Stop currently activated holidays
stopHolidays();
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
if ((isSendProfileUpdateEnabled()) && (getProfileUpdate() > 0) && (getResendProfileUpdate() > 0)) {
// Load personal data
$result = SQL_QUERY("SELECT
SQL_FREERESULT($result);
} // END - if
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
// Reset surfbar counter
updateConfiguration(array('surfbar_daily_counter', 'surfbar_yester_counter'), array(0, getConfig('surfbar_daily_counter')));
setConfigEntry('surfbar_yester_counter', getConfig('surfbar_daily_counter'));
setConfigEntry('surfbar_daily_counter' , 0);
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset started.');
+
// Simply reset the requests here
updateConfiguration('yoomedia_requests_remain', getConfig('yoomedia_requests_total'));
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Daily reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Weekly reset started.');
+
// Start your weekly-reset things here
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Weekly reset ended.');
+
// [EOF]
?>
return;
}
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Weekly reset started.');
+
// Reset the surfbar counter
updateConfiguration('surfbar_weekly_counter', 0);
+// Debug line
+//* DEBUG: */ logDebugMessage(__FILE__, __LINE__, 'Weekly reset ended.');
+
// [EOF]
?>
return $GLOBALS[__FUNCTION__];
}
+// "Getter" for last_month
+function getLastMonth () {
+ // Do we have cache?
+ if (!isset($GLOBALS[__FUNCTION__])) {
+ // Determine it
+ $GLOBALS[__FUNCTION__] = getConfig('last_month');
+ } // END - if
+
+ // Return cache
+ return $GLOBALS[__FUNCTION__];
+}
+
// Checks wether proxy configuration is used
function isProxyUsed () {
// Do we have cache?
<tr>
<td align="right">{--ADMIN_OPTION_CSS_PHP--}:</td>
<td>
- <input type="radio" class="form_field" name="css_php" value="DIRECT"$content[css_php_direct] /> {--ADMIN_CSS_PHP_DIRECT--}<br />
- <input type="radio" class="form_field" name="css_php" value="FILE"$content[css_php_file] /> {--ADMIN_CSS_PHP_FILE--}<br />
- <input type="radio" class="form_field" name="css_php" value="INLINE"$content[css_php_inline] /> {--ADMIN_CSS_PHP_INLINE--}
+ <input type="radio" class="form_field" name="css_php" value="DIRECT"$content[css_php_direct] /> {--ADMIN_SELECT_CSS_OUTPUT_MODE_DIRECT--}<br />
+ <input type="radio" class="form_field" name="css_php" value="FILE"$content[css_php_file] /> {--ADMIN_SELECT_CSS_OUTPUT_MODE_FILE--}<br />
+ <input type="radio" class="form_field" name="css_php" value="INLINE"$content[css_php_inline] /> {--ADMIN_SELECT_CSS_OUTPUT_MODE_INLINE--}
</td>
</tr>
<tr>
<td align="right">{--ADMIN_OPTION_GUEST_MENU--}:</td>
<td>
- <input type="radio" class="form_field" name="guest_menu" value="Y"$content[guest_menu_y] /> {--ADMIN_GUEST_MENU_ACTIVE--}<br />
- <input type="radio" class="form_field" name="guest_menu" value="N"$content[guest_menu_n] /> {--ADMIN_GUEST_MENU_INACTIVE--}
+ <input type="radio" class="form_field" name="guest_menu" value="Y"$content[guest_menu_y] /> {--ADMIN_IS_SHOWN--}<br />
+ <input type="radio" class="form_field" name="guest_menu" value="N"$content[guest_menu_n] /> {--ADMIN_IS_NOT_SHOWN--}
</td>
</tr>
<tr>
<td align="right">{--ADMIN_OPTION_MEMBER_MENU--}:</td>
<td>
- <input type="radio" class="form_field" name="member_menu" value="Y"$content[member_menu_y] /> {--ADMIN_MEMBER_MENU_ACTIVE--}<br />
- <input type="radio" class="form_field" name="member_menu" value="N"$content[member_menu_n] /> {--ADMIN_MEMBER_MENU_INACTIVE--}
+ <input type="radio" class="form_field" name="member_menu" value="Y"$content[member_menu_y] /> {--ADMIN_IS_SHOWN--}<br />
+ <input type="radio" class="form_field" name="member_menu" value="N"$content[member_menu_n] /> {--ADMIN_IS_NOT_SHOWN--}
</td>
</tr>
<tr>
<td align="right">{--ADMIN_OPTION_YOURE_HERE--}:</td>
<td>
- <input type="radio" class="form_field" name="youre_here" value="Y"$content[youre_here_y] /> {--ADMIN_YOURE_HERE_ACTIVE--}<br />
- <input type="radio" class="form_field" name="youre_here" value="N"$content[youre_here_n] /> {--ADMIN_YOURE_HERE_INACTIVE--}
+ <input type="radio" class="form_field" name="youre_here" value="Y"$content[youre_here_y] /> {--ADMIN_IS_SHOWN--}<br />
+ <input type="radio" class="form_field" name="youre_here" value="N"$content[youre_here_n] /> {--ADMIN_IS_NOT_SHOWN--}
</td>
</tr>