LOS ANGELES -- Adam Wainwright had to work. Then he had to wait. But it was worth it as the right-hander ended a slump in a 2-1 Cardinals win over the Dodgers at Dodger Stadium on Friday night.

Wainwright picked up with his first win in five starts, his first win away from Busch Stadium and his best performance regardless of outcome in three starts. He was backed by yet another home run from the scorching Ryan Ludwick, while Ryan Franklin managed not to be derailed by a freak rainstorm in the ninth inning.

The Cardinals' ace pitched seven strong innings, allowing one run on five hits, for his best start since pitching seven scoreless innings on May 7. He struck out five, walked two and needed only 89 pitches to record 21 outs. In short, he looked like the man who pitched like gangbusters over the season's first five weeks.

"It wasn't easy, but I felt very in control of everything," Wainwright said. "I felt like I was always dictating what was happening out there. Even with guys in scoring position, I was very confident with the way I was throwing the ball that I was going to get out of it."

The game was delayed for more than an hour in the ninth inning when heavy rain struck Chavez Ravine. A gray and damp night turned into a rainy night with one out and Franklin pitching with a full count to Matt Kemp. Once play started, Franklin sealed the deal for his third save, though matters got very interesting.

Franklin walked Kemp when play resumed, and two batters later he walked Delwyn Young. But he struck out pinch-hitter Andruw Jones to deliver the victory.

"I was upset that they stopped the game, because I was two pitches from getting out of it -- could have been," Franklin said. "But that was the right call, because I was slipping all over the place out there. My push-off foot was sliding. It was definitely the right call to make."

Said Wainwright: "I knew Frankie was going to pull through."

Had the Dodgers rallied, it would have marked the fourth time in 10 starts that Wainwright was deprived of a well-earned win. In three previous games, he pitched 6 1/3 innings or more, allowed two earned runs or fewer and received no decision. In two of those games, the Cardinals won but Wainwright did not. It's an indication of the shaky value of the win stat for pitchers, but it's also somewhat irritating for a pitcher.

"It's frustrating, but as long as we're winning the games, I really don't care," Wainwright said. "Wins are cool, no doubt about it. You feel good about yourself pitching. But as long as we're winning the games, [it's no problem]."

The Dodgers put a runner on base against Wainwright in every inning, and they put a man in scoring position with fewer than two outs on four different occasions. Yet the right-hander was able to bear down when he got in trouble, relying frequently on a curveball that had fierce movement.

"When you've got that going, you can do some cool things," he said.

Wainwright got all the offensive help he needed from the hottest Cardinal, Ludwick. The outfielder cranked his 13th home run, a no-doubt shot to straightaway center field in the third inning, for the Redbirds' only runs against Derek Lowe. Albert Pujols walked in front of Ludwick, who has gone deep nine times in his last 15 games.

Ludwick is one homer short of his career high, set last year in 303 at-bats. With three hits, he raised his batting average to .348 on the year, best on the team.

"I'm just trying to stick with that approach of going up there, get a good pitch to hit and hit it hard," Ludwick sid. "I guess I've been in situations where hits are falling when there are some runners on base. It's worked out all right, I guess."

The Cardinals remained one game behind the first-place Cubs in the National League Central. Chicago beat the Pirates earlier in the evening.