PHP str_split()Functions
Definition and Usage
The str_split() function splits a string into an array.
Syntax
str_split(string,length)
| Parameter | Description |
|---|---|
| string | Required. Specifies the string to split. |
| length | Optional. Specifies the length of each array element. Default is 1. |
Technical Details
| Return value: | If length is less than 1, the str_split() function will return FALSE. If length is greater than the length of the string, the entire string will be returned as the only element of the array. |
|---|---|
| PHP Version: | 5+ |
More Examples
PHP String Reference Manual Other Extensions