Protecting yourself against HIV is about knowledge. Understanding how you get (and avoid getting) HIV, and knowing yourself and your partner (or partners), are key to protecting yourself against HIV.
Many people who "know better" engage in risky activities. The reasons for this are numerous and normal: you could be afraid to insist that your partner use a condom; you may not want to use a condom yourself, you could make false assumptions about partners (they seem too young, old, healthy-looking, or nice to be HIV positive); you might be a drinker or recreational drug user who does things while under the influence that you wouldn't otherwise consider. The hardest part of protecting yourself can be learning how to apply what you know to your life and behavior.
Be safe and smart with your decisions. Reduce your risk of becoming HIV infected by avoiding activities that put you at risk and by only practicing safer sex. Don't be afraid to get tested or to insist that your partner get tested; knowing your HIV status and that of your partner (or partners) will help you make more informed decisions.