Shane Victorino got the winning rally started with a one-out single off Bobby Parnell (2-2). After Chase Utley walked, Ken Takahashi came in and struck out Ryan Howard as the crowd at a misty Citi Field roared. But Ibanez followed with a drive over the wall in right-center for his 21st homer.
Scott Eyre (1-1) recorded the last out of the ninth to earn the win, throwing just two pitches. Ryan Madson worked the 10th for his fourth save in five opportunities and second in two days.
Parnell also got the loss Wednesday night, giving up Chase Utley's winning homer in the 11th inning of Philadelphia's 5-4 victory.
Jaime Moyer pitched six effective innings and Pedro Feliz had three hits for Philadelphia, which took two of three against second-place New York to increase its NL East lead to four games. Jimmy Rollins, Utley and Matt Stairs each drove in a run.
The Phillies went 7-3 on their 10-game trip to improve to a major league-best 23-9 on the road. They face the Boston Red Sox on Friday night in the opener of a nine-game homestand, all against AL East teams.
Carlos Beltran drove in Luis Castillo three times and Tim Redding pitched a season-high seven innings for New York, which dropped to 18-11 at its new home and will open the Subway Series Friday night against the New York Yankees.
Redding was in line for his first victory with New York before the Phillies rallied in the seventh. Feliz singled with one out and Chris Coste followed with a double to left to put runners on second and third. Stairs, hitting for Moyer, then grounded out to second, tying it at 3. Redding got Rollins to fly out to center to end the inning.
He allowed six hits and struck out six with no walks.
Castillo doubled in the first, singled in the third and doubled in the fifth. Alex Cora moved him up each time, twice with sacrifices, and Beltran took care of the rest. He had a run-scoring groundout, an RBI double and a sacrifice fly.
The sharp offensive execution came one night after the Mets stranded a season-high 16 runners, including eight from innings seven through 10.
Rollins, who returned to his customary leadoff spot Wednesday night after two games batting sixth, drove in Philly's first run with a sacrifice fly in the third. He also singled and scored on Utley's one-out double into the right-field corner in the sixth, cutting New York's lead to 3-2.
NOTES: Phillies INF Pablo Ozuna was suspended for 50 games under baseball's minor league drug program. Major League Baseball said he had an elevated ratio of testosterone to epitestosterone, a violation of its drug rules. The 34-year-old Ozuna was hitting .292 with 15 RBIs for Triple-A Lehigh Valley this season. ... Mets RHP John Maine's next start has been pushed back to Saturday, with Livan Hernandez moving up to start the Subway Series opener Friday night against the New York Yankees. Maine is working through some discomfort in the back of his surgically repaired shoulder. The Mets were off Monday, so Hernandez will be working on regular rest. ... New York Giants first-round draft pick, WR Hakeem Nicks, threw out a first pitch.
Copyright 2009 The Associated Press.