public static function addNew(string $add, string $existing, string $concatenateWith = ' ')
    {
        if (!strpos($existing, $add)) :
            return sprintf("%s%s%s", $existing, $concatenateWith, $add);
        endif;

        return $existing;
    }
public static function addNew(string $add, string $existing, string $concatenateWith = ' ')
    {
        if (!strpos($existing, $add)) :
            return sprintf("%s%s%s", $existing, $concatenateWith, $add);
        endif;

        return $existing;
    }
public static function addNew ( string $ add , string $ existing , string $ concatenateWith = ' ' ) { if ( ! strpos ( $ existing , $ add ) ) : return sprintf ( "%s%s%s" , $ existing , $ concatenateWith , $ add ) ; endif ; return $ existing ; }
Concatenates a string to another string, if it isn't already
a substring of it.

@param string $add               The string to be added.
@param string $existing          The existing string.
@param string $concatenateWith   (option) String to concatenate with. Defaults to ' '.
@return string                   Returns concatenated string (if $add isn't a substring)
and original string (if $add is a substring).
Concatenates a string to another string if it isn t already a substring of it .