Filters Filter Functions

suggest change

Versions

[{“Name”:“5.0”,“GroupName”:“PHP 5.x”},{“Name”:“5.1”,“GroupName”:“PHP 5.x”},{“Name”:“5.2”,“GroupName”:“PHP 5.x”},{“Name”:“5.3”,“GroupName”:“PHP 5.x”},{“Name”:“5.4”,“GroupName”:“PHP 5.x”},{“Name”:“5.5”,“GroupName”:“PHP 5.x”},{“Name”:“5.6”,“GroupName”:“PHP 5.x”},{“Name”:“7.0”,“GroupName”:“PHP 7.x”},{“Name”:“7.1”,“GroupName”:“PHP 7.x”}]

Introduction

This extension filters data by either validating or sanitizing it. This is especially useful when the data source contains unknown (or foreign) data, like user supplied input. For example, this data may come from an HTML form.

Syntax

Parameters

Parameter| Details| —— | —— | variable| Value to filter. Note that scalar values are converted to string internally before they are filtered.| —— | —— | filter | The ID of the filter to apply. The Types of filters manual page lists the available filters.If omitted, FILTER_DEFAULT will be used, which is equivalent to FILTER_UNSAFE_RAW. This will result in no filtering taking place by default. | —— | —— | options| Associative array of options or bitwise disjunction of flags. If filter accepts options, flags can be provided in “flags” field of array. For the “callback” filter, callable type should be passed. The callback must accept one argument, the value to be filtered, and return the value after filtering/sanitizing it. |

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:


Filters, filter functions:
* Filters Filter Functions

Table Of Contents
2 Arrays
4 Types
10 Cookies
14 JSON
15 SOAP
17 cURL
19 XML
21 Traits
31 Filters, filter functions
35 UTF-8
36 URLs
38 PHPDoc
41 Loops
44 Closur
72 YAML
77 Cache
78 Streams
81 PDO
82 SQLite3
83 Sockets
87 MongoDB
93 IMAP
94 Redis
95 Imagick
102 APCu
108 PSR