Foligno put a backhander past Jacob Markstrom that extended the Senators' winning streak to four games. The goal came on a rebound from a slap shot from the right circle by Daniel Alfredsson.
Florida had tied it at 3-3 with only 47 seconds left on a goal by Kris Versteeg, his fifth of the season.
Ottawa twice came back from a one-goal deficit and took a 3-2 lead with 2:07 to go in the third on a score by Colin Greening. That set up the dramatics of the final minute which ended Florida's winning streak at two.
Craig Anderson won his fourth straight game by making 22 saves. Markstrom stopped 34 shots.
Celebrity Breakups and divorces of 2014 [PHOTOS]