James van Riemsdyk knows he was not given a five-year, $35 million contract last year to be on the Flyers’ fourth line.

But that’s where the Flyers’ big left winger has played the last four games.

To his credit, van Riemsdyk hasn’t sulked and hasn’t stopped playing hard.

The Central Jersey native hasn’t been playing that poorly. His defense has improved, and he was getting plenty of scoring chances from in close before his demotion.

He just wasn’t finishing those chances, and now has only one goal in his last 16 games.

“Obviously, I’m here to produce and score goals,” van Riemsdyk, whose team hosts Detroit at 4 p.m. Friday, said recently. “When things aren’t going in, I think there are things you can focus on. For me, focus on being good on the walls, don’t turn pucks over, be a plus player. I think I’ve been doing all those things. You just continue to stick with it.”

Case in point: van Riemsdyk, playing in his 700th career game, contributed an assist on Tyler Pitlick’s goal and was plus-1 in the Flyers’ 3-2 comeback win Wednesday in Columbus, where they entered the night with just one win in their previous 14 contests.

Flyers coach Alain Vigneault said van Riemsdyk is working hard and ‘trying to get his game in order. As a staff and as a head coach, there’s always that fine line. Players say, ‘Give me more ice time and I’ll play better,’ and I say, ‘Play better and I’ll give you more ice time.’ We’ve given him every power play, and he’s gotten one goal so far on that unit.”

“I feel like I’ve gotten some good looks, and I’ve certainly been a little snake-bitten,” van Riemsdyk said. “But I know I’m here to produce offense and it hasn’t necessarily gone well for me in that sense, but I have to focus on the other details as I mentioned, and the rest usually takes care of itself.”

Van Riemsdyk, who had 27 goals in 66 games last season but just four goals in 25 games this year, had received less than 10 minutes of playing time in his previous two games before Wednesday. He was on the ice for 15:55 against Columbus, primarily because the Flyers had five power plays.

“Everyone wants to play,” van Riemsdyk said, “but that being said, those decisions are out of your control as a player. You just have a good attitude, a good mindset every day, and you go from there.”

In Wednesday’s victory, Claude Giroux’s power-play goal late in the second period and Brian Elliott’s strong goaltending lifted the Flyers to the win, giving them points in 12 of their last 14 games.

The Flyers had been a sloppy 0-for-4 on the power play — and had not had many chances — before Giroux scored on a wrist shot from the left circle.

Elliott stopped 15 of his 28 shots in the third period. He made two huge late saves, including one with his skate on Sonny Milano’s point-blank attempt with 3:15 to go.

“Probably his best save of the year,” Giroux said.

Earlier, Scott Laughton converted Joel Farabee’s perfect goal-mouth feed into a goal, knotting the score at 2-2 early in the second period. It was Laughton’s first goal of the season – and first in 24 games dating back to last March.

“That’s the best I’ve felt since the injury,” said Laughton, who had missed 13 games this season because of a broken right index finger.

The goal negated Seth Jones’ tally with 36 seconds left in the first, which put Columbus ahead, 2-1.

Elliott called Laughton’s goal the key to a rare win in Columbus.

“I thought the energy of our team jumped up from there,” he said, “and we were able to play the rest of the game the right way. I thought we did a good job of not getting rattled by letting up a goal in the last minute of the [first] period. It’s a big sign that we’re a veteran team that can handle some misplays and come back with resilience.”

It was the Flyers’ first regulation victory at Nationwide Area since 2005, when rookie Jeff Carter deposited the winner.

“Just a big win on the road,” said Laughton, whose team improved its overall record to 13-7-5. “It feels like we hadn’t won in this building in forever.”

Breakaways

Carter Hart, who is 5-2-2 with a 2.05 GAA and .921 save percentage this month, will face the Red Wings and may be opposed by former Flyer Cal Pickard. … Detroit (7-17-3), which is last in the 16-team Eastern Conference and has lost seven straight (0-5-2), is coming off a 6-0 defeat Wednesday to visiting Toronto. The Leafs had 54 shots, the most allowed by Detroit in a game since 1976. … Robert Hagg broke up a two-on-one in Wednesday’s third period and had three blocked shots and three hits. ... Most of the team worked out off-ice on Thursday with the exception of Shayne Gostisbehere, Phil Myers, Chris Stewart, and Nolan Patrick taking the ice for some drills against goaltender Hart. Vigneault said early Thursday afternoon that he had not yet decided on his six defensemen for Friday’s game. The coach said earlier this week that he wanted to get Gostisbehere, who has sat out the last three games, back into the lineup at some point soon.