Libyan rebels appear to be in control of part of the strategic western coastal town of Zawiya, despite denials by the government. As fighting continued, rebels raised their flag inside the town and could be seen controlling a large chunk of it.

Libyan rebel fighters fired their rifles and automatic weapons into the air to celebrate their capture of large areas of of Zawiya, about 50 kilometers west of the capital, Tripoli.

Rebels could be seen on video raising two pre-Gadhafi-era flags over a mosque inside the city to mark their conquest. An al-Jazeera TV correspondent inside Zawiya said forces loyal to embattled leader Moammar Gadhafi control the northern half of the city and are sporadically lobbing mortar shells at rebel-held portions of the city.

A group of rebel fighters cheered their advance into Zawiya and told journalists that a recent string of victories over government forces should help propel them to the capital Tripoli in the near future.

He says "thanks to God we have now liberated Niyad in the Western (Nafousa) Mountains, as well as Sabha, and now Zawiya, and God willing tomorrow we will be in the capital, Tripoli."

Libyan government spokesman Moussa Ibrahim denied the rebels were in control of Zawiya, insisting they had mounted an uprising from within the city and government forces were in the process of defeating them.

"They were stopped easily by our armed forces," said Ibrahim. "There was a small group that resided inside Zawiya. They did not enter Zawiya. They are already inside Zawiya and they were waiting for the other group to come in to join them, but they basically took action too early, so they exposed themselves and they were dealt with and they are still being dealt with.”

The rebels are also claiming to have made advances inside the eastern oil port city of Brega, taking several neighborhoods. Arab satellite channels showed rebels controlling parts of Brega, but it could not be independently confirmed how much of the town they hold.

A rebel victory in Zawiya would represent a significant blow for the government, because Zawiya sits on the strategic coastal highway between the Tripoli and the Tunisian border. That highway has been a major supply line for Tripoli in recent weeks, providing food and fuel for the capital.

Zawiya was one of the first towns to rebel against Colonel Gadhafi in the early weeks of the rebellion, which began in February. Gadhafi forces retook Zawiya in early March, after weeks of a bloody siege that resulted in hundreds of casualties.