The United States were hammered 3-1 by Poland in their final World Cup group D match on Friday but still made it through to the second round of the competition.
The Americans go through in second place behind South Korea, who handed the U.S. a lifeline by scoring a late winner against Portugal in the group's other match.
News of Korea's goal was greeted with cheers from virtually everyone inside Taejon's World Cup stadium -- Koreans and Americans alike. Even the Poles, their side eliminated from the competition, joined in.
But for most of an open, exciting game, the U.S. appeared to have blown their chance of a place in the last 16 against a Poland side which bore no resemblance to the one which lost their opening two matches without scoring.
Poland struck twice in the first five minutes to stun their opponents.
Nigerian-born striker Emmanuel Olisadebe scored their first with a fierce shot off the underside of the crossbar after his initial header from a corner kick had been blocked.
Two minutes later, Jacek Krzynowek found space to cross from the left and striker Pawel Kryszalowicz beat U.S. centreback Jeff Agoos to the ball to turn a first time shot past goalkeeper Brad Friedel from close range.
Between the two goals, in a astonishing opening few minutes, U.S. midfielder Landon Donovan had an effort disallowed.
The 20-year-old midfielder was adjudged to have fouled defender Arkadiusz Glowacki just before he headed the ball into the net.
The American players swarmed around Chinese referee Lu Jun to protest the decision, and some of them still appeared to be distracted as Poland surged up to the other end of the pitch to score their second.
The Poles almost grabbed a third midway through the half when forward Maciej Zurawski drove a low shot off Friedel's legs and on to the keeper's right hand post.
Poland added a third in the 66th minute when Marcin Zewlakow, who had been on the pitch for less than a minute, scored with his first touch -- a header from a cross from the Polish left.
The U.S. looked down and out until the news came through from the Korean match to propel them into the second round.
Friedel celebrated his side's qualification by saving a Zurawski penalty in the 76th minute after Kryszalowicz had been pulled down by Tony Sanneh.
It was his second penalty save of the competition.
Then with seven minutes to go, Donovan got some consolation for his disallowed goal, when he pulled back a late goal for the U.S. after finding space in the Polish area.