1 Find character position function:
Strpos ($str, Search,[int]): Find the first position of search in $str starting from int;
Stripos ($str, search,[int]): function returns the position where the string first appears in another string. This function is not sensitive to case
Strrpos ($str, Search,[int]): Find the last occurrence of search in $str from int
2. Extract the character function (double byte)
Submit ($str, int start[,int length]): Extracts [length string] from strat position in $str.
Strstr ($str 1, $str 2): Searches the $str2 from the $STR1 (the first position) and intercepts it to the ending string, or false if not.
The STRISTR () feature is the same as STRSTR, but is case-insensitive.
STRRCHR () return from the last search to the word entered prompt; use: take the filename in the path
3. Replacement string
Str_replace (Search,replace, $STR): Search from $STR Replace with replace
Str_irreplace (Search,replace, $STR):
STRTR ($str, search,replace): Replace cannot be "" in this function;
Substr_replace ($Str, $rep, $start [, length]) $str The original string, $rep replaced by the new
The string, $start the starting position, $length the length of the replacement, which is optional
4, character length
int strlen ($STR)
5. Comparing character functions
int strcmp ($str 1, $str 2): $str 1>=< $str 2 is positive 1,0,-1 (string comparison)
STRCASECMP () ditto (case-insensitive)
STRNATCMP ("4", "14") compare strings by natural sort
STRNATCASECMP () ditto, (case-sensitive)