Updated

Cole Hamels pitched seven solid innings and helped the Philadelphia Phillies defeat the New York Mets, 6-2, in the third contest of a four-game series at Citi Field.

Hamels (6-13) struck out eight and gave up two runs on nine hits and a walk. Despite only winning twice in his last nine starts, the 29-year-old southpaw has not lost since July 26. He drove in two runs.

"That's kind of the thing about baseball is that you have to keep pressing and digging deep because eventually good things will come," said Hamels.

Carlos Ruiz hit a solo shot while Jimmy Rollins. Kevin Frandsen and John Mayberry Jr. had an RBI apiece for the Phillies, who have won twice in this series.

Ike Davis and Andrew Brown each drove in a run for the Mets, who have lost six of their last seven games. Starter Daisuke Matsuzaka (0-2) allowed four runs on six hits and four walks over 4 1/3 innings.

"He's a great pitcher and has fantastic command of his pitches," said Brown about Hamels. "When you have command of your stuff like he did tonight, it's tough to get anything going."

The Mets got on the board in the third. Eric Young Jr. hit into a fielder's choice to center and stole second. After Juan Lagares walked and Brown fouled out, Davis delivered an RBI single to left.

The Phillies responded in the fourth. With two outs and a man on second, Rollins ripped an RBI double to left.

An inning later, they scored three runs. Ruiz knocked a one-out single, Michael Young hit a ground-rule double to right and Cody Asche walked, loading the bases. Mayberry was then hit by a pitch.

Matsuzaka was replaced by Robert Carson, but after striking out pinch-hitter Darin Ruf, he gave up an two-run single to left from Hamels.

Ruiz homered to left off Carson in the sixth.

In the seventh, pinch-hitter Daniel Murphy singled and later stole third. Brown then brought him home with a two-out double to left-center.

The Phillies tacked on a run in the ninth. John McDonald reached first on an error by Wilmer Flores. After a grounder from Mayberry and a single by Ruf, pinch-hitter Frandsen reached first on a fielding error by Mets reliever Scott Atchison, and McDonald scored.

Game Notes

Hamels has allowed three earned runs or less in each of his last seven starts, including an eight-inning shutout on August 1 ... Asche is on a nine-game hitting streak ... Roger Bernadina went 0-for-6 with three strikeouts ... Philadelphia hit 4-for-18 with runners in scoring position and stranded 14 ... The Phillies have won nine of their last 12 games at Citi Field, outscoring the Mets, 65-35 ... Philadelphia's Ethan Martin is scheduled to face New York's Carlos Torres in Thursday's series finale.