There are several ways you can avoid contracting gonorrhea.
Abstention
Easier said than done for many people, but perhaps in today's STD-challenged situation, this is the only way that's one hundred percent effective in preventing transmission of sexually transmitted diseases, including gonorrhea.
Limit your Partners
The ideal arrangement is for you to be in a monogamous long-term relationship with a partner who was tested and is known to be uninfected. If you are unable to stick to one partner, practice safe sex and avoid sexual contact with high-risk partners.
Latex Condoms
When used consistently and correctly, condoms can effectively reduce the risk of STD transmission.