diarrhea in a baby

Karla
So my baby has diarrhea I already took him to his doctor and she told me to only give him pedialyte. I am not breastfeeding only he is drinking that. He is 7 months old. I dont know why it happen I breastfeed him and he eats but only fruits and veggies. It really suxs. 😕😕