MIAMI - A rout turned into a heart-stopper when the Florida Marlins nearly blew a big lead against Philadelphia.
Thanks to Chad Fox, the Marlins held on. Now they have their biggest lead of the season in the NL wild-card race, with more thrills to come.
Philadelphia scored five in the eighth before Fox ended the threat with two runners aboard, and the Marlins won 6-5 Wednesday night to edge closer to their first playoff berth since 1997.
Florida leads the Phillies and Astros by three with four to go.
The Phillies said the game was one they had to win, and they rallied after falling behind 6-0. But Fox struck out Chase Utley to end the eighth, and Ugueth Urbina pitched a perfect ninth.
"We were not going to lose," Fox said.
"That would have been a tough one to swallow if we had let that get away," said Florida's Jeff Conine, who homered for the second game in a row.
The Marlins can clinch a playoff berth today and eliminate Philadelphia by completing a sweep of their three-game series.
"If I'm in their clubhouse, it's time to get going," Fox said. "But they're not going to get it done here."
Phils catcher Mike Lieberthal all but conceded the race to the Marlins.
"If we win every game from here on out, we probably still won't get in," he said. "It's theirs to hold on to."
The Marlins started strong, and by the sixth they literally had the Phillies ducking out of the way. Third baseman Placido Polanco scrambled to avoid being beaned by a broken bat on a run-scoring single by Miguel Cabrera.
Juan Encarnacion's 18th home run put Florida ahead to stay, and Josh Beckett took a two-hit shutout into the eighth.
Beckett sent the Phillies to their fourth consecutive loss.
"Beckett dominated us," manager Larry Bowa said. "That's the best stuff we've seen all year."
The right-hander's next start could come in the first game of the playoffs Tuesday at San Francisco.
"We haven't opened the champagne yet," Beckett said. "I just want to be in one of those celebrations."
The Marlins won for the 13th time in their past 15 home games, and they beat Brett Myers for the fourth time this season.
But Philadelphia made it harrowing. The eighth-inning rally began with consecutive singles by Utley, pinch-hitter Ricky Ledee and Marlon Byrd. Polanco's two-run double finished Beckett.
Michael Tejera gave up a two-run single to Bobby Abreu and walked Jim Thome. Both runners advanced on a wild pitch by Fox, and Conine made a running catch of Lieberthal's sacrifice fly in deep left to make it 6-5.
Pat Burrell flied out and Jimmy Rollins walked before Fox struck out Utley.
"It got a little scary at the end," Marlins manager Jack McKeon said. "I didn't like that."