The Dodgers lost their fifth in a row and fell out of a first-place tie with San Francisco in the National League West.
Elian Herrera delivered an RBI triple in the fourth and then scored on a single by Juan Rivera to end a 33-inning LA scoring drought and bring the Dodgers back from an early 2-0 deficit.
New York quickly regained the lead, however, when Mike Nickeas singled with one out in the fifth, advanced to second on a sacrifice by pitcher Chris Young and scored on the double by Torres.
Young (2-1) went 6 1/3 innings in his fifth start since returning from shoulder surgery. He gave up both Los Angeles runs on six hits with six strikeouts and no walks.
Bobby Parnell, handed the New York closer's role while Frank Francisco is on the disabled list, worked a perfect ninth for his first save. Parnell had blown 15 of 22 saves opportunities over the past five seasons.
Chris Capuano (9-3) surrendered the double to Torres and took the loss in a seven-inning effort. Capuano suffered his first loss in five starts.
David Wright drove in the first two New York runs with a double in the first and a homer in the fourth.