New United boss Graham Rix, still looking for his first win at the club, had kept faith with young keeper Simon Cox, and he was unlucky to concede after just 16 minutes as Mansfield took the lead against the run of play.
Bobby Hassell's deep free-kick was eventually knocked back by Rhys Day to Tom Curtis whose powerful low drive was only parried by the unlucky Cox for Mendes to rifle in the rebound.
Three minutes later, Cox again had no chance as the Stags doubled their lead. Jon Ashton's back-pass fell short and Colin Larkin nipped in, rounded the keeper and bent the ball into the roof of the net from an acute angle.
However the were playing the better football and were rewarded in the 34th minute when Whitehead unleashed a 25-yard screamer into the top corner from a short corner routine.
But just two minutes later Mansfield restored their two-goal advantage, Day rifling in from six yards after Neil Mackenzie's 25-yard free-kick was blocked.
From then on Mansfield dominated and at the start of the second half Mendes wasted three golden opportunities to make the game safe, the best coming in the 65th minute when he was foiled by Cox's tremendous point-blank save.
Click here to read FootyMad's full report on the game, or click here to see the updated league table.