The Yemeni President has been injured and three people have been killed after shells struck a mosque in the presidential compound in Sanaa.

State television in Yemen broadcast a message from President Ali Abdullah Saleh in which he said he was well after being lightly wounded when the presidential palace was shelled earlier.

An official in the ruling General People's Congress party said earlier Saleh was 'lightly wounded in the back of his head' in an attack blamed by officials on powerful dissident tribesman Sheikh Sadiq al-Ahmar.

Saleh in his message hit out at 'the sons of Al-Ahmar,' a reference to Sheikh Sadiq and his brothers, and called on 'the security forces to purge state institutions of these gangs.'

Three people were killed when the shells struck a mosque in the presidential compound in Sanaa.

Fierce fighting engulfed the Yemeni capital all morning, with reports of dozens of people killed.

Yemen has tipped swiftly towards civil war this week, with forces of the Hashed tribal confederation battling troops still loyal to Saleh in the capital and elsewhere.

More than 370 people have been killed, at least 155 of them in the last 10 days, since a popular uprising against Saleh's nearly 33 years in power began in January.

Before the attack on the palace, protesters paraded the coffins of 50 people it said were killed by Saleh's forces.