Six-time prime minister Ranil Wickremesinghe was elected as crisis-wracked Sri Lanka’s new president in a parliamentary vote Wednesday, with the backing of the disgraced former leader’s party.

Official results gave the veteran politician 134 votes, an absolute majority in the 225-member parliament, after Gotabaya Rajapaksa fled the country and resigned in the wake of protesters overrunning his palace.

“Our divisions are now over,” Wickremesinghe said in a brief acceptance speech in parliament, urging his defeated rivals “to join me and work together to bring the country out of the crisis we are facing”.

Wickremesinghe takes charge of a bankrupt nation that is in bailout talks with the IMF, with its 22 million people enduring severe shortages of food, fuel and medicines.

But he was backed by the Rajapaksas’ SLPP party — still the largest in parliament — and is despised as a proxy for the former leader the protesters forced from his palace after months of demonstrations over the unprecedented economic crisis.

They have also been demanding the departure of Wickremesinghe, who on Wednesday reiterated his vow to crack down on lawbreakers.

Hundreds of heavily armed troops and police stood guard outside the parliament, but there were no signs of demonstrators.

Outside the presidential secretariat, where protesters camped for months, actress Damitha Abeyrathne, 45, said: “We lost. The whole country lost.”

“The politicians are fighting for their power. They are not fighting for the people. They have no feeling for people who are suffering.”

The struggle would continue, she told AFP.

But Wickremesinghe vowed to take tough action against anyone resorting to what he called the undemocratic means that led to his predecessor’s ouster.

“If you try to topple the government, occupy the president’s office and the prime minister’s office, that is not democracy and we will deal with them firmly,” he said on an evening visit to a Buddhist temple.

Law and order

One by one, the legislators entered ballot booths set up on the floor of the chamber to choose between the three candidates.

Previous elections have been marred by allegations of corruption and vote-buying, and mobile phones were banned to prevent anyone taking photos of the ballots.

Wickremesinghe was elected for the balance of Rajapaksa’s term, which runs until November 2024, and the speaker’s office said he would be sworn in on Thursday.

According to analysts, Wickremesinghe is likely to appoint his school-mate Dinesh Gunawardena, a strong ally of the once-powerful Rajapaksa clan, as prime minister.

Wickremesinghe insisted: “I’m not a friend of the Rajapaksas, I’m a friend of the people.”

But he appears to be indebted for his victory to the four brothers who have dominated Sri Lankan politics for much of the last two decades.

Gotabaya’s departure wounded the group after two of his brothers also quit their posts as premier and finance minister earlier this year.

But former president Mahinda Rajapaksa, the deposed Gotabaya’s elder brother and the head of the family, remained in the country, and party sources said he had pressed SLPP legislators to support the veteran operator.

As acting president, Wickremesinghe extended a state of emergency that gives police and security forces sweeping powers.

On Wednesday, a court ordered the protesters to vacate their camp near the Presidential Secretariat and confine themselves only to a designated area.

A top police official said anyone damaging state property would be dealt with severely. Protesters occupying a part of president’s office have been ordered to leave or face eviction.

Opposition MP Dharmalingam Sithadthan said ahead of the vote that Wickremesinghe’s hardline stance against demonstrators had gone down well with MPs who had been at the receiving end of mob violence, describing him as the “law-and-order candidate”.

Political analyst Kusal Perera said he had “regained the acceptance of the urban middle classes by restoring some of the supplies like gas”.

Clearing government buildings of protesters also showed the 73-year-old’s “firmness”, Perera said.

‘Petrol and gas’

Wickremesinghe’s main opponent in the vote was SLPP dissident and former education minister Dullas Alahapperuma, 63, a former journalist who was supported by the opposition and received 82 votes.

The third candidate, leftist Anura Dissanayake, 53, was embarrassed when the final tally showed that the pile of rejected votes was one more than the three he polled.

But 72-year-old Zarook, a retired seaman who gave only one name and lives in Slave Island, an impoverished area of the capital, was indifferent to the result.

“If Ranil comes, if another man comes, we have to do our daily jobs. So we don’t care,” he said.

He hoped for “petrol and gas”, he told AFP, “the daily products we need”.