Yemeni security forces have foiled a plot by Al-Qaida to take over oil and gas export facilities and a provincial capital in the eastern part of the country, a government official said on Wednesday.

Rajeh Badi, press advisor to Yemeni Prime Minister Mohammed Salem Basindwa, said the plan involved dozens of Al-Qaida militants dressed in Yemeni army uniforms storming the facilities on the 27th night of the of Muslim month of Ramadan, which was on Sunday.

"The plot aimed to seize the al-Dabbah oil export terminal in Hadramout (province) and the Belhaf gas export facility, as well as the city of Mukalla," Badi told Reuters, referring to the Hadramout provincial capital.

He said the plot was prevented by deploying extra troops around the targeted facilities and banning anyone from entering.

The United States has evacuated some U.S. diplomatic staff out of Yemen and told nationals to leave the country immediately after warnings of potential attacks that had prompted Washington to shut missions across the Middle East.

Other Western countries, including Britain, France, the Netherlands and Norway, also closed their embassies in Sanaa and some evacuated their staff.

It was not immediately clear if the foiled plot was linked to these security measures.

Yemen, one of the poorest Arab countries, is the base for Al-Qaida in the Arabian Peninsula (AQAP), one of the most active branches of the network founded by Osama bin Laden, and militants have launched attacks from there against the West.