I work for a major pharma company and have worked on a chlamydia vaccine. So I know some have tried, but a couple things have prevented it most of it comes down to money and non-science related issues 1. Most STDs are not life-threatening and can be cured with regular anti-biotics. Because of that there is little need for a prophylactic vaccine. Whereas flu, pneumonia measles, etc kills many people a year or can have lasting negative effects, when is the last time you heard of a person dying from gonorrhea or chlamydia.
2. There may be social resistance. There was social resistance to the HPV vaccine which may because conservatives thought that it would result in girls having more sex.