1.is_array
- is_array ( mixed $var ) : bool
- Finds whether a variable is an array
2.explode
- explode ( string $delimiter , string $string [, int $limit = PHP_INT_MAX ] ) : array
- Returns an array of strings, each of which is a substring of string formed by splitting it on boundaries formed by the string delimiter.
3.implode
- implode ( string $glue , array $pieces ) : string
implode ( array $pieces ) : string - Join array elements with a glue string.
4.split
- This function was DEPRECATED in PHP 5.3.0, and REMOVED in PHP 7.0.0.
- Alternatives to this function include:
①preg_split()
②explode()
③str_split()
5.preg_split
- preg_split ( string $pattern , string $subject [, int $limit = -1 [, int $flags = 0 ]] ) : array
- Split the given string by a regular expression.
- limit
If specified, then only substrings up to limit are returned with the rest of the string being placed in the last substring. A limit of -1 or 0 means “no limit” and, as is standard across PHP, you can use NULL to skip to the flags parameter. - flags
flags can be any combination of the following flags (combined with the | bitwise operator):
PREG_SPLIT_NO_EMPTY
If this flag is set, only non-empty pieces will be returned by preg_split().
PREG_SPLIT_DELIM_CAPTURE
If this flag is set, parenthesized expression in the delimiter pattern will be captured and returned as well.
PREG_SPLIT_OFFSET_CAPTURE
If this flag is set, for every occurring match the appendant string offset will also be returned. Note that this changes the return value in an array where every element is an array consisting of the matched string at offset 0 and its string offset into subject at offset 1.
6.unset
- unset ( mixed $var [, mixed $… ] ) : void
- unset() destroys the specified variables.
- The behavior of unset() inside of a function can vary depending on what type of variable you are attempting to destroy.
7.array_change_key_case
- array_change_key_case ( array $array [, int $case = CASE_LOWER ] ) : array
- Returns an array with all keys from array lowercased or uppercased. Numbered indices are left as is.
- case
Either CASE_UPPER or CASE_LOWER (default)
8.array_chunk
- array_chunk ( array $array , int $size [, bool $preserve_keys = FALSE ] ) : array
- Chunks an array into arrays with size elements. The last chunk may contain less than size elements.
- preserve_keys
When set to TRUE keys will be preserved. Default is FALSE which will reindex the chunk numerically