str_ireplace()

It replaces some characters in a string (case-insensitive)

Example

<?php
echo  str_ireplace(“phpcodez”, “phpcode”, “phpcodez”);
?>

Output

phpcode