strcspn – PHP String Functions
Syntax : strcspn ( string, char, start, length); Description : strcspn() function will returns the number of characters found in a string before any part of the specified characters are found....
Syntax : strcspn ( string, char, start, length); Description : strcspn() function will returns the number of characters found in a string before any part of the specified characters are found....
Syntax : strcoll ( string1, string2 ); Description : strcoll() function will function compares two strings based on locale and this comparison is case sensitive. Note : If the current locale...
Syntax : strcmp ( string1, string2 ); Description : strcmp() function will compare two strings. This is case-sensitive function. Note : Binary safe and case-sensitive function. Parameter : string1 – This is a...
Syntax : stristr ( string, search, before_search ); Description : stristr() function will find the first occurrence of search in a string. This is case-insensitive function. Note : This function is binary-safe....
Syntax : strchr ( string, search, before_search ); Description : strchr() function will find the first occurrence of search in a string. This function is an alias of the strstr() function. Note :...
Syntax : strstr ( string, search, before_search ); Description : strstr() function will find the first occurrence of search in a string Note : This function is binary-safe. Note : This function...
Syntax : strcasecmp ( string1, string2 ); Description : strcasecmp() function will compare two strings. Note : Binary safe case-insensitive string comparison function. Parameter : string1 – This is a Required parameter. It...
Syntax : str_word_count (string, returnformat, characterlist ); Description : str_word_count() function will counts the number of words in a string. Parameter : string – This is a Required parameter. It is the...
Syntax : str_split ( string, length ); Description : str_split() function will breaks a string into an array. Parameter : string – This is a Required parameter. It is the input string...
Syntax : str_shuffle (string ); Description : str_shuffle() function will shuffles a string randomly. Parameter : string – This is a Required parameter. It is the input string on which shuffle will...
Syntax : str_rot13 ( string ); Description : str_rot13() function Perform the ROT13 transform/encoding and decoding on a string. The ROT13 encoding simply shifts every letter by 13 places in the...
Syntax : str_replace ( find, replace, string, count ); Description : str_replace() function will replace all occurrences of the search string with the replacement string. It is case – sensitive function....
Syntax : str_repeat (string, repeat ); Description : str_repeat() function repeats a string a specified number of times.. Parameter : string – This is a Required parameter. It is the input string which...
Syntax : str_pad (string, length, pad_string, pad_type ); Description : str_pad() function will pad a string to a certain length with another string. Parameter : string – This is a Required parameter....
Syntax : str_ireplace ( find, replace, string, count ); Description : str_ireplace() function will replace all occurrences of the search string with the replacement string. It is case – insensitive function....
Syntax : str_getcsv ( string, separator, enclosure, escape ); Description : str_getcsv() function parse a CSV string into an array Parameter : string – This is a Required parameter. This is a string which...
Syntax : html_entity_decode ( strings, flags, encoding/character-set ); Description : html_entity_decode() function will converts HTML entities to their applicable characters. Note : htmlentities() function is reverse of it. Parameter : strings – This...
Syntax : htmlentities ( strings, flags, encoding/character-set, double_encode ); Description : htmlentities() function will converts all possible characters to HTML entities. Note : html_entity_decode() function is reverse of it. You can convert...
Syntax : ltrim ( string, charlist ); Description : ltrim() function will truncate spaces or other characters from starting of input string. We can remove “hi” from the starting of input string...
Syntax : rtrim ( string, charlist ); Description : rtrim() function will truncate spaces or other characters from the end of input string. We can remove “es.” from the end of input...