How about only conditionally add in the :? Check if $3 has content and add it, otherwise leave it out.