Donovan, a hero of the United States' recent victory in the Gold Cup tournament, produced a hat trick Sunday. He scored twice in a span of less than 10 minutes during the second half while rallying Los Angeles into a 3-2 lead.
Perez, however, scored off a free kick that came about when the Galaxy's Leonardo was called for a hand ball.
Los Angeles (10-9-4) moved into a tie with Seattle for fifth place with 34 points in the tightly bunched Western Conference. Colorado and Portland have 35 points and Vancouver has 36 -- five behind conference-leading Real Salt Lake.
Dallas, which had its winless streak extended to 10 matches, has 33 points. Dallas got off to an 8-2-3 start this season, but since then has gone 0-4-6.
Donovan scored in first-half stoppage time to tie it at 1-1. After Perez scored in the 48th minute, Donovan produced goals in the 73rd and 82nd minutes to put the Galaxy in front.
Notable deaths of 2014 [PHOTOS]