BOSTON -- Down 3-0 in the series, then down 3-0 in Game 7. It looked as if the Philadelphia Flyers had finally run out of rallies against the Boston Bruins.

Turns out Simon Gagne and his teammates were just warming up.

Taking advantage of a too-many-men-on-the-ice call, Gagne scored on a power play with 7:08 left for a thrilling 4-3 victory Friday night in the Eastern Conference semifinals.

The win set up a most unlikely matchup for a trip to the Stanley Cup final -- the seventh-seeded Flyers vs. the eighth-seeded Montreal Canadiens starting Sunday night in Philadelphia.

"If we believe in ourselves and keep going with this, who knows what can happen?" said Scott Hartnell, who scored Philadelphia's second goal.

Flyers coach Peter Laviolette added, "The game 7s are tough. There's a lot of pressure. It's a game that's made for men. And our guys proved to be men."

The Bruins became the third team in NHL history to lose a series after winning the first three games.

"The bottom line is we had a 3-0 lead in the series, we had a 3-0 lead tonight, and we blew them both," Boston coach Claude Julien said. "We have to take the responsibility that goes with it. Everyone."

The Flyers on the bench smacked their sticks against the boards when they saw the Bruins had an extra skater, trying to get the officials' attention. Vladimir Sobotka had jumped on the ice, but Marc Savard, who had raised his stick to call for a replacement, stayed on.

"I saw it right away," Flyers captain Mike Richards said.

The whistle blew.

"I saw two centermen out there and I said, `What's going on?" said Milan Lucic, who had two goals for Boston.

The Flyers capitalized when Richards' shot from the right circle hit players in front of Tuukka Rask. The puck bounced and Gagne, stationed to Rask's left, flipped the puck over the goalie's right shoulder with 18 seconds left in the power play.

Gagne, who had four goals after returning from a toe injury for Game 4, thought the Bruins might have grown tense as their 3-0 lead began to shrink.

"Sometimes you're nervous and you make mistakes," he said. "Then they had too many men on the ice and that might be our chance to win the game and we did."

The only other teams to win a series after trailing 3-0 were the 1942 Toronto Maple Leafs, who beat Detroit, and the 1975 New York Islanders, who eliminated Pittsburgh. The other 159 teams that won the first three games in a series all won them.

The Bruins shot out to a 3-0 lead on power-play goals by Michael Ryder and Lucic and another goal by Lucic. And only 14:10 had been played. Then James van Riemsdyk scored with 2:48 left in the first period for the Flyers.

Second-period goals by Hartnell at 2:49 and Danny Briere at 8:39 tied it at 3.

When the final buzzer sounded, the Flyers poured off their bench and surrounded goaltender Michael Leighton, who started his second playoff game for injured Brian Boucher.

While the Flyers celebrated, the yellow towels that fans twirled to spur on their team floated to the ice, no longer needed until next season. Boston center Patrice Bergeron took a slap shot with one of them -- like the Bruins, it didn't go far.

Boston was hurt by the same too-many-men-on-the-ice call in the 1979 Stanley Cup semifinals against Montreal. In that Game 7, the penalty led to Guy Lafleur's tying goal with 74 seconds left in the third period, then Yvon Lambert won it in overtime for the Canadiens.

Boston lost its third straight Game 7 and first since falling to Carolina in last year's conference semifinals after battling back from a 3-1 series deficit.

The Bruins and Flyers played aggressively at the start with plenty of end-to-end action in the first 5 minutes.

Boston got a break when Hartnell was penalized for high-sticking at 5:19 and Ryder scored his fourth playoff goal on a rebound 8 seconds later. Another Bruins power play 3 minutes later led to another goal, this one by Lucic, who tipped in a pass across the crease from Dennis Wideman in the right corner.

Lucic struck again, scoring his fifth playoff goal five minutes later, at 14:10 on a shot from the right circle.

Leighton, who took over in Game 5 after sitting out nearly two months, didn't allow another goal.

Van Riemsdyk began the comeback with his first playoff goal 3 minutes after Lucic's second goal on a soft shot that trickled by Rask. That was the first of nine consecutive shots by Philadelphia. One of them was Hartnell's second goal of the playoffs. Another was Briere's seventh playoff goal -- on a wraparound.