PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
One solution is preg_replace (which can have a limit on the number of replacements) but if all you want is to replace the first instance some work with strpos and substr is better.