Baby butt rash

I have a 9 month old, after eating certain foods she gets a really bad red rash from her poop. It goes away after I put cream on it, but does this mean shes reacting to certain foods? Or an intolerance or something? Do I need to stop giving her these foods or carry on? Shes fine other than the red butt. Its foods like strawberries, peppers, onions etc?