Bacteria can also cause infections in the skin. Sometimes, if the infection is close to the surface, a doctor can give an antibiotic in an ointment that goes on the skin. Other skin infections are serious enough that an antibiotic that is swallowed has to be taken.