TEHRAN (AFP) - Iran plans to put on trial 20 people accused of rioting in the unrest that rocked the nation after Mahmoud Ahmadinejads disputed re-election, the official IRNA news agency said on Wednesday. The news came as Ahmadinejad himself was again in the firing line from his own hardline supporters who warned him to obey supreme leader Ayatollah Ali Khamenei or face the consequences for his controversial political decisions. IRNA reported that 20 rioters would go on trial from Saturday, following the release of scores of protesters who were rounded up after massive public demonstrations over Ahmadinejads June 12 election victory. They face charges including bombings, carrying firearms and grenades, attacking Basij militiamen and security forces and having contacts with exiled Opposition group the Peoples Mujahideen. They are also charged with attacking military units and universities, sending pictures to enemy media, organising thugs and rioters, vandalising public and state property including destroying banks and houses, IRNA said. However, Iran prosecutor Ghorban Ali Dorri Najafabadi announced that a considerable number of protesters would be freed by end of the Iranian week on Friday. On Tuesday, the authorities freed 140 protesters, while about 200 remain behind bars, including 50 suspected of masterminding riots, according to an MP who visited detainees. The moves are being seen as gestures to the opposition movement which has branded Ahmadinejads landslide election win a fraud and protested over the subsequent crackdown on demonstrators and political activists. But the authorities are continuing to ban opposition gatherings and have refused to issue a permit for a planned mourning ceremony for slain protesters on Thursday. Judiciary chief Ayatollah Mahmoud Hashemi Shahrudi on Monday ordered officials to decide on the fate of protesters within a week, while Ahmadinejad himself told Shahrudi to release them by August 7, the birth anniversary of Imam Mahdi, a revered Shiite saint. The all-powerful Khamenei - whose regime is battling to contain the worst crisis in the Islamic republics 30-year existence - also this week ordered the closure of a jail as it was not up to required standards. Irans top dissident cleric Grand Ayatollah Hossein Ali Montazeri lashed out at the regime over the deaths of protesters in custody, after media reports that four had died. Those who are behind bars are being forced to confess under torture and every day a body is being delivered to their family, Montazeri said in a letter on his website. What is their sin, except silently protesting against several wrongdoings, offences and fraud in the election, said Montazeri, once tipped to succeed revolutionary leader Ayatollah Ruhollah Khomeini. Amid the mounting political tensions, Ahmadinejads standing has been weakened even within his own camp, forcing him into a humiliating climbdown over a political appointment blocked by Khamenei. Ahmadinejads post-election troubles stemmed from his choice of a controversial aide as his first deputy and his tardiness in terminating the appointment despite Khameneis orders. Ahmadinejad must apologise to people, said the front-page headline of Yalesarat, a hardline weekly newspaper. You have preferred to pour your love on someone like Mashaie than the leader. Mr Ahmadinejad, if this attitude continues, we want you to return our votes, it said in an editorial. Another harsh warning came from prominent conservative group the Islamic Society of Engineers. The peoples continued support for you depends on your unconditional obedience of the supreme leader and departing from this path will have consequences, it said. It seems you did not consider your best interests by appointing Mr Mashaie as your chief of staff.