X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmodules%2Fmember%2Fwhat-surfbar_book.php;h=f98b2844e1930a4d29c58ac420072a0238d5ba1c;hb=885637e9f61f315ba051500061ec193ebc937f7b;hp=c1d861aecaa2b9b912423ef9ae5ade382031caaa;hpb=3daede4c904e23905c3e48dd6749019deca0a0e0;p=mailer.git diff --git a/inc/modules/member/what-surfbar_book.php b/inc/modules/member/what-surfbar_book.php index c1d861aeca..f98b2844e1 100644 --- a/inc/modules/member/what-surfbar_book.php +++ b/inc/modules/member/what-surfbar_book.php @@ -10,7 +10,12 @@ * -------------------------------------------------------------------- * * Kurzbeschreibung : Mitglieder koennen URLs buchen * * -------------------------------------------------------------------- * - * * + * $Revision:: $ * + * $Date:: $ * + * $Tag:: 0.2.1-FINAL $ * + * $Author:: $ * + * Needs to be in all Files and every File needs "svn propset * + * svn:keywords Date Revision" (autoprobset!) at least!!!!!! * * -------------------------------------------------------------------- * * Copyright (c) 2003 - 2008 by Roland Haeder * * For more information visit: http://www.mxchange.org * @@ -33,49 +38,49 @@ // 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 (!IS_MEMBER()) { // Redirect - LOAD_URL("modules.php?module=index"); -} elseif ((!EXT_IS_ACTIVE("surfbar")) && (!IS_ADMIN())) { - addFatalMessage(EXTENSION_PROBLEM_EXT_INACTIVE, "surfbar"); + redirectToUrl('modules.php?module=index'); +} elseif ((!EXT_IS_ACTIVE('surfbar')) && (!IS_ADMIN())) { + addFatalMessage(__FILE__, __LINE__, generateExtensionInactiveNotInstalledMessage('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, MEMBER_SURFBAR_NO_MORE_ALLOWED); -} elseif ((isset($_POST['ok'])) && (isset($_POST['limited']))) { + LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_SURFBAR_NO_MORE_ALLOWED')); +} elseif ((isFormSent()) && (REQUEST_ISSET_POST(('limited')))) { // Is limitation "no" and "limit" is > 0? - if (($_POST['limited'] == "N") && ((isset($_POST['limit'])) && ($_POST['limit'] > 0)) || (!isset($_POST['limit']))) { + if ((REQUEST_POST('limited') == 'N') && ((REQUEST_ISSET_POST(('limit'))) && (REQUEST_POST('limit') > 0)) || (!REQUEST_ISSET_POST(('limit')))) { // Set it to unlimited - $_POST['limit'] = 0; + REQUEST_SET_POST('limit', 0); } // END - if // Register the new URL - $insertId = SURFBAR_MEMBER_ADD_URL($_POST['url'], $_POST['limit']); + $insertId = SURFBAR_MEMBER_ADD_URL(REQUEST_POST('url'), REQUEST_POST('limit')); // By default something went wrong - $msg = MEMBER_SURFBAR_URL_NOT_ADDED; + $msg = getMessage('MEMBER_SURFBAR_URL_NOT_ADDED'); // Was this fine? if ($insertId > 0) { // URL added and waiting for unlock - $msg = MEMBER_SURFBAR_URL_ADDED; + $msg = getMessage('MEMBER_SURFBAR_URL_ADDED'); } // 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( - 'reward' => TRANSLATE_COMMA(SURFBAR_DETERMINE_REWARD(true)), - 'costs' => TRANSLATE_COMMA(SURFBAR_DETERMINE_COSTS(true)), + 'reward' => translateComma(SURFBAR_DETERMINE_REWARD(true)), + 'costs' => translateComma(SURFBAR_DETERMINE_COSTS(true)), 'max_order' => getConfig('surfbar_max_order'), 'curr_order' => SURFBAR_GET_TOTAL_USER_URLS() );