Menu
i should know this one but don’t.
given a string …
$str = “hello my name is bob.”
how would i replace only the first space character
with some default text $default = “###”;
so $str would become “hello###my name is bob.”
i tried str_replace but it seems it will always replace all occurences
thanks