The English midfielder fell ill late last week and was close to not playing for the Galaxy but returned to the line-up to play around 80 minutes in the win which came courtesy of second-half goals from Juninho and Todd Dunivant.
"After an hour of sleep, throwing up all night it's never easy, but two of the kids are the same so I just got through it," he said.
"I think at the end of the day I played almost 80 minutes and I didn't feel great, but the important part was the three points."
Galaxy boss Bruce Arena commended Beckham for his efforts despite being well under the weather.
"David was a little sick," Arena said.
"There's a virus going around that he caught and for David to hang in there was outstanding. Showed great leadership on his part, he was not feeling well today."