You are here

function assert_request_vars_all in Lingotek Translation 7.5

Same name and namespace in other branches
  1. 7.7 lib/oauth-php/example/server/core/init.php \assert_request_vars_all()
  2. 7.2 lib/oauth-php/example/server/core/init.php \assert_request_vars_all()
  3. 7.3 lib/oauth-php/example/server/core/init.php \assert_request_vars_all()
  4. 7.4 lib/oauth-php/example/server/core/init.php \assert_request_vars_all()
  5. 7.6 lib/oauth-php/example/server/core/init.php \assert_request_vars_all()

File

lib/oauth-php/example/server/core/init.php, line 112

Code

function assert_request_vars_all() {
  foreach ($_REQUEST as $row) {
    foreach (func_get_args() as $a) {
      if (!isset($row[$a])) {
        header('HTTP/1.1 400 Bad Request');
        echo 'Bad request.';
        exit;
      }
    }
  }
}