Post game review of the fouls to determine if any diving was going on. Any dives would come with a stiff penalty (like a 5-10 game suspension). I promise you the diving would evaporate within a single year.
For something like the WC, 2-3 game suspension. Basically a no tolerance policy. You don't get warnings or anything like that, you just get suspended for a handful of games.
Better way to eliminate flopping in soccer? Eliminate the game completely. Nobody would miss it and hundreds of spectators would be saved every year. Win-Win.