What do you do when you blunder?




I think it depends on the game and the opponent. Sometimes it's more fun for everyone if you just resign and move onto the next game.
At higher levels it's harder to make it back from a blunder so it's pointless to play on if you know you have no chance. At lower levels there might still be opportunities, especially as blunders are more common. I recently lost my queen for a bishop but fought back to win. I had been playing for a little material to help fight for a draw when I spotted a good combination that led to counterplay down the queenside. Ended up mating them. But if he'd have gone on beating me I would have then resigned.
While you're learning it can be useful to play on because when you're stretched you'll find that your opponent has some advantages that you'll have to be careful about. But if you prevent their pieces linking up well or even developing then you may find that the material advantage isn't that important. Many players make little mistakes when they're up because they're too focused on the win. Playing a few games where you have to scrap and scrape can do wonders for your chess.
So to summarize, play 5-15 more moves and see what happens. Resign if your position is still hopeless and you're not in the mood for seeing if you can learn something.