PHOENIX -- The Dodgers were going to head back to Los Angeles from a successful road trip regardless of what happened in their series finale against Arizona. To close it out with a dramatic comeback and complete a three-game sweep, they couldnt have scripted it any better. Hanley Ramirez and A.J. Ellis hit consecutive homers in the 14th inning after Ellis tied the game with two outs in the ninth, helping the Los Angeles Dodgers beat first-place Arizona 7-5 Wednesday night for their first sweep of the Diamondbacks in two years. "For us to walk out of here fighting and grinding the way we did, its going to make for a real fun trip home," Ellis said. Los Angeles won six of its first eight games on the road trip, including the first two against Arizona. The Dodgers closed it out with a flourish. With the Dodgers still in it because of Ellis hit in the ninth off Heath Bell, Ramirez hit the first pitch of the 14th off Josh Collmenter (4-2) just over the wall in right field. Five pitches later, Ellis made it 7-5 with his fourth homer. Kenley Jansen (3-3) pitched the final two innings for the Dodgers, who used all of their position players and had Zack Greinke, Mondays starter, pinch hit in the 10th inning. A team that was 12 games under .500 and 9 1/2 games out of first on June 22, the Dodgers are back to .500 and 1 1/2 games back of the Diamondbacks in the NL West after winning 15 of 18. "Obviously, you want to come in and win a series, but to win three was big for us because its a two-game swing when youre playing them," Dodgers manager Don Mattingly said. "I really felt like before we got here, we really got ourselves back into it, where we were in the race and we knew it. This has been icing on the cake." Arizona went through eight pitchers in the 19th game in the majors to go at least 14 innings this season, according to STATS. There were 20 total last season. Aaron Hill homered and drove in two runs, and Paul Goldschmidt hit a two-run double for the Diamondbacks, who went seven innings -- until two outs in the 12th -- without a hit. Arizona appeared to be in position for the victory after Bell got two quick outs. But, as has been the case lately, the Diamondbacks couldnt hold the lead. Adrian Gonzalez, who led off the seventh inning with a solo homer, worked a two-out walk off Bell in the ninth inning, then Ramirez moved pinch runner Jerry Hairston to second with a single. Ellis followed with his tying single off Bell, his fifth blown save and the Diamondbacks 19th. "We have to figure out some things so guys can get some outs later in the game," Diamondbacks manager Kirk Gibson said. The more than five-hour game started with the teams trading leads. Tyler Skaggs had a superb return to Arizonas rotation on Friday, allowing three hits and striking out five in eight scoreless innings against Colorado after being called up from Triple-A Reno. The left-hander wasnt nearly as good against the Dodgers, giving up a run on Scott Van Slykes sacrifice fly in the fourth inning and a two-run double to Ramirez that put the Dodgers up 3-2 in the fifth. Skaggs then walked two to load the bases, but reliever Will Harris prevented further damage by getting Van Slyke to hit into an inning-ending double play. Skaggs allowed three runs on eight hits in 4 1-3 innings. Hyun-Jin Ryu wasnt much better. He gave up a solo homer to Hill in the first inning and a sacrifice fly to him in the third. Given the lead back, Ryu allowed a pair of one-out singles in the fifth and Goldschmidt followed with his two-run double. Martin Prado made it 5-3 with a run-scoring single. Ryu allowed five runs on seven hits in five innings, the second time in 18 starts hes failed to reach the sixth inning. Gonzalez led off the seventh inning with his 14th homer off David Hernandez to cut Arizonas lead to 5-4, then set the tying run after fouling off five pitches from Bell, whos allowed nine runs his past 11 outings. "I feel really bad because I left everybody down," Bell said. "We definitely should have won that game." Even after Bells blowup, the Diamondbacks had chances, as did the Dodgers. But, with fans falling asleep in the stands, Ramirez and Ellis finally put the Dodgers ahead for good, sending them home with an exclamation point to their successful road trip. "We might be the only team in baseball not looking forward to the All-Star break," Ellis said. NOTES: Dodgers 2B Skip Schumaker sat out and will not play Thursday after having his two-game suspension upheld by Major League Baseball. He was one of eight people suspended following a bench-clearing brawl against Arizona on June 11. ... The Dodgers Ricky Nolasco and Greinke, who started the series first two games, were the first pair of starting pitchers to go at least a combined 5-for-5 at the plate in consecutive games since Cincinnatis Tim Pugh and John Smiley did it May 6-7, 1994, according to information provided to the Dodgers by the Elias Sports Bureau. ... Wade Miley will pitch for Arizona in the opener of a four-game series against Milwaukee on Thursday. The left-hander won for the first time in a month by allowing a run in eight innings against the Rockies on Saturday. ... RHP Yovani Gallardo, who will start against the Diamondbacks, has allowed 15 earned runs over his past three starts. Jarrod Dyson Jersey . -- Charline Labonte couldnt have asked for a better homecoming. Randy Johnson Jersey . Louis Cardinals. Victorino is batting sixth and playing right field after missing two games because of back tightness. http://www.diamondbackssale.com/diamondbacks-matt-szczur-jersey/ . After Gasquet beat fifth-seeded Ivan Dodig of Croatia 7-5, 6-3, Tsonga followed up with a 6-7 (3), 6-2, 6-2 win against sixth-seeded Edouard Roger-Vasselin in an all-French match. Wilmer Flores Jersey .S. -- Nikolaj Ehlers registered a hat trick for the third straight game and Jonathan Drouin had a goal and five assists as the Halifax Mooseheads hammered the host Cape Breton Screaming Eagles 10-1 on Tuesday in Quebec Major Junior Hockey League action. Archie Bradley Jersey . I cant pinpoint a date, but I do remember a player from my youth. Brian Downing was with the Chicago White Sox at a time when I listened to every game I possibly could on the radio. That particular season the late great Harry Caray was calling the White Sox games. BASTAD, Sweden -- Top-seeded Serena Williams advanced to the second round of the Swedish Open by beating Sesil Karatancheva of Kazakhstan 6-1, 6-2 Tuesday. Williams broke Karatanchevas serve five times, twice in the first set and three times in the second, to advance at the clay-court tournament on Swedens west coast. She will next face Anna Taatishvili of Georgia, who beat 16-year-old Belinda Bencic of Switzerland 2-6, 6-4, 6-4.dddddddddddd Third-seeded Klara Zakopalova of the Czech Republic, sixth-seeded Lesia Tsurenko of Ukraine, Mathilda Johansson of France, Teliana Pereira of Brazil, Richel Hogenkamp of the Netherlands and Andrea Gamiz of Venezuela also advanced. ' ' '