What function can be used in PHP to filter and validate data?
- filter_var()
- validate_data()
- sanitize_data()
- clean_data()
In PHP, the filter_var() function is commonly used to filter and validate data. It allows you to apply various filters to sanitize and validate input data, such as filtering for specific data types, validating email addresses, sanitizing URLs, and more. The filter_var() function is a versatile tool for data validation and sanitization in PHP. For more information, refer to: http://php.net/manual/en/function.filter-var.php
Loading...
Related Quiz
- In PHP, Form Handling involves collecting, processing, and responding to user data submitted through ______.
- Which type of variable in PHP is accessible anywhere in the script?
- How do you use the $_REQUEST superglobal in PHP?
- In PHP, you can start a session using the session_start() ______.
- You have a PHP script and you need to access data sent via the GET method from a form. How would you do this using the $_GET superglobal?