Which of the following are true about the $_REQUEST superglobal in PHP?

  • It is a built-in global variable in PHP.
  • It is used to retrieve the values of both GET and POST requests.
  • It is considered a security risk and should not be used.
  • It is used to access session data.
The $_REQUEST superglobal in PHP is a built-in global variable that allows access to values from both GET and POST requests. It provides a convenient way to handle user input data regardless of the HTTP method used. However, it's important to note that using $_REQUEST indiscriminately can pose security risks, so it's recommended to use specific superglobals like $_GET or $_POST when handling user input. Learn more: https://www.php.net/manual/en/reserved.variables.request.php
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *