X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmodules%2Fguest%2Faction-admin.php;h=038bf7cc91875671f489edb0363a6754ec36e918;hb=c809d01655c73f8dbd2042ab917d8527ceec4a92;hp=68567e02b2f5be23a2f333a728dc21ddd02910bc;hpb=b73c135350d7ed266c0cac680105707139bd892d;p=mailer.git diff --git a/inc/modules/guest/action-admin.php b/inc/modules/guest/action-admin.php index 68567e02b2..038bf7cc91 100644 --- a/inc/modules/guest/action-admin.php +++ b/inc/modules/guest/action-admin.php @@ -35,18 +35,19 @@ if (!defined('__SECURITY')) { $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php"; require($INC); +} elseif ($GLOBALS['block_mode']) { + // Block mode detected + return; } -if (GET_ACTION("guest", $GLOBALS['what']) == "admin") { - // Only when one admin link is clicked... - $INC = sprintf("%sinc/modules/guest/what-%s.php", PATH, $GLOBALS['what']); - if (FILE_READABLE($INC)) { - // Ok, we finally load the guest action module - include($INC); - } else { - ADD_FATAL(GUEST_404_ACTION_1.$GLOBALS['what'].GUEST_404_ACTION_2); - } -} // END - if +// Only when one admin link is clicked... +$INC = sprintf("inc/modules/guest/what-%s.php", SQL_ESCAPE($GLOBALS['what'])); +if (INCLUDE_READABLE($INC)) { + // Ok, we finally load the guest action module + LOAD_INC($INC); +} else { + addFatalMessage(__FILE__, __LINE__, getMessage('GUEST_404_ACTION'), $GLOBALS['what']); +} // ?>