templates/de/emails/admin/admin_surfbar_url_unlock.tpl -text
templates/de/emails/admin/admin_transfer_ap.tpl -text
templates/de/emails/admin/admin_transfer_points.tpl -text
+templates/de/emails/admin/admin_undelete_active_surfbar_urls.tpl -text
templates/de/emails/admin/admin_wernis_request.tpl -text
templates/de/emails/admins/.htaccess -text
templates/de/emails/admins/admins_mail_contct_admin.tpl -text
templates/de/emails/member/member_surfbar_url_unlock.tpl -text
templates/de/emails/member/member_transfer_recipient.tpl -text
templates/de/emails/member/member_transfer_sender.tpl -text
+templates/de/emails/member/member_undelete_active_surfbar_urls.tpl -text
templates/de/emails/member/member_wernis_accepted.tpl -text
templates/de/emails/member/member_wernis_rejected.tpl -text
templates/de/emails/member/member_wernis_request.tpl -text
define('SERVER_URL', "http://www.mxchange.org");
// This current patch level
-define('CURR_SVN_REVISION', "562");
+define('CURR_SVN_REVISION', "563");
// Take a prime number which is long (if you know a longer one please try it out!)
define('_PRIME', 591623);
// Has the whole value changed?
if ("".$ret."" != "".$num."") {
// Log the values
+ print("<pre>");
+ debug_print_backtrace();
+ die("</pre>");
DEBUG_LOG(__FUNCTION__, __LINE__, " num={$num},ret={$ret}");
} // END - if
} else {
// Log invalid request
DEBUG_LOG(__FUNCTION__, __LINE__, " action={$formData['action']},id={$formData['id']},function={$functionName}");
+ ADD_FATAL(sprintf("Invalid member action! action=%s,id=%s,function=%s", $formData['action'], $formData['id'], $functionName));
}
// Return status
// Fetch the new status if found
if ($isValid) {
+ // Load new status
list($SURFBAR_CACHE['new_status']) = SQL_FETCHROW($result);
} // END - if
// Member actions
// -----------------------------------------------------------------------------
//
-// Retreat an URL
+// Retreat a booked URL
function SURFBAR_MEMBER_RETREAT_ACTION ($urlData) {
// Create the data array for next function call
$data = array(
// Simply change the status here
return SURFBAR_CHANGE_STATUS ($urlData['id'], $urlData['status'], $urlData['new_status'], $data);
}
+// Show edit form or do the changes
+function SURFBAR_MEMBER_EDIT_ACTION ($urlData) {
+ // Is the "execute" flag there?
+ if (isset($urlData['execute'])) {
+ // Execute the changes
+ return SURFBAR_MEMBER_EXECUTE_ACTION("edit", $urlData);
+ } // END - if
+
+ // Display form
+ return SURFBAR_MEMBER_DISPLAY_ACTION_FORM("edit", $urlData);
+}
+// Show delete form or do the changes
+function SURFBAR_MEMBER_DELETE_ACTION ($urlData) {
+ // Is the "execute" flag there?
+ if (isset($urlData['execute'])) {
+ // Execute the changes
+ return SURFBAR_MEMBER_EXECUTE_ACTION("del", $urlData);
+ } // END - if
+
+ // Display form
+ return SURFBAR_MEMBER_DISPLAY_ACTION_FORM("del", $urlData);
+}
+// Display selected "action form"
+function SURFBAR_MEMBER_DISPLAY_ACTION_FORM ($action, $urlData) {
+ // Translate some data
+ $urlData['registered'] = MAKE_DATETIME($urlData['registered'], "2");
+ $urlData['views_total'] = TRANSLATE_COMMA($urlData['views_total']);
+
+ // Load the form and display it
+ LOAD_TEMPLATE(sprintf("member_surfbar_%s_action_form", $action), false, $urlData);
+
+ // All fine by default ... ;-)
+ return true;
+}
//
// -----------------------------------------------------------------------------
// Self-maintenance functions
// Set default translated status
$statusTranslated = "!".$constantName."!";
- // Generate eval() command
+ // Is the constant there?
if (defined($constantName)) {
- $eval = "\$statusTranslated = ".$constantName.";";
- eval($eval);
+ // Then get it's value
+ $statusTranslated = constant($constantName);
} // END - if
// Return result
global $_CONFIG;
// Get URL data for status comparison if missing
- if (count($data) == 0) {
+ if ((!is_array($data)) || (count($data) == 0)) {
+ // Fetch missing URL data
$data = SURFBAR_GET_URL_DATA($urlId);
} // END - if
// Update the status now
- // ---------------------- Commented out for debugging member actions! -----------------------
+ // ---------- Comment out for debugging/developing member actions! ---------
//SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_surfbar_urls SET status='%s' WHERE id=%s LIMIT 1",
// array($newStatus, bigintval($urlId)), __FILE__, __LINE__);
- // ---------------------- Commented out for debugging member actions! -----------------------
+ // ---------- Comment out for debugging/developing member actions! ---------
// Was that fine?
if (SQL_AFFECTEDROWS() != 1) {
// Add other columns as well
foreach ($_POST as $key => $entries) {
- // Skip id, raw userid and 'do_lock'
- if (!in_array($key, array($idColumn, 'uid_raw', 'do_lock'))) {
+ // Skip id, raw userid and 'do_$mode'
+ if (!in_array($key, array($idColumn, 'uid_raw', ('do_'.$mode)))) {
// Are there brackets () at the end?
if (substr($entries[$id], -2, 2) == "()") {
// Direct SQL command found
$SQL .= sprintf(" %s='%s',", SQL_ESCAPE($key), SQL_ESCAPE($entries[$id]));
}
} // END - if
- } // END - if
+ } // END - foreach
// Finish SQL statement
$SQL = substr($SQL, 0, -1) . sprintf(" WHERE %s=%s AND %s='%s' LIMIT 1",
if (($values[$idx] + 0) === $values[$idx]) {
// Number detected
$all .= sprintf("%s=%s,", $entry, (float)$values[$idx]);
+ } elseif ($values[$idx] == "UNIX_TIMESTAMP()") {
+ // Function UNIX_TIMESTAMP() detected
+ $all .= sprintf("%s=%s,", $entry, $values[$idx]);
} else {
// String detected
$all .= sprintf("%s='%s',", $entry, SQL_ESCAPE($values[$idx]));
--- /dev/null
+{--HELLO_ADMIN--},
+
+Es wurde eine zuvor gelöschte URL in der Surfbar wiederhergestellt.
+
+Hier sind alle dazu:
+------------------------------------------
+URL: $content[url]
+------------------------------------------
+Framekiller-Test:
+$content[frametester]
+------------------------------------------
+User-ID: $content[userid]
+------------------------------------------
+Sperrgrund: $content[lock_reason]
+------------------------------------------
+Letzte Sperrung: $content[last_locked]
+------------------------------------------
+Angemeldet: $content[registered]
+------------------------------------------
+ID in der Surfbar: $content[id]
+------------------------------------------
+
+{--ADMIN_THANX--}
+ {--YOUR--} {!MAIN_TITLE!} {--SCRIPT--}
+
+{!URL!}/admin.php
--- /dev/null
+Hallo Mitglied,
+
+wir haben soeben Ihre zuvor gelöschte URL in der Surfbar wiederhergestellt.
+
+Hier sind alle Daten dazu:
+------------------------------------------
+Gebuchte URL: $content[url]
+------------------------------------------
+Sperrgrund: $content[lock_reason]
+------------------------------------------
+Angemeldet: $content[registered]
+------------------------------------------
+Ihre User-ID: $content[userid]
+------------------------------------------
+ID in der Surfbar: $content[id]
+------------------------------------------
+
+Mit freundlichem Gruss,
+ Ihr {!MAIN_TITLE!} Team
+
+{!URL!}/login.php ({!WEBMASTER!})