From d997f1621c6e6e0427166bd96690e0825387dadd Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Tue, 9 Sep 2008 00:36:48 +0000 Subject: [PATCH] Unlock of booked URLs in surfbar added, fix for URL-encoded links in loader module --- .gitattributes | 4 + inc/databases.php | 7 +- inc/functions.php | 8 +- inc/language/surfbar_de.php | 13 ++- inc/libs/surfbar_functions.php | 99 +++++++++++++++++-- inc/modules/admin/what-list_surfbar_urls.php | 3 +- .../admin/what-unlock_surfbar_urls.php | 50 +++++++++- inc/modules/frametester.php | 7 +- inc/modules/loader.php | 2 +- inc/mysql-manager.php | 36 +++---- surfbar.php | 4 +- .../admin/admin_surfbar_url_confirmed.tpl | 28 ++++++ .../member/member_surfbar_url_confirmed.tpl | 19 ++++ .../de/html/admin/admin_list_surfbar_urls.tpl | 5 +- .../admin/admin_list_surfbar_urls_row.tpl | 3 + .../html/admin/admin_unlock_surfbar_urls.tpl | 24 +++++ .../admin/admin_unlock_surfbar_urls_row.tpl | 20 ++++ 17 files changed, 290 insertions(+), 42 deletions(-) create mode 100644 templates/de/emails/admin/admin_surfbar_url_confirmed.tpl create mode 100644 templates/de/emails/member/member_surfbar_url_confirmed.tpl create mode 100644 templates/de/html/admin/admin_unlock_surfbar_urls.tpl create mode 100644 templates/de/html/admin/admin_unlock_surfbar_urls_row.tpl diff --git a/.gitattributes b/.gitattributes index 858b7a8899..09f59dacc6 100644 --- a/.gitattributes +++ b/.gitattributes @@ -600,6 +600,7 @@ templates/de/emails/admin/admin_support-order.tpl -text templates/de/emails/admin/admin_support-ordr.tpl -text templates/de/emails/admin/admin_support-reflink.tpl -text templates/de/emails/admin/admin_support-unconfirmed.tpl -text +templates/de/emails/admin/admin_surfbar_url_confirmed.tpl -text templates/de/emails/admin/admin_surfbar_url_reg.tpl -text templates/de/emails/admin/admin_surfbar_url_unlock.tpl -text templates/de/emails/admin/admin_transfer_ap.tpl -text @@ -665,6 +666,7 @@ templates/de/emails/member/member_support-order.tpl -text templates/de/emails/member/member_support-ordr.tpl -text templates/de/emails/member/member_support-reflink.tpl -text templates/de/emails/member/member_support-unconfirmed.tpl -text +templates/de/emails/member/member_surfbar_url_confirmed.tpl -text templates/de/emails/member/member_surfbar_url_reg.tpl -text templates/de/emails/member/member_surfbar_url_unlock.tpl -text templates/de/emails/member/member_transfer_recipient.tpl -text @@ -1029,6 +1031,8 @@ templates/de/html/admin/admin_unlock_emails_redir_row.tpl -text templates/de/html/admin/admin_unlock_emails_row.tpl -text templates/de/html/admin/admin_unlock_sponsor.tpl -text templates/de/html/admin/admin_unlock_sponsor_row.tpl -text +templates/de/html/admin/admin_unlock_surfbar_urls.tpl -text +templates/de/html/admin/admin_unlock_surfbar_urls_row.tpl -text templates/de/html/admin/admin_update_download.tpl -text templates/de/html/admin/admin_user_details.tpl -text templates/de/html/admin/admin_validate_reset_hash_form.tpl -text diff --git a/inc/databases.php b/inc/databases.php index ba57bc56fa..2057f1310a 100644 --- a/inc/databases.php +++ b/inc/databases.php @@ -93,13 +93,10 @@ define('START_YDAY', MAKE_TIME(0, 0, 0, time() - ONE_DAY)); define('START_TDAY', MAKE_TIME(0, 0, 0, time())); $COOKIES = substr(URL, strpos(substr(URL, 8), "/") + 8); -if ((strpos($COOKIES, "/") == "0") && (strpos(substr(URL, 8), "/") > 0)) -{ +if ((strpos($COOKIES, "/") == "0") && (strpos(substr(URL, 8), "/") > 0)) { // Script was installed into a sub directory if (substr($COOKIES, -1) != "/") $COOKIES .= "/"; -} - else -{ +} else { // No more sub directories added to URL $COOKIES = "/"; } diff --git a/inc/functions.php b/inc/functions.php index 8875dc134d..0f4f995d6d 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -198,6 +198,9 @@ function LOAD_TEMPLATE($template, $return=false, $content="") { // Add more variables which you want to use in your template files global $DATA, $_CONFIG, $username; + // Make all template names lowercase + $template = strtolower($template); + // Count the template load if (!isset($_CONFIG['num_templates'])) $_CONFIG['num_templates'] = 0; $_CONFIG['num_templates']++; @@ -550,7 +553,7 @@ function TRANSLATE_COMMA ($dotted, $cut=true) { // function DEREFERER ($URL) { - $URL = URL."/modules.php?module=loader&url=".urlencode(base64_encode(gzcompress(COMPILE_CODE($URL)))); + $URL = URL."/modules.php?module=loader&url=".urlencode(base64_encode(gzcompress($URL))); return $URL; } @@ -667,6 +670,9 @@ function SET_LANGUAGE($lang) { function LOAD_EMAIL_TEMPLATE($template, $content="", $UID="0") { global $DATA, $_CONFIG, $REPLACER; + // Make sure all template names are lowercase! + $template = strtolower($template); + // Keept for backward-compatiblity (please replace these variables against our new {--CONST--} syntax!) $MAIN_TITLE = MAIN_TITLE; $URL = URL; $WEBMASTER = WEBMASTER; $surname = ""; $family = ""; $nick = ""; $sex = "N"; diff --git a/inc/language/surfbar_de.php b/inc/language/surfbar_de.php index 54a81ee1f7..19d9446dfb 100644 --- a/inc/language/surfbar_de.php +++ b/inc/language/surfbar_de.php @@ -37,7 +37,7 @@ if (basename($_SERVER['PHP_SELF']) == basename(__FILE__)) { require($INC); } -// General admin text +// Configuration strings in admin area define('ADMIN_CONFIG_SURFBAR_TITLE', "Konfiguration der Surfbar"); define('ADMIN_CONFIG_SURFBAR_STATIC_REWARD', "Statische Vergütung:"); define('ADMIN_CONFIG_SURFBAR_STATIC_COSTS', "Statische Kosten:"); @@ -52,12 +52,17 @@ define('ADMIN_CONFIG_SURFBAR_MAX_ORDER', "Maximal durch Mitglied in Surfbar buch define('ADMIN_CONFIG_SURFBAR_RESTART_TIME', "Ruhezeit der Surfbar, wenn alle URLs in Reload-Lock sind:"); define('ADMIN_CONFIG_SURFBAR_AUTOSTART', "Surfbar soll nach Ruhezeit automatisch starten?"); define('ADMIN_CONFIG_SURFBAR_STATS_RELOAD', "Reload-Zeit der Statistik unterhalb der beworbenen Seite:"); +define('ADMIN_CONFIG_SURFBAR_NOTE', "(*): Es sind auch die Übertragungen der URLs aus der Mailbuchung einbezogen. Es wird empfohlen, die Ruhezeit etwas länger als die Reload-Sperre einzustellen."); + +// General admin text define('ADMIN_SURFBAR_NOTIFY_UNLOCK_YES', "Ja, Admin(s) informieren."); define('ADMIN_SURFBAR_NOTIFY_UNLOCK_NO', "Nein, nicht informieren."); define('ADMIN_SURFBAR_NO_REF_LEVELS_FOUND', "Zur Zeit sind keine Referal-Ebenen für die Surfbar eingestellt.
\nBitte installieren Sie die Erweiterung surfbar neu."); define('ADMIN_SURFBAR_ADD_NEW_REFDEPTH', "Neue Referal-Ebene zur Surfbar hinzufügen"); define('ADMIN_SURFBAR_NO_URLS_FOUND', "Es konnten keine URLs in der Surfbar gefunden werden."); define('ADMIN_SURFBAR_REWARD', "Vergütung"); +define('ADMIN_SURFBAR_COSTS', "Kosten"); +define('ADMIN_SURFBAR_PAYMENT', "Payment"); define('ADMIN_SURFBAR_VIEWS_TOTAL', "Gesamtaufrufe"); define('ADMIN_SURFBAR_STATUS', "URL-Status"); define('ADMIN_SURFBAR_REGISTERED', "URL aufgenommen"); @@ -66,7 +71,9 @@ define('ADMIN_SURFBAR_LOCK_REASON', "Sperrgrund"); define('ADMIN_SURFBAR_EDIT_URL', "URL ändern"); define('ADMIN_SURFBAR_DEL_URL', "URL löschen"); define('ADMIN_SURFBAR_UNLOCK_URL', "URL ent-/sperren"); -define('ADMIN_CONFIG_SURFBAR_NOTE', "(*): Es sind auch die Übertragungen der URLs aus der Mailbuchung einbezogen. Es wird empfohlen, die Ruhezeit etwas länger als die Reload-Sperre einzustellen."); +define('ADMIN_SURFBAR_CONFIRM_URL', "URL(s) freigeben"); +define('ADMIN_SURFBAR_UNLOCK_DONE', "Freischaltung ausgewählter URL(s) vollständig. :-)"); +define('ADMIN_SURFBAR_UNLOCK_FAILED', "Freischaltung fehlgeschlagen. Bitte nachschauen, welche URLs nicht freigegeben wurden."); // General member text define('MEMBER_SURFBAR_URL_ADDED', "URL hinzugefügt und wartet auf Freischaltung."); @@ -77,10 +84,12 @@ define('MEMBER_SURFBAR_NO_MORE_ALLOWED', "Sie können leider nicht mehr URLs // Subject lines for admins define('ADMIN_SURFBAR_NOTIFY_URL_UNLOCK_SUBJECT', "URL in Surfbar gebucht"); define('ADMIN_SURFBAR_NOTIFY_URL_REG_SUBJECT', "Mitglied hat URL in Surfbar gebucht"); +define('ADMIN_SURFBAR_NOTIFY_URL_CONFIRMED_SUBJECT', "URL in Surfbar freigegeben"); // Subhect lines for members define('MEMBER_SURFBAR_NOTIFY_URL_UNLOCK_SUBJECT', "Ihre URL wurde in die Surfbar aufgenommen"); define('MEMBER_SURFBAR_NOTIFY_URL_REG_SUBJECT', "Ihre URL in der Surfbar wartet auf Freischaltung"); +define('MEMBER_SURFBAR_NOTIFY_URL_CONFIRMED_SUBJECT', "Ihre URL wurde für die Surfbar freigegeben"); // URL status define('SURFBAR_URL_STATUS_CONFIRMED', "Freigegeben"); diff --git a/inc/libs/surfbar_functions.php b/inc/libs/surfbar_functions.php index 560c4897c2..3e0a103c8a 100644 --- a/inc/libs/surfbar_functions.php +++ b/inc/libs/surfbar_functions.php @@ -37,7 +37,11 @@ if (ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) { require($INC); } -// Admin has added an URL with given user id +// ----------------------------------------------------------------------------- +// Admin functions +// ----------------------------------------------------------------------------- + +// Admin has added an URL with given user id and so on function SURFBAR_ADMIN_ADD_URL ($url, $uid, $reward, $costs, $paymentId) { // Do some pre-checks if (!IS_ADMIN()) { @@ -57,6 +61,37 @@ function SURFBAR_ADMIN_ADD_URL ($url, $uid, $reward, $costs, $paymentId) { // Register the new URL return SURFBAR_REGISTER_URL($url, $uid, $reward, $costs, $paymentId, "CONFIRMED", "unlock"); } +// Admin function for unlocking URLs +function SURFBAR_ADMIN_UNLOCK_URL_IDS ($IDs) { + // Is this an admin or invalid array? + if (!IS_ADMIN()) { + // Not admin or invalid IDs array + return false; + } elseif (!is_array($IDs)) { + // No array + return false; + } elseif (count($IDs) == 0) { + // Empty array + return false; + } + + // Set to true to make AND expression valid if first URL got unlocked + $done = true; + + // Update the status for all ids + foreach ($IDs as $id => $dummy) { + // Test all ids through (ignores failed) + $done = (($done) && (SURFBAR_CHANGE_STATUS($id, "PENDING", "CONFIRMED"))); + } // END - if + + // Return total status + return $done; +} + +// ----------------------------------------------------------------------------- +// Member functions +// ----------------------------------------------------------------------------- + // Member has added an URL function SURFBAR_MEMBER_ADD_URL ($url) { global $_CONFIG; @@ -83,6 +118,10 @@ function SURFBAR_MEMBER_ADD_URL ($url) { // Register the new URL return SURFBAR_REGISTER_URL($url, $GLOBALS['userid'], $reward, $costs); } +// ----------------------------------------------------------------------------- +// Generic functions +// ----------------------------------------------------------------------------- + // Looks up by an URL function SURFBAR_LOOKUP_BY_URL ($url) { // Now lookup that given URL by itself @@ -104,12 +143,19 @@ function SURFBAR_GET_URL_DATA ($searchTerm, $column="id", $order="id", $sort="AS $searchTerm = bigintval($searchTerm); } // END - if + // If the column is "id" there can be only one entry + $limit = ""; + if ($column == "id") { + $limit = "LIMIT 1"; + } // END - if + // Look up the record $result = SQL_QUERY_ESC("SELECT id, userid, url, reward, costs, views_total, status, registered, last_locked, lock_reason FROM "._MYSQL_PREFIX."_surfbar_urls WHERE %s='%s' -ORDER BY %s %s", - array($column, $searchTerm, $order, $sort), __FILE__, __LINE__); +ORDER BY %s %s +%s", + array($column, $searchTerm, $order, $sort, $limit), __FILE__, __LINE__); // Is there at least one record? if (SQL_NUMROWS($result) > 0) { @@ -600,9 +646,48 @@ function SURFBAR_DETERMINE_TOTAL_ONLINE () { // Return result return $cnt; } -// Determine next id for surfbar view, always call this before you call other +// Changes the status of an URL from given to other +function SURFBAR_CHANGE_STATUS ($id, $prevStatus, $newStatus) { + // Get URL data for status comparison + $data = SURFBAR_GET_URL_DATA($id); + + // Is the status like prevStatus is saying? + if ($data[$id]['status'] != $prevStatus) { + // No, then abort here + return false; + } // END - if + + // Update the status now + SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_surfbar_urls SET status='%s' WHERE id=%s LIMIT 1", + array($newStatus, bigintval($id)), __FILE__, __LINE__); + + // Was that fine? + if (SQL_AFFECTEDROWS() != 1) { + // No, something went wrong + return false; + } // END - if + + // Prepare content for notification routines + $data[$id]['uid'] = $data[$id]['userid']; + $data[$id]['frametester'] = FRAMETESTER($data[$id]['url']); + $data[$id]['reward'] = TRANSLATE_COMMA($data[$id]['reward']); + $data[$id]['costs'] = TRANSLATE_COMMA($data[$id]['costs']); + $data[$id]['status'] = SURFBAR_TRANSLATE_STATUS($newStatus); + $data[$id]['registered'] = MAKE_DATETIME($data[$id]['registered'], "2"); + $newStatus = strtolower($newStatus); + + // Send admin notification + SURFBAR_NOTIFY_ADMIN("url_{$newStatus}", $data[$id]); + + // Send user notification + SURFBAR_NOTIFY_USER("url_{$newStatus}", $data[$id]); + + // All done! + return true; +} +// Determine next id for surfbar or get data for given id, always call this before you call other // getters below this function!!! -function SURFBAR_GET_NEXT_ID ($id = 0) { +function SURFBAR_DETERMINE_NEXT_ID ($id = 0) { global $SURFBAR_CACHE, $_CONFIG; // Default is no id! @@ -771,10 +856,10 @@ LIMIT 1", //DEBUG_LOG(__FUNCTION__.":nextId={$nextId}"); return $nextId; } -// ---------------------------------------------------------------------------- +// ----------------------------------------------------------------------------- // PLEASE DO NOT ADD ANY OTHER FUNCTIONS BELOW THIS LINE ELSE THEY "WRAP" THE // $SURFBAR_CACHE ARRAY! -// ---------------------------------------------------------------------------- +// ----------------------------------------------------------------------------- // Private getter for data elements function SURFBAR_GET_DATA ($element) { global $SURFBAR_CACHE; diff --git a/inc/modules/admin/what-list_surfbar_urls.php b/inc/modules/admin/what-list_surfbar_urls.php index 02c0b65f19..3753e8f6af 100644 --- a/inc/modules/admin/what-list_surfbar_urls.php +++ b/inc/modules/admin/what-list_surfbar_urls.php @@ -41,7 +41,7 @@ if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) || (!is_admin())) { ADD_DESCR("admin", basename(__FILE__)); // List all URLs -$result = SQL_QUERY("SELECT id, userid, url, reward, views_total, status, UNIX_TIMESTAMP(registered) AS registered, UNIX_TIMESTAMP(last_locked) AS last_locked, lock_reason +$result = SQL_QUERY("SELECT id, userid, url, reward, costs, views_total, status, UNIX_TIMESTAMP(registered) AS registered, UNIX_TIMESTAMP(last_locked) AS last_locked, lock_reason FROM "._MYSQL_PREFIX."_surfbar_urls ORDER BY id ASC", __FILE__, __LINE__); @@ -55,6 +55,7 @@ if (SQL_NUMROWS($result) > 0) { $content['userid'] = ADMIN_USER_PROFILE_LINK($content['userid']); $content['url'] = FRAMETESTER($content['url']); $content['reward'] = TRANSLATE_COMMA($content['reward']); + $content['costs'] = TRANSLATE_COMMA($content['costs']); $content['views_total'] = TRANSLATE_COMMA($content['views_total']); $content['status'] = SURFBAR_TRANSLATE_STATUS($content['status']); $content['registered'] = MAKE_DATETIME($content['registered'], 2); diff --git a/inc/modules/admin/what-unlock_surfbar_urls.php b/inc/modules/admin/what-unlock_surfbar_urls.php index c1d2d52c98..96fcf6a8a1 100644 --- a/inc/modules/admin/what-unlock_surfbar_urls.php +++ b/inc/modules/admin/what-unlock_surfbar_urls.php @@ -35,10 +35,58 @@ if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) || (!is_admin())) { $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php"; require($INC); -} +} // END - if // Add description as navigation point ADD_DESCR("admin", basename(__FILE__)); +// Is the form sent? +if ((isset($_POST['unlock'])) && (is_array($_POST['id'])) && (count($_POST['id']) > 0)) { + // Unlock selected URLs + if (SURFBAR_ADMIN_UNLOCK_URL_IDS($_POST['id'])) { + // Unlock done! :-) + LOAD_TEMPLATE("admin_settings_saved", false, ADMIN_SURFBAR_UNLOCK_DONE); + } else { + // Unlock failed! + LOAD_TEMPLATE("admin_settings_saved", false, ADMIN_SURFBAR_UNLOCK_FAILED); + } +} // END - if + +// List all URLs +$result = SQL_QUERY("SELECT id, userid, url, reward, costs, UNIX_TIMESTAMP(registered) AS registered +FROM "._MYSQL_PREFIX."_surfbar_urls +WHERE status='PENDING' +ORDER BY id ASC", __FILE__, __LINE__); + +// Do we have some URLs left? +if (SQL_NUMROWS($result) > 0) { + // List all URLs + $OUT = ""; $SW = 2; + while ($content = SQL_FETCHARRAY($result)) { + // "Translate"/add content + $content['sw'] = $SW; + $content['userid'] = ADMIN_USER_PROFILE_LINK($content['userid']); + $content['url'] = FRAMETESTER($content['url']); + $content['costs'] = TRANSLATE_COMMA($content['costs']); + $content['reward'] = TRANSLATE_COMMA($content['reward']); + $content['registered'] = MAKE_DATETIME($content['registered'], 2); + + // Load row template + $OUT .= LOAD_TEMPLATE("admin_unlock_surfbar_urls_row", true, $content); + + // Switch color + $SW = 3 - $SW; + } // END - while + + // Load main template + LOAD_TEMPLATE("admin_unlock_surfbar_urls", false, $OUT); +} else { + // No URLs in surfbar + LOAD_TEMPLATE("admin_settings_saved", false, ADMIN_SURFBAR_NO_URLS_FOUND); +} + +// Free result +SQL_FREERESULT($result); + // ?> diff --git a/inc/modules/frametester.php b/inc/modules/frametester.php index 78ab97dacc..49b06b359e 100644 --- a/inc/modules/frametester.php +++ b/inc/modules/frametester.php @@ -71,12 +71,15 @@ if (!empty($_GET['order'])) { } if ((!empty($_POST['url'])) || (!empty($_GET['url'])) || (!empty($_GET['frame']))) { + // Default URL is ours $url = URL; - if (!empty($_POST['url'])) $url = $_POST['url']; - // Decode URL if set + // Decode URL if set in GET parameters if (!empty($_GET['url'])) $url = COMPILE_CODE(gzuncompress(base64_decode(urldecode($_GET['url'])))); + // Use URL from POST data if set + if (!empty($_POST['url'])) $url = $_POST['url']; + // Add missing element $frame = ""; if (!empty($_GET['frame'])) $frame = SQL_ESCAPE($_GET['frame']); diff --git a/inc/modules/loader.php b/inc/modules/loader.php index c8c62dd353..368b613789 100644 --- a/inc/modules/loader.php +++ b/inc/modules/loader.php @@ -39,7 +39,7 @@ if (ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) { if (!empty($_GET['url'])) { // Decode URL - $url = COMPILE_CODE(@gzuncompress(base64_decode(urldecode($_GET['url'])))); + $url = COMPILE_CODE(@gzuncompress(base64_decode(str_replace(" ", "+", urldecode($_GET['url']))))); // Validate the URL if (VALIDATE_URL($url)) { diff --git a/inc/mysql-manager.php b/inc/mysql-manager.php index a519c798b1..abed7ff949 100644 --- a/inc/mysql-manager.php +++ b/inc/mysql-manager.php @@ -1235,37 +1235,37 @@ WHERE sid='%s' LIMIT 1", array($_CONFIG['online_timeout']), __FILE__, __LINE__); } // OBSULETE: Sends out mail to all administrators -function SEND_ADMIN_EMAILS($subj, $msg) -{ - $result = SQL_QUERY("SELECT email FROM "._MYSQL_PREFIX."_admins ORDER BY id", __FILE__, __LINE__); - while (list($email) = SQL_FETCHROW($result)) - { +function SEND_ADMIN_EMAILS($subj, $msg) { + // Load all admin email addresses + $result = SQL_QUERY("SELECT email FROM "._MYSQL_PREFIX."_admins ORDER BY id ASC", __FILE__, __LINE__); + while (list($email) = SQL_FETCHROW($result)) { + // Send the email out SEND_EMAIL($email, $subj, $msg); - } - // Really simple... ;-) + } // END - if + + // Free result SQL_FREERESULT($result); + + // Really simple... ;-) } // Get ID number from administrator's login name -function GET_ADMIN_ID($login) -{ +function GET_ADMIN_ID($login) { global $cacheArray; $ret = "-1"; - if (!empty($cacheArray['admins']['aid'][$login])) - { + if (!empty($cacheArray['admins']['aid'][$login])) { // Check cache $ret = $cacheArray['admins']['aid'][$login]; if (empty($ret)) $ret = "-1"; - } - else - { + } else { // Load from database $result = SQL_QUERY_ESC("SELECT id FROM "._MYSQL_PREFIX."_admins WHERE login='%s' LIMIT 1", array($login), __FILE__, __LINE__); - if (SQL_NUMROWS($result) == 1) - { + if (SQL_NUMROWS($result) == 1) { list($ret) = SQL_FETCHROW($result); - SQL_FREERESULT($result); - } + } // END - if + + // Free result + SQL_FREERESULT($result); } return $ret; } diff --git a/surfbar.php b/surfbar.php index 976cd7be95..43da016f13 100644 --- a/surfbar.php +++ b/surfbar.php @@ -117,7 +117,7 @@ if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_install } } elseif ((isset($_GET['check'])) && (isset($_GET['id'])) && (isset($_GET['salt']))) { // Dummy next id get - SURFBAR_GET_NEXT_ID($_GET['id']); + SURFBAR_DETERMINE_NEXT_ID($_GET['id']); // Check reload lock and validation code if ((!SURFBAR_CHECK_RELOAD_LOCK($_GET['id'])) && (SURFBAR_CHECK_VALIDATION_CODE($_GET['id'], $_GET['check'], $_GET['salt']))) { @@ -149,7 +149,7 @@ if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_install // Frame "top" set? if ((isset($_GET['frame'])) && ($_GET['frame'] == "top")) { // Determine next id - $nextId = SURFBAR_GET_NEXT_ID(); + $nextId = SURFBAR_DETERMINE_NEXT_ID(); // Is there a valid id? if ($nextId > 0) { diff --git a/templates/de/emails/admin/admin_surfbar_url_confirmed.tpl b/templates/de/emails/admin/admin_surfbar_url_confirmed.tpl new file mode 100644 index 0000000000..0051031721 --- /dev/null +++ b/templates/de/emails/admin/admin_surfbar_url_confirmed.tpl @@ -0,0 +1,28 @@ +{--HELLO_ADMIN--}, + +Ein Administrator hat soeben folgende URL in der Surfbar freigegeben. + +Hier sind alle Daten von der URL: +------------------------------------------ +Gebuchte URL: $content[url] +------------------------------------------ +Framekiller-Test: +$content[frametester] +------------------------------------------ +User-ID: $content[uid] +------------------------------------------ +Angemeldet: $content[registered] +------------------------------------------ +Kosten/Aufruf: $content[costs] {!POINTS!} +------------------------------------------ +Vergütung/Aufruf: $content[reward] {!POINTS!} +------------------------------------------ +Status: $content[status] +------------------------------------------ +ID in der Surfbar: $content[id] +------------------------------------------ + +{--ADMIN_THANX--} + {--YOUR--} {!MAIN_TITLE!} {--SCRIPT--} + +{!URL!}/admin.php diff --git a/templates/de/emails/member/member_surfbar_url_confirmed.tpl b/templates/de/emails/member/member_surfbar_url_confirmed.tpl new file mode 100644 index 0000000000..368912a911 --- /dev/null +++ b/templates/de/emails/member/member_surfbar_url_confirmed.tpl @@ -0,0 +1,19 @@ +{--HELLO--} Mitglied, + +Ihre gebuchte URL wurde soeben in unserer Surfbar freigegeben. + +Hier sind alle Daten: +------------------------------------------ +Gebuchte URL: $content[url] +------------------------------------------ +Ihre User-ID: $content[uid] +------------------------------------------ +Status: $content[status] +------------------------------------------ +ID in der Surfbar: $content[id] +------------------------------------------ + +Mit freundlichem Gruss, + Ihr {!MAIN_TITLE!} Team + +{!URL!} ({!WEBMASTER!}) diff --git a/templates/de/html/admin/admin_list_surfbar_urls.tpl b/templates/de/html/admin/admin_list_surfbar_urls.tpl index 725f8bd8b7..23a813ff4a 100644 --- a/templates/de/html/admin/admin_list_surfbar_urls.tpl +++ b/templates/de/html/admin/admin_list_surfbar_urls.tpl @@ -1,7 +1,7 @@
- @@ -10,6 +10,7 @@ + @@ -18,7 +19,7 @@ $content - + diff --git a/templates/de/html/admin/admin_unlock_surfbar_urls.tpl b/templates/de/html/admin/admin_unlock_surfbar_urls.tpl new file mode 100644 index 0000000000..b0b3920360 --- /dev/null +++ b/templates/de/html/admin/admin_unlock_surfbar_urls.tpl @@ -0,0 +1,24 @@ + +
+ {--EDIT_DEL_REFDEPTH--}
{--_UID--} {--ADMIN_TEST_URL--} {--ADMIN_SURFBAR_REWARD--}{--ADMIN_SURFBAR_COSTS--} {--ADMIN_SURFBAR_VIEWS_TOTAL--} {--ADMIN_SURFBAR_STATUS--} {--ADMIN_SURFBAR_REGISTERED--}
$content[reward] {!POINTS!} + $content[costs] {!POINTS!} + $content[views_total]
+ + + + + + + + + + + +$content + + + +
+ {--EDIT_DEL_REFDEPTH--} +
{--ID_SELECT--}{--_UID--}{--ADMIN_TEST_URL--}{--ADMIN_SURFBAR_REWARD--}{--ADMIN_SURFBAR_COSTS--}{--ADMIN_SURFBAR_REGISTERED--}
+
diff --git a/templates/de/html/admin/admin_unlock_surfbar_urls_row.tpl b/templates/de/html/admin/admin_unlock_surfbar_urls_row.tpl new file mode 100644 index 0000000000..40fbae4239 --- /dev/null +++ b/templates/de/html/admin/admin_unlock_surfbar_urls_row.tpl @@ -0,0 +1,20 @@ + + + + + + $content[userid] + + + {--ADMIN_TEST_URL--} + + + $content[reward] {!POINTS!} + + + $content[costs] {!POINTS!} + + + $content[registered] + + -- 2.30.2