It wasn't exactly how Lawrence Frank would have preferred to get a much-needed road victory, but he will take it.

The Pistons gave up 24 points in the paint in the third quarter and gave up 18 offensive rebounds Sunday night.

And the team was missing rotation mainstay Rodney Stuckey, listed as inactive for reasons that Frank didn't divulge afterward.

But two late Brandon Knight triples in a span of 29 seconds powered the Pistons to a 104-102 victory over the Magic.

The long-distance baskets capped off a career-high 31-point evening for Knight, who was 12-for-16 from the field and 5-for-8 from three-point land.

The Pistons (17-27) were able to remain 4 games behind the Celtics for the eighth and final spot in the Eastern Conference playoff chase. The Pistons' chances appear more realistic with the news that Celtics point guard Rajon Rondo is out for the season with a knee injury. So the Pistons must beat teams like the Magic (14-29) to make a run.

"Every game is a must-win for us from this point on if we want to have a shot at trying to make it to the playoffs," Pistons small forward Tayshaun Prince said. "But we just got to continue to take one game at a time.

"We did feel like we wanted to come out and get this one because they beat us pretty well the first two times they played us and we really wanted to come out and be aggressive."

Knight's late heroics came with the team trailing, 98-95, after the Magic's E'Twaun Moore completed a three-point play. Knight nailed the first one when Greg Monroe found him after an offensive rebound. The next came on a corner triple for a 103-100 lead. He also drew a key offensive foul and grabbed a key offensive rebound.