Handymail - Secure class.
This class handles secure form element specific validation & Filtering
| package |
HandyMail |
|---|---|
| author |
I.G Laghidze developer@firewind.co.uk |
alphanumeric(string|array $input) : boolean
| access |
private |
|---|
string|arrayThe submitted field input.
booleanTrue if validation passes, false upon failure.
apply_filters(string $input, array $filters) : string
stringThe input string.
arrayAn array of filters to be parsed.
stringThe modified input string.
apply_validation(string $input, string $id, array &$fields, array $rules) : array
stringThe submitted field input.
stringThe field ID.
arrayReference array of defined field objects.
arrayArray of rules
arrayAn array of errors. If empty, validation has passed.
escape_html(string|array $input) : string|array
| access |
private |
|---|
string|arrayThe submitted field input.
string|arrayThe filtered field input with escaped html tags.
forbidden(string|array $input, array $keys) : boolean
string|arrayThe submitted field input.
arrayAn array of forbidden keywords.
booleanIf false, no forbidden keywords found - otherwise returns an array of forbidden keywords (evaluating to boolean true). IMPORTANT that false is good here.
hash_input(string|array $input) : string|array
| access |
private |
|---|
string|arrayThe submitted field input.
string|arrayThe hashed field input.
limit(string|array $input, integer $limit) : boolean
| access |
private |
|---|
string|arrayThe submitted field input.
integerThe maximum number of permitted characters.
booleanTrue if validation passes, false upon failure.
match(string|array $input, $match) : boolean
| access |
private |
|---|
string|arrayThe submitted field input.
booleanTrue if matched, false upon failure.
nl2br_recursive(string|array $input) : string|array
| access |
private |
|---|
string|arrayThe submitted field input.
string|arrayThe modified field input.
numeric(string|array $input) : boolean
| access |
private |
|---|
string|arrayThe submitted field input.
booleanTrue if validation passes, false upon failure.
required(string|array $input) : boolean
| access |
private |
|---|
string|arrayThe submitted field input.
booleanTrue if not empty, false if empty.
strip_html(string|array $input) : string|array
| access |
private |
|---|
string|arrayThe submitted field input.
string|arrayThe filtered field input with stripped HTML tags.
trim_input(string|array $input) : string|array
| access |
private |
|---|
string|arrayThe submitted field input.
string|arrayThe trimmed field input.
valid_email(string|array $input) : boolean
| access |
private |
|---|
string|arrayThe submitted field input.
booleanTrue if validation passes, false upon failure.