static function str_replace_first($from, $to, $content)
    {
        $from = '/'.preg_quote($from, '/').'/';
        return preg_replace($from, $to, $content, 1);
    }
static function str_replace_first($from, $to, $content)
    {
        $from = '/'.preg_quote($from, '/').'/';
        return preg_replace($from, $to, $content, 1);
    }
static function str_replace_first ( $ from , $ to , $ content ) { $ from = '/' . preg_quote ( $ from , '/' ) . '/' ; return preg_replace ( $ from , $ to , $ content , 1 ) ; }
Return string with replaced first occurerence only

@param string $from    The needle
@param string $to      The replacement
@param string $content The haystack

@return string String with replaced first occurerence only
Return string with replaced first occurerence only