KUALA LUMPUR (AFP) - Malaysias Prime Minister Abdullah Ahmad Badawi resigned Thursday after six years in office, clearing the way for his deputy to take over the task of steering the nation out of economic crisis. Najib Razak will be sworn in on Friday (today), completing a transition that has been in the planning since elections last year in which the ruling United Malays National Organisation party (UMNO) put up its worst performance in 39 years. The incoming prime minister has said he will focus on a programme to unite the multi-racial nation, whose ethnic minorities shifted towards the opposition in large numbers in the 2008 polls, fearing their rights were being eroded. I think this new thrust will ensure there will be a fairer distribution of government allocations and assistance to all communities, Najib said Wednesday. Meanwhile, the 81 opposition lawmakers in parliament sent a joint petition to the king urging him to delay Najibs swearing-in until he has been cleared of allegations including links to the murder of an aides mistress. It is highly unlikely the king will consider their request. Najib has an impeccable pedigree as the son and nephew of two former prime ministers, but he has been dogged by the controversy which his opponents have said he would have to address. Najib and Abdullah had successive audiences with King Tuanku Mizan Zainal Abidin at the royal palace on Thursday, and a senior official told AFP the prime ministers resignation had been accepted. PM Abdullah offered his resignation to the king. The king is understood to have accepted it, the official told AFP on condition of anonymity. Najib was last Thursday officially declared president of UMNO, effectively smoothing his path to the premiership because of its dominance of the political scene. He is due to be sworn in as prime minister at 0200 GMT Friday.