Jump to content

Replace (number of occurances) and ignorecase


Recommended Posts

Hi all,I'm using preg_replace function to replace a part of string with another in my whole string for the first 2 occurances.. but this function is not working if my string was like this:$string = "SEARCH the web";I mean it dosen't ignore case .. so that it will not change the word "SEARCH" if i used "search" to replace it..is there anyway to do this??Thanks,zeid

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...