X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmodules%2Fmember%2Fwhat-sponsor.php;h=b951a952774c117ad20f266d56d6bbf4461d7837;hb=3afdce4fe00b4af570122ce7b8158ced44aec7d3;hp=942f1c79773fc1532b1a7d8b98a43cb0d30fa2e5;hpb=fb7120ffa230b62b54895bcf95952e1cf30f8594;p=mailer.git diff --git a/inc/modules/member/what-sponsor.php b/inc/modules/member/what-sponsor.php index 942f1c7977..b951a95277 100644 --- a/inc/modules/member/what-sponsor.php +++ b/inc/modules/member/what-sponsor.php @@ -37,17 +37,17 @@ // 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()) { - LOAD_URL("modules.php?module=index"); -} elseif ((!EXT_IS_ACTIVE("sponsor")) && (!IS_ADMIN())) { - addFatalMessage(__FILE__, __LINE__, getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), "sponsor"); + redirectToUrl('modules.php?module=index'); +} elseif ((!EXT_IS_ACTIVE('sponsor')) && (!IS_ADMIN())) { + addFatalMessage(__FILE__, __LINE__, sprintf(getMessage('EXTENSION_PROBLEM_EXT_INACTIVE'), 'sponsor')); return; } // Add description as navigation point -ADD_DESCR("member", __FILE__); +ADD_DESCR('member', __FILE__); // Loads the name-matching template LOAD_TEMPLATE(substr(basename(__FILE__), 5, -4));