What could be the cause?

31 weeks and 5 days pregnant with severe cramps all over stomach and diarrhea, what could be causing it?