A local Communist Party official and 26 other people were being tried on charges of organizing a bloody attack on protesting villagers that killed six people in June, the government said Friday.

The announcement of the trial came as the government tried to diffuse public anger over a separate clash last week in which police opened fire on protesters in a southern village northeast of Hong Kong, killing at least three. Villagers said as many as 20 were killed.

The government has detained the commander of the forces that fired on the demonstrators.

In the June conflict in Hebei province near Beijing, as many as 300 men with knives and guns attacked villagers protesting the seizure of land for construction of a power plant.

Dozens of people were injured and more than 100 people were detained.

He Feng, a former local Communist Party secretary, was among the 27 who went on trial Thursday on charges of causing "intentional injuries," the official Xinhua News Agency said.

It said Zhang Li, a contractor, was accused of plotting the attack with her husband. The report did not identify the other defendants or say how they were involved.

More than 200 people attended the session at the Intermediate People's Court in city of Handan, including families of the victims and the accused, Xinhua said. It was unclear how long the trial would last.

A woman who answered the phone at the court said the trial was in session Friday, but she would not give any details.

Rural confrontations are increasing in intensity and frequency in China as local authorities confiscate land for construction of factories, power plants, shopping malls and other projects.

Farmers often complain they are paid little or nothing and sometimes accuse local officials of stealing compensation money.

State media reports said unidentified men armed with guns, clubs and knives stormed the shantytown on June 11 to try to empty it.

It was unclear who the men were, but local Chinese officials often hire armed thugs to settle disputes.

State media reports described witness accounts of men rushing into the shacks and starting "pounding and chopping." Witnesses said they saw a 60-year-old man shot, and a woman said she was hit by a brick as she fled the scene, according to the state media.

Two villagers were killed on the spot and four others died in the hospital, Xinhua said Friday.

State media reported a month after the attack that Hebei officials decided to give villagers their land back, citing a local shortage of land.

Villagers said they were satisfied with the return of their land but wanted the killers punished, state media said.