String Decomposition Functions | |
---|---|
explode() | |
array explode(string $sDelimiter, string $sOriginal, integer $iMaxSplit = PHP_INT_MAX) | |
This function returns an array of strings that contain portions of $sOriginal that are split by the entire string $sDelimiter. | |
Argument | Description |
string $sDelimiter | This is the delimiter string that is used to split $sOriginal. The function will return FALSE if this is an empty string. |
string $sOriginal | This is the string that is split. |
integer $iMaxSplit | This is the maximum number of pieces of $sOriginal that are returned. The last entry will contain the rest of the string. |
implode() | |
string implode(string $sJoint, array $saPieces) | |
string implode(array $saPieces, string $sJoint = "") | |
This function returns an string that is composed of the pieces of $saPieces joined together by $sJoint. | |
Argument | Description |
string $sJoint | This is the string that is put between each piece. |
array $saPieces | This is the string pieces that are put together. |
join() | |
This function is the same as implode(). | |
parse_str() | |
void parse_str(string $sGetUrl, array &$sarKeyValuePairs) | |
This function returns takes a string URL in the form of a get with name/value pairs encoded in it and splits the values into the array entries of &$sarNameValuePairs with the names as keys to the corresponding values. | |
Argument | Description |
string $sGetUrl | This is the URL that is parsed. |
array &$sarKeyValuePairs | This is the set of resulting key/value pairs. |
str_getcsv() | |
array str_getcsv(string $sOriginal, string $sDelimiter = ",", string $sEnclosure = '"', string $sEscape = "/") | |
This function returns an array of strings consisting of the parts of $sOriginal delimited by $sDelimiter. The parts inside sets of $sEnclosure pairs are not delimited. | |
Argument | Description |
string $sOriginal | This is the string that is broken up into substrings. |
string $sDelimiter | This is delimiter that is used to split the string. |
string $sEnclosure | This encloses portion of string that are not split. |
string $sEscape | This is the escape character for special characters. |
str_split() | |
array str_split(string $sOriginal, integer $iSplitLength = 1) | |
This function returns an array of characters of size $iSplitLength or less for the remainder.. | |
Argument | Description |
string $sString | This is a string that will be measured. |
integer $iSplitLength | This is the maximum length of a section. |
strtok() | |
array strtok(string $sOriginal, string $sDelimiterSet = ",") | |
This function returns the array of substrings of the string $sOriginal that are split by the set of characters in the string $sDelimiterSet.. | |
Argument | Description |
string $sOriginal | This is a string that will be measured. |
string $sDelimiterSet | This is the set of delimiter characters that split the string. |
© 20072024 XoaX.net LLC. All rights reserved.