UTI, Sex and Periods??

Kaili
Hey guys! So I had a UTI about a month (if not more) end. I had sex between that time and up to now, have been drinking a ton of water and taking cranberry pills and eating healthily. I also got my period about a week ago and it's still going (which is normal for me), but I use tampons which I've read can cause vaginal tearing if the flow is too light. And as of recently, I thought I've been doing everything right to prevent a UTI, but it seems as if I may have another one. Any thing that I can do to prevent frequent UTI's (longterm or shortterm)? Might I only feel this burning sensation because I have vaginal tears from tampons?