X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Frequest-functions.php;h=bf045e11feb4ab76c248045395363b71abc972ba;hb=5fcc4a6ee46b5fc4bc8bee9f71fa5078fc25c5a9;hp=0ae3de0a6a52c4d17edc49eb04507f38ddf6a8b6;hpb=2592ef433edd0c7cbde318e76792a521b6ec155e;p=mailer.git diff --git a/inc/request-functions.php b/inc/request-functions.php index 0ae3de0a6a..bf045e11fe 100644 --- a/inc/request-functions.php +++ b/inc/request-functions.php @@ -113,7 +113,7 @@ function REQUEST_SET_GET ($element, $value) { } // Wrapper for elements in $_POST -function REQUEST_POST ($element, $subElement=-1) { +function REQUEST_POST ($element, $subElement=null) { // By default no element is there $value = null; @@ -126,7 +126,7 @@ function REQUEST_POST ($element, $subElement=-1) { $value = $GLOBALS['raw_request']['post'][$element]; // Is $subElement set? - if (($subElement != -1) && (REQUEST_ISSET_POST($element, $subElement))) { + if ((!is_null($subElement)) && (REQUEST_ISSET_POST($element, $subElement))) { // Then use this $value = SQL_ESCAPE($value[$subElement]); } elseif (!is_array($value)) {