It could have been due to sweat dermatitis. The main treatment for sweat dermatitis is prevention. The best thing to consider is to prevent that portion of the body from sweating like by wearing light and cotton clothes,taking cool refreshing baths,maintaining the temperature in your homes and cars and avoiding strenuous activities.
If however sweat dermatitis occurs,then apply mild corticosteroid creams like dermacort or hydrocortisone or calamine lotion on the rashes.
It is very difficult to precisely confirm a diagnosis without examination and investigations and the answer is based on the medical information provided. For exact diagnosis, you are requested to consult your doctor. I sincerely hope that helps. Take care and please do keep me posted on how you are doing.