The g (global)
modifier is on
by default in preg_replace
PHP, how can it be switched off ?
If I do a preg_replace(/n/,'',$string);
it will replace all occurrences of n
but I want to replace only the first occurrence of n
. How should I do it?