Php separator string is array explodeexplode-use one string to split another string arrayexplode (string $ separator, string $ string [, int $ limit]) This function returns an array composed of strings, each element is a substring of a string, which is separated by a string separator as a boundary point. Php separator string is an array
Explode
Explode-use one string to separate another string
Array explode (string $ separator, string $ string [, int $ limit])
This function returns an array composed of strings. each element is a substring of a string, which is separated by a string separator as a boundary point. If the limit parameter is set, the returned array contains up to limit elements, and the last element contains the rest of the string.
If separator is a null string (""), explode () returns FALSE. If the value of separator cannot be found in string, explode () returns an array containing a single string element.
If the limit parameter is negative, all elements except the last-limit element are returned. This feature is added in PHP 5.1.0.
For historical reasons, although implode () can receive two parameter sequences, explode () cannot. You must ensure that the separator parameter is prior to the string parameter.
Note: When constructing an SQL statement, the query column can be written in this way.
$ Field = explode (':', '*'); // The usage of explode is unknown today.
Official demo: