There are many types of eye infection that you or your child may get. Sties can be very painful and look really ugly. A sty is caused when an eyelash follicle becomes inflamed and infected. A white, pus-filled bump can form inside the eyelid or on the very edge of the eyelid.