Pro-government forces loyal to Colonel Barre Hirale Aden Shire, the Somalian defence minister, tried to recapture Kismayo late on Friday, three weeks after losing control of it.

Witnesses told AP that the fighting on the town's outskirts lasted for two hours as rival forces used heavy machine guns and rocket-propelled grenades.

According to an official from the Islamic courts, Shire's forces then retreated.

Fighters defending the Islamic courts took over Mogadishu, the capital, in June. They have since swept through southern Somalia.

Other violence

In related violence, Shire's fighters and those of the Islamic group clashed briefly on Friday in the town of Bu'aale, about 350km south of Baidoa, the only town controlled by Somalia's weak government. Shire had been regrouping his forces near Bu'aale.

Isma'il Khalif Shire, a commander of Shire's fighters, confirmed there had been skirmishes in Bu'aale and said there were no casualties.

Many residents credit the Islamic courts with bringing a semblance of order, but Somalia still remains chaotic and violent.

On September 18, the president of Somalia's interim government survived an assassination attempt when a car bomb exploded outside parliament. Leaders of the Islamic Courts Union have denied responsibility.

Days after the attack, the UN pulled international staff out of central and southern Somalia, saying it had received threats. Aid workers, speaking on condition of anonymity because of the sensitive nature of the subject, said the threats came from Islamic extremists.

State of play

Somalia has not had an effective national government since 1991, when regional commanders overthrew Mohamed Siad Barre, the president, and then turned on one another, throwing the country into anarchy.

The present government was formed in 2004 with UN help in the hope of restoring order after years of lawlessness. But the government never asserted much authority and the Islamic group has stepped into the power vacuum

Islamic courts fighters took control of Kismayo on September 23. They believe that a planned African peacekeeping force to Somalia, which they oppose, would be deployed in the strategic port.

The takeover of the town sparked demonstrations, mainly by women and children. Islamic courts fighters shot dead one boy when they tried to disperse protesters. They also closed down a local radio station, accusing the broadcasters of anti-Islamic propaganda.

Kismayo, 400km southwest of the capital, Mogadishu, was controlled by a loose alliance of commanders led by Shire. He fled the town shortly before its fall.