X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Flibs%2Fsurfbar_functions.php;h=d928ad7df4cda025a3a27a0d0aa90ba4df3a826f;hb=c47144dd555bbab4acdf9085e4623900dedb0e7c;hp=da1f944f503b10dea2f7ce8b4218828f0e4dbd86;hpb=61b77b466ed51b55406cce2671c6ad3991b350a9;p=mailer.git diff --git a/inc/libs/surfbar_functions.php b/inc/libs/surfbar_functions.php index da1f944f50..d928ad7df4 100644 --- a/inc/libs/surfbar_functions.php +++ b/inc/libs/surfbar_functions.php @@ -42,7 +42,7 @@ if (!defined('__SECURITY')) { // ----------------------------------------------------------------------------- // // Admin has added an URL with given user id and so on -function SURFBAR_ADMIN_ADD_URL ($url, $limit) { +function SURFBAR_ADMIN_ADD_URL ($url, $limit, $reload) { // Do some pre-checks if (!IS_ADMIN()) { // Not an admin @@ -56,13 +56,16 @@ function SURFBAR_ADMIN_ADD_URL ($url, $limit) { } elseif (!SURFBAR_IF_USER_BOOK_MORE_URLS()) { // No more allowed! return false; - } elseif ("".bigintval($limit)."" != "".$limit."") { + } elseif ("".($limit + 0)."" != "".$limit."") { + // Invalid amount entered + return false; + } elseif ("".($reload + 0)."" != "".$reload."") { // Invalid amount entered return false; } // Register the new URL - return SURFBAR_REGISTER_URL($url, "0", "ACTIVE", "unlock", $limit); + return SURFBAR_REGISTER_URL($url, "0", "ACTIVE", "unlock", array('limit' => $limit, 'reload' => $reload)); } // Admin unlocked an email so we can migrate the URL function SURFBAR_ADMIN_MIGRATE_URL ($url, $uid) { @@ -158,13 +161,13 @@ function SURFBAR_MEMBER_ADD_URL ($url, $limit) { } elseif (!SURFBAR_IF_USER_BOOK_MORE_URLS($GLOBALS['userid'])) { // No more allowed! return false; - } elseif ("".bigintval($limit)."" != "".$limit."") { + } elseif ("".($limit + 0)."" != "".$limit."") { // Invalid amount entered return false; } // Register the new URL - return SURFBAR_REGISTER_URL($url, $GLOBALS['userid'], "PENDING", "reg", $limit); + return SURFBAR_REGISTER_URL($url, $GLOBALS['userid'], "PENDING", "reg", array('limit' => $limit)); } // Create list of actions depending on status for the user function SURFBAR_MEMBER_ACTIONS ($urlId, $status) { @@ -182,7 +185,7 @@ function SURFBAR_MEMBER_ACTIONS ($urlId, $status) { foreach ($actionArray as $actionId=>$action) { // Add form for this action $OUT .= sprintf("