Gonzalez got the ball rolling with one away in the first inning. Shortly after Craig Counsell singled to lead off the inning, Gonzalez connected on a 1-0 fastball from Maddux (0-1) for a two-run homer that put Arizona in the early lead.
The Cubs would strike back a half inning later in the second when a Jeromy Burnitz double and a Derrek Lee walk set the stage for Todd Hollandsworth, who crushed a three-run home run to right center that made it 3-2. The home run moved Hollandsworth to 14 shy of 100 for his career.
But Gonzalez and the Diamondbacks eventually proved too much for Maddux and company. Gonzalez led off the fourth inning with his second homer of the night, a solo shot to right that tied the game at three. The home runs were the eighth and ninth of his career off Maddux.
Chad Tracy singled to open the fifth and advanced to second one batter later when Chris Snyder hit a bouncer to Nomar Garciaparra, who then missed a tag on Tracy allowing Snyder to reach first with a fielders choice. Ortiz (1-0) followed with a single to right, putting the Diamondbacks back on top at 4-3. Counsell then added an RBI single of his own to extend the lead to 5-3.
The Cubs rallied for a run in the eighth when Corey Patterson singled to open the inning and Todd Walker followed with a double to put runners on second and third. Garciaparra's RBI groundout brought the Cubs to within one, but right-hander Brandon Lyon got Aramis Ramirez swinging and Jeromy Burnitz on a groundout to retire the side.
The Cubs threatened again in the ninth as Lee led off the inning with a single. Lyon, however, retired Hollandsworth and Michael Barrett on flyouts and then got pinch-hitter Neifi Perez on a groundout when shortstop Royce Clayton made a sliding stop to keep the ball in play.
Maddux allowed five runs on six hits in five innings and is now winless in his last seven starts against the Diamondbacks dating back to Sept. 7, 2000. He struck out six and walked one. Lyon recorded his first career National League save and his first overall since June 26, 2003 while pitching with the Red Sox.
Ryan Dempster will start the final game of the series for the Cubs Thursday at 9:10 p.m. CDT against Arizona right-hander Brandon Webb.