Two teenagers who robbed a newsagent before bragging about it on Facebook minutes later were caught due to their underwear being captured on CCTV, police said.
Reece Winfield, 18, and Corey Hobson, 17, attacked the shopkeeper during the raid in Mansfield, Nottinghamshire, before stealing cigarettes and alcohol.
Minutes later, Winfield took a photo of Hobson with the stolen items and posted it on Facebook.
Hobson also commented on a newspaper link to an article about the robbery which was posted on the social networking website, saying: “Hehehe that’s me.”
But it was their underwear, caught on CCTV hanging out above their low-slung trousers, that helped police to track them down.
When they were arrested two days later, they were still wearing the same underwear, Nottinghamshire Police said.
The shopkeeper received minor injuries in the incident at the newsagent on February 5 this year.
After making comments about the robbery on social media site Facebook, the pair also filmed themselves lighting and throwing a homemade petrol bomb in a street in Nottingham in a separate incident, police said.
Hobson, of no fixed abode, and Winfield, of Nottingham, were both sentenced to 32 months for robbery and four months for attempted arson at Nottingham Crown Court on Thursday after pleading guilty at an earlier hearing.
Seventeen-year-old Hobson can be named after Judge Andrew Hamilton agreed to lift restrictions on identifying him following an application by a reporter from the Mansfield Chad newspaper.
Detective Sergeant Phil Sims, of Mansfield CID, said: “These two made it very easy for us to track them down and, in the end, you could say they were well and truly caught with their pants down.
“They obviously thought it was funny to brag about their crime, sparing no thought for their victim, who they left battered and bruised and counting the cost of their theft and damage.”
Neighbourhood Inspector Andy Goodall said: “While there was no damage or injuries caused by the explosion, Winfield and Hobson’s actions showed a reckless disregard for their own and other people’s safety.
“The fact that they filmed their exploits and laughed at the bang suggests they were pretty happy with themselves.
“I doubt they are laughing now.
“It is by no means big or clever to play with fire and certainly not risk to the lives of others. Under no circumstances will we tolerate this sort of lawless, dangerous behaviour.”