Yes. You can get an STI while taking the birth control pill because it uses hormones to prevent pregnancy. Those hormones do not protect against STIs.