Aside from underlying medical issues, diarrhea can be brought on by bacterial or viral infections, food poisoning, specific drugs, dietary changes, and other factors.