X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fwrapper-functions.php;h=60fccd2839885a52905aa0d3061e090bb1ade3ec;hb=b6a6d0a2c0a0f274b937eb75c413db8fa9b44f9c;hp=fe5834dcd714c9193771088455116752f3d19e7a;hpb=1d22c70e65e858422ee0d17a7612f4b5c0757a42;p=mailer.git diff --git a/inc/wrapper-functions.php b/inc/wrapper-functions.php index fe5834dcd7..60fccd2839 100644 --- a/inc/wrapper-functions.php +++ b/inc/wrapper-functions.php @@ -673,6 +673,27 @@ function setModule ($newModule) { $GLOBALS['__module'] = strtolower($newModule); } +// Wrapper to get extra module names +function getExtraModule () { + // Default is 'NULL' + $extra = 'NULL'; + + // Is 'tab/step' set? + if (isPostRequestElementSet('tab')) { + // Use this + $extra = 'tab=' . postRequestElement('tab'); + } elseif (isPostRequestElementSet('step')) { + // Use this + $extra = 'step=' . postRequestElement('step'); + } elseif ((isActionSet()) && (isWhatSet())) { + // Use 'action/what' + $extra = 'action=' . getAction() . ':what=' . getWhat(); + } + + // Return it + return $extra; +} + // Checks whether module is set and optionally aborts on miss function isModuleSet ($strict = FALSE) { // Check for it