Ophthalmic ofloxacin ophthalmic is used to treat bacterial infections of the eye, including conjunctivitis (Pink eye) and ulcers of the cornea. Ofloxacin is in a class of medications called quinolone antibiotics. It works by killing bacterial cells that cause infection.