Qalqilya residents say their economy has been hit hard by the West Bank barrier
By Heather Sharp
BBC News, Qalqilya, West Bank
"The decision was purely political," says Wajih Qawas, fiddling with a string of prayer beads as he explains how he lost his job.
Until a month ago, the softly-spoken management systems graduate was the mayor of the West Bank town of Qalqilya, although he has spent much of that time in Israeli prisons.
The town of 40,000 was one of several major West Bank towns in which Hamas won control of municipal councils in elections in 2004 and 2005.
Locals and outsiders alike wondered how a group known for suicide bombings would handle fixing potholes and sewage pipes.
Mr Qawas has spent much of his term in office in Israeli jails
Four years later, Qalqilya - which is almost surrounded by Israel's West Bank barrier - has a smooth, wide new road to its entrance, but the traffic lights at its central intersection don't work.
Mr Qawas believes he is the latest victim of the bitter feud between the Islamist movement and its more secular rival Fatah, being played out here in the minutiae of electricity bills and school construction.
Hamas won legislative elections in 2006, and later seized control in Gaza in June 2007.
Since then, the Fatah-dominated Palestinian Authority and Israel have jointly been working to effectively stamp out the Islamic movement in the West Bank, while Hamas has used similar tactics against its rivals in Gaza.
Qalqilya has a new road, but some traffic lights don't work
Palestinian rights groups have condemned a steady stream of detentions without trial, dismissals of officials and the disbanding of institutions and charities by both sides in the dirty internecine struggle.
On 12 Sept, PA officials swept in and fired Mr Qawas and his team.
They accuse him of allowing the municipality's debts to spiral out of control, ignoring orders from above and failing to bring in international funds to improve the town.
The PA's minister for local government, Khaled Qawasmi, says the move was "totally not a political decision", pointing to two Fatah-run councils it has also dissolved - albeit small ones.
He dismisses a performance report by an official auditing body that scored Qalqilya municipality 3rd out of 51 in the West Bank, saying it was not detailed enough.
When Hamas points out that there are Fatah-run municipalities with equally soaring debts, Mr Qawasmi says that unlike them, Qalqilya refused to delay a proportion of employees' salary payments to help refill the coffers.
Much of the deficit is due to unpaid power bills. Hamas claims that the PA failed to supply enough pre-pay electricity meters needed to recover the money.
But the PA says it offered to reduce the council's debt by the cost of the meters, or to pay for them if the electricity price was increased by 10% - and Hamas refused both options.
Robert Blecher, an analyst for the International Crisis Group, said the PA take-over was "almost by definition politically motivated".
He says PA-linked figures and institutions have long tried to squeeze Hamas-run municipalities in the West Bank.
But those local councils have definitely brought in less money from international donors, he says.
Most of the international community shuns Hamas as a terrorist organisation, despite its electoral victories.
Mr Qawas fails, even when asked repeatedly, to condemn attacks on civilians. So it is perhaps unsurprising that, as one humanitarian worker put it, "many donors got cold feet" on projects in Qalqilya.
On the streets of the town, shoppers weave their way through yellow taxis.
Locals say the economy has improved a little in recent months since the checkpoint at the entrance to the town was removed and Israeli Arabs were allowed in to visit.
But they say the barrier - which Israel says is necessary for security - and Israeli export restrictions are still squeezing them hard.
There are Fatah supporters who believe Hamas just gave jobs to its supporters and did little for the town.
But there are others - not all Hamas voters - who believe the group ran the municipality reasonably well, but was hamstrung by international isolation and the people's inability to pay their electricity bills.
Weary shrugs on the streets suggest many locals are more worried about where the next meal is coming from than the high ideals of democracy.
But rights workers like lawyer Salah Moussa of the Palestinian Independent Commission for Human Rights are critical of the legal basis on which the Qalqilya take-over was carried out.
The Palestinian Legislative Council is not sitting because Hamas and Fatah cannot agree over what to do about the fact that many of the council's Hamas members are in Israeli jails.
In late 2008, PA President Mahmoud Abbas issued a law permitting the local government minister to dissolve municipal councils after their four-year mandates expire.
Some locals believe Hamas did a good job but was short of money
Mr Moussa believes it conflicts with both the Palestinian basic law, and - as neither the new law nor the appointment of the minister have been ratified by an elected assembly - the spirit of democracy.
"Who is supposed to have more power?," he asks. "The elected people, not the appointed people!"
Mr Abbas's four-year term has already ended. The PLC's - and with it Hamas's main claim to legitimacy in Gaza - will expire in January.
The two factions are struggling to agree a deal to pave the way for presidential, legislative and local elections in the first half of next year.
There are big questions over whether any poll would be free and fair.
In addition, Hamas infrastructure in the West Bank has been heavily eroded - as has Fatah's in Gaza.
Many former Hamas figures and supporters in the West Bank now describe themselves as "independent" and "Islamist".
As Mr Qawas sits unemployed in his apartment, behind a door riddled with bullets left by "unkown people", I ask whether this is the end of Hamas as a political force in the West Bank.
"Hamas is a vision - it's families, it's houses, its opinions," he says,
"If anyone wants to end Hamas - or Fatah - he has to end the whole of the Palestinian people."