Mark Hughes registered his first Barclays Premier League win as QPR manager with a convincing victory over hapless Wigan at Loftus Road.
Rangers started nervously, but took the lead in the 32nd minute when Heidar Helguson slotted home from the spot after James McCarthy handled in the box and they then made it 2-0 on the stroke of half-time thanks to Akos Buzsaky's brilliant free-kick.
Hugo Rodallega pulled one back for the Latics with a strike of equal brilliance before Tommy Smith blasted home from 25 yards to complete the win following Helguson's failure to convert a second penalty.
This morning's back pages may have concentrated on Joey Barton's Twitter tirade against former boss Neil Warnock, but the only thing Hughes was concerned with today was the three points.
The Welshman saw his team slip into the relegation zone after losing his first game in charge against Newcastle last week, but they are now out of the bottom three.
After last week's tricky fixture on Tyneside, Hughes must have been encouraged to see Wigan - who have won just three times this term - were next up.
The bottom-of-the-table Latics, with the worst scoring record in the top four divisions, started strongly, however, and should have been ahead inside three minutes.
Steve Gohouri gained two yards on his marker to meet Jordi Gomez's cross but he side-footed a yard wide with Rodallega lurking at the back post.
Victor Moses then cut in from the left, skipped past two challenges and fired across the box but no-one could tap in.
Barton sent Luke Young down the right for QPR and his miscued cross drifted towards goal, causing Ali Al Habsi to back-pedal and tip over athletically.
The move seemed to kick Rangers into gear. DJ Campbell just missed a chance to prod home before lashing a chance wide following a mistake by Gohouri. Shaun Wright-Phillips then had a shot blocked by McCarthy, before Gohouri put in a crucial block to deny the winger moments later.
The former Manchester City man then laid the ball off to Buzsaky, who turned his marker before firing a superb 30-yard effort that beat the out-stretched Al Habsi, but flew inches wide.
The Latics stopper denied Jamie Mackie moments later with a fine save, but a glaring error from McCarthy then gifted the hosts the lead in the 32nd minute.
Inexplicably, the midfielder chose to palm the ball away from danger from Barton's corner when he realised he could not head the inswinging cross clear and Jon Moss pointed to the spot.
McCarthy went into the book and Helguson slotted home for his eighth league strike of the season.
Al Habsi did well to tip Buzsaky's 25-yard free-kick around the post, but the Hungarian beat the Latics stopper with two minutes of the half left.
Gohouri's trip on Campbell gave QPR a dangerous free-kick 25 yards out and Buzsaky curled a wonderful effort over the wall and into the net off a post to make it 2-0.
Wigan boss Roberto Martinez introduced striker Connor Sammon for James McArthur at the break while Smith came on for Campbell for the hosts.
Gomez ploughed a volley in to the stands after a quiet opening to the second half.
The ball then popped up to Buzsaky at the other end following Wright-Phillips' lay-off and he fired a peach of a volley which Al Habsi tipped around the post with a brilliant diving save.
The visitors found a way back into the game in the 65th minute when Barton upended Maynor Figueroa on the edge of the box and Rodallega curled in the resulting free-kick which had Paddy Kenny rooted to the spot.
Sammon slipped in behind the QPR defence and calmly controlled the ball, but could only fire a yard wide of Kenny's goal.
Referee Moss awarded his second penalty of the afternoon with 17 minutes left when he adjudged Gary Caldwell had climbed over Helguson's back in the box.
The Icelandic striker stepped up to take the spot-kick but Al Habsi saved this time down low to his right.
Helguson came within inches of making amends moments later when he hammered a powerful volley that sailed inches wide of Al Habsi's goal, with the former Bolton man easily beaten.
Mackie had the perfect chance to put the game beyond Wigan's reach with 12 minutes left when he galloped clear following Wright-Phillips' through-ball, but the home crowd, and Hughes, despaired as the forward blasted over.
Smith put the game beyond doubt the following minute, however, when he crashed a thundering piledriver past Al Habsi from 25 yards.
Buzsaky received a standing ovation when he was replaced by Shaun Derry as Rangers ran out comfortable winners.