Yemen’s president on Thursday afternoon apologized to US President Barack Obama for the attack on the US Embassy in Sanaa, the Yemeni capital, by a mob angry over an anti-Islam film.

The US Embassy in Yemen said nobody was harmed in Thursday’s assault. “All embassy personnel are safe and accounted for,” spokesman Lou Fintor said.

Yemenite President Abed Rabbo Mansour Hadi also ordered an investigation into the attack. He avowed to bring the culprits to justice, saying the attack by a “rowdy crowd” was part of a conspiracy to derail Yemen’s close relations with Washington.

Earlier Thursday, protesters angered by an anti-Islam film stormed the US Embassy compound in Sanaa, while in Egypt police clashed with some 200 protesters outside the US Embassy in Cairo.

Protesters also gathered in Iraq to protest the United States.

Before storming the embassy compound in Sanaa on Thursday, the demonstrators removed the embassy’s sign on the outer wall and set tires ablaze. Once inside the compound, they brought down the US flag and burned it, replacing it with a black, Islamist banner.

The protesters were on the embassy’s grounds but did not enter the building housing the offices. They managed to smash windows and burn the security building at the entrance to the heavily-guarded compound.

Security guards opened fire, Reuters reported. There were reports of casualties on both sides. Photos on twitter showed locals looting computer equipment from the compound.

In Egypt, police fired tear gas outside the embassy, as protesters hurled firebombs, rocks and set fires. Some 20 people were reported injured in the clashes.

The fighting in Cairo lasted until after dawn Thursday, as security forces pushed protesters away from the embassy and toward Tahrir Square, Al Arabiya reported.

Egyptian news outlet Al-Ahram reported that about 200 people attended the protest, with several firebombs hurled at security forces.

Tear gas wafting through Tahrir Square as police clash in protesters in Cairo Thursday morning. (photo credit: Sherine Tadros via Twitter)

Tear gas wafting through Tahrir Square as police clash with protesters in Cairo Thursday morning. (photo credit: Sherine Tadros via Twitter)

Many of the protesters were reportedly members of the Ultras, a militant soccer fan club that has played a large role in past protests and has emerged as a potent political force in the country.

Many of the demonstrators were unbearded, the outlet reported, a marked difference from the day before, when protests were seemingly dominated by hard-line Islamists.

In Iraq, protests came hours after a radical group linked to powerful Shiite cleric Muqtada al-Sadr warned the US’s interests in the country could be harmed by fallout from the movie, CBS News reported.

“The offence caused to the messenger (Prophet Mohammad) will put all American interests in danger and we will not forgive them for that,” Qais al-Khazali, leader of the Asaib al-Haq militia, said, according to Reuters.

The protests were the latest in a number of attacks on US embassies in the Arab world, including an attack on Tuesday night that saw the American ambassador in the country, Chris Stevens, and three other staff members killed.

On Tuesday, an angry mob of some 2,000 stormed the embassy grounds in Cairo, tearing down the American flag and replacing it with a pro-Islam banner.

Security at US embassies in the Arab world was ordered ramped up after the protests, which stemmed from the release of a trailer for a movie which depicts the Muslim prophet Mohammad as a feckless womanizer who abuses children.

Officials originally believed the Libya attack to be linked to the film, though they are now investigating the possibility that it was a planned al-Qaeda attack.

Yemen is home to al-Qaeda’s most active branch and the United States is the main foreign supporter of the Yemeni government’s counterterrorism campaign. The government on Tuesday announced that al-Qaeda’s No. 2 leader in Yemen was killed in an apparent US airstrike, a major blow to the terror network.

Troops patrol outside the US Embassy in Sanaa in 2008. (photo credit: AP/Nasser Nasser)

Troops patrol outside the US Embassy in Sanaa in 2008. (photo credit: AP/Nasser Nasser)

In September 2008, terrorists dressed as police officers and armed with rocket-propelled grenades, rifles and car bombs stormed the US Embassy in Sanaa, Yemen killing 19 and injuring 16. The Islamic Jihad of Yemen, an affiliate of al-Qaeda took responsibility for the attack.

Clashes were also reported in Tunisia on Wednesday, as several hundred people protested outside the US Embassy in Tunis.

In Afghanistan, President Hamid Karzai canceled an official visit to Norway amid concerns over riots over the film.

Karzai’s spokesman Aimal Faizi said on Thursday that the trip will be held at a later date. He did not say why the trip has been postponed.

The Norwegian Foreign Ministry said in a statement that Karzai postponed the trip because he felt he needed to stay at home in light of the serious events in some Arab countries.

Karzai was to have travelled to Oslo late Wednesday to sign an agreement of strategic partnership.

US President Barack Obama called the presidents of Libya and Egypt Thursday morning and urged them to continue working with the US to ensure the safety of diplomatic personnel.

Egyptian President Mohammed Morsi promised Egypt “would honor its obligation to ensure the safety of American personnel,” the White House said.

Obama told Morsi that while “he rejects efforts to denigrate Islam… there is never any justification for violence against innocents.”

Asher Zeiger contributed to this report.