UK[rɪˈpleɪs] US[rɪˈples]
vt.Replace; replace; put... back into its original place; (with...) replace
Third person singular: replaces Present participle: replacing Past tense: replaced Past participle: replaced
php str_ireplace() function syntax
Function:String replacement operation, case-insensitive
Syntax:str_ireplace(find,replace,string,count)
Parameters:
Parameters | Description |
find | Required. Specifies the value to look for. |
replace | Required. Specifies the value to replace the value in find . |
string | Required. Specifies the string to be searched for. |
count | Optional. A variable counting the number of substitutions. |
Description:Replace some characters in the string (not case sensitive). The function must follow the following rules: If the searched string is an array, then it will return an array. If the string being searched is an array, then it will find and replace each element in the array. If both an array search and a replace are required, and the number of elements to be replaced is less than the number of elements found, the excess elements will be replaced with an empty string. If you search an array and replace only one string, the replacement string will apply to all found values.
php str_ireplace() function example
Output:
Hello php.cn!
Output:
Hi php.cn!