A teenager will appear in court after allegedly making comments on Facebook about the deaths of six soldiers in Afghanistan last week, police said.

Azhar Ahmed, 19, according to West Yorkshire Police, posted the comments on his profile page and has been charged with a racially aggravated public order offence, according to West Yorkshire Police.

A police spokesman said Ahmed, of Fir Avenue, Ravensthorpe, West Yorkshire, was bemoaning the level of attention the British soldiers who died in a bomb blast last week received compared to Afghan civilians who have died in the war.

The spokesman said: "He didn't make his point very well and that is why he has landed himself in bother."

Ahmed will appear at Dewsbury Magistrates' court on March 20.

He was arrested on Friday and charged over the weekend. He has been bailed to an address outside the county.

Last week, six men were killed in the deadliest single attack on British forces in Afghanistan since 2001.

The soldiers who died - five of them aged between 19 and 21 - died when their Warrior armoured vehicle was blown up by a massive improvised explosive device (IED).

Sergeant Nigel Coupe, 33, of 1st Battalion The Duke of Lancaster's Regiment was killed alongside Corporal Jake Hartley, 20, Private Anthony Frampton, 20, Private Christopher Kershaw, 19, Private Daniel Wade, 20, and Private Daniel Wilford, 21, all of 3rd Battalion the Yorkshire Regiment.

The tragedy was the biggest single loss of life for British forces in Afghanistan since an RAF Nimrod crash killed 14 people in September 2006.

It took the number of UK troops who have died since the Afghanistan campaign began in 2001 to 404.