When you have the stomach flu, the stomach flu can last from 7 to 10 days but the diarrhea should subside and go away within 3 to 4 days after the stomach flu is over.
However sometimes I've had diarrhea last up to 6 days after my stomach flu was over so it can vary from person to person.
When you have the stomach flu you should avoid eating or drinking anything containing dairy and stick to the BRAT diet which consist of Bananas, Rice, Applesauce and Toast.
Those are good foods to eat that are bland which can help with the Stomach Flu and when you just have diarrhea.