Foster and Patrik Elias scored in a 2:58 span midway through the third period to lift New Jersey past the Winnipeg Jets, 2-1 on Saturday. Foster tied it at 9:45, and Elias gave the Devils the lead at 12:43 with his 16th goal of the season.
"It was my first goal as a Devil, and it definitely felt really nice," said Foster, acquired last month from Anaheim.
Martin Brodeur made 22 saves for the Devils (25-17-2), who have won four of six.
Elias redirected a point shot from Adam Larsson for the go-ahead goal at 12:43.
"We got a little luck, we battled real hard," Brodeur said. "A little chaotic, but we got it done."
The game was the last in a four-game trip for the Devils.
"We knew we needed contributions from some different people with some of the guys we have out of the lineup. At the end of the road trip we got that," New Jersey coach Peter DeBoer said.
Andrew Ladd scored his 15th goal for Winnipeg. Pavelec stopped Elias on a penalty shot with 1:36 left and finished with 24 saves, but the Jets (20-19-5) have lost five of six.
"This is not the time to start beating up on this team," said Jets coach Claude Noel, who had been worried about his team's morale after a 2-0 loss to San Jose on Thursday. "It's not going to happen, not from my standpoint. If people want to do that, that's fine, but it's not going to happen from here.
"We want effort. We wanted to be proud of our effort today and we wanted to work. We wanted to work together, work smart and we got that. That's what we did, so this thing will get itself resolved."
Noel said Wheeler was taken to hospital to be assessed, but he didn't have an update on his condition.
"We don't know yet, but I think he's OK," he said.
Ladd had some close calls in front of the New Jersey net during the first period, but he scored on the fly. Racing down the left boards from center ice, he fired a high shot that glanced off the top of Brodeur's glove with 1:29 left in the period.
"We've had some leads," Winnipeg defenseman Ron Hainsey said. "We're not getting run out of the building, especially against a lot of good teams.
"We're just in tight, low-scoring one-goal games that ... one play here, one play there that's cost us."
The scoreless second period was costly for the Jets when Wheeler, who leads the team with 32 points, left the game about 7 minutes in.
New Jersey had a 16-12 edge in shots after the second.
- Devils rookie Adam Henrique (34 points) didn't play because of a minor groin injury.
- The teams will meet again in New Jersey on Tuesday night, the beginning of a six-game homestand for the Devils.