What types of data can be validated using the filter_var() function in PHP?
- Email addresses
- URLs
- IP addresses
- All of the above
The filter_var() function in PHP can be used to validate various types of data, including email addresses, URLs, and IP addresses. It provides specific filters for each of these data types, allowing you to perform validation based on their respective formats and rules. The filter_var() function offers flexibility in data validation for multiple data types. For further information, refer to: http://php.net/manual/en/function.filter-var.php
Loading...
Related Quiz
- The value of a class constant in PHP cannot be changed once it is ______.
- The elseif statement in PHP is used to specify a new condition to test if the first condition is ______.
- How can we pass a variable through navigation between pages?
- How do you connect to a MySQL database in PHP?
- You are writing a PHP script and you need to start a session. How would you do this?