PHILADELPHIA (AP) -- Chase Utley walked with the bases loaded in the bottom of the ninth inning, lifting the Philadelphia Phillies to a 4-3 comeback victory over the Arizona Diamondbacks on Friday night.
Cody Asche led off the ninth with a single and went to third on Jimmy Rollins' single. Heath Bell (4-2) intentionally walked Michael Young to load the bases for Kevin Frandsen. After striking out Frandsen, Bell was lifted for left-hander Eury De La Rosa.
De La Rosa ran the count to 3-2 and Utley walked when the final pitch appeared to be a bit inside.
It was the fifth win in six games for the Phillies, who have won four of those contests in their last at-bat.
Darin Ruf homered for the second straight game for Philadelphia, which improved to 5-3 under interim manager Ryne Sandberg. Ruf has eight homers and 12 RBIs in 21 games this month.
Matt Davidson had two hits and an RBI for the Diamondbacks, who have dropped four of five, damaging their fleeting playoff hopes. Coming into the day, Arizona was 9 1/2 games back of the Dodgers in the NL West and seven back of the Reds for the second NL wild-card spot.
Jonathan Papelbon (4-1) pitched a scoreless ninth for the win.
The Phillies jumped to a 1-0 lead on Ruf's two-out homer in the second. The Diamondbacks answered with three runs in the fourth off hard-luck Cole Hamels.
Paul Goldschmidt was credited with a double after left fielder Domonic Brown lost his routine fly ball in the lights. Martin Prado drove in Goldschmidt and Adam Eaton with a two-run double, and Davidson's RBI single put Arizona ahead 3-1.
That was it for the Diamondbacks against Hamels, who allowed six hits and walked one in seven innings. The left-hander has a 1.89 ERA in his last five starts but has just one win and four no-decisions over that stretch.
Hamels, who entered with the fifth-lowest run support average among starters in the majors (3.30), remained 5-13 on the season.
The Phillies tied it when Carlos Ruiz hit a two-run double off Wade Miley in the sixth. Miley finished the inning to complete his outing, yielding five hits and two walks.
The Phillies threatened in the eighth against Bell, putting runners on first and second with two outs. But Bell struck out John Mayberry Jr. swinging to end the inning.
The Diamondbacks got a runner to second with two outs in the ninth off Papelbon, but Cliff Pennington flew out to center to end the threat.
NOTES: Ruiz went 2 for 4, raising his average to .600 (12 for 20) in his last six games. . The three-game series resumes Saturday night when Phillies RHP Ethan Martin (2-2, 5.23 ERA) opposes RHP Randall Delgado (4-4, 3.82 ERA). ... The Phillies wore maroon and white pinstriped uniforms similar to what the club wore in the 1990s on '90s night. ... Frandsen snapped an 0-for-17 skid with a sixth-inning single.