Updated

Two men from western China who had been held for nearly a decade without charge at the Guantanamo Bay prison amid a diplomatic struggle to find them homes, have been resettled in El Salvador, the U.S. military said Thursday.

The men, ethnic Uighurs from a region of China roiled by a separatist movement, are learning Spanish and gratefully settling into their new home in the Central American country, lawyers for the men said.

"They are well and very happy," said Susan Baker Manning, a Washington D.C.-based lawyer for one of the men. "We are extremely pleased that the government of El Salvador has taken them in and granted them refuge."

The U.S. confirmed their release in a brief statement that did not identify them, specify when they had been moved or provide details of their resettlement. Lawyers for the men identified them as Abdul Razakah and Hammad Memet, both of whom were captured in Pakistan and held at Guantanamo for nearly 10 years.

El Salvador's foreign affairs office said in a statement that the men were brought into the country on Wednesday on humanitarian grounds and in recognition of the fact that other countries have taken in their citizens as refugees in the past because of the 1980-1992 civil war.

Their release brings the prisoner population at the U.S. base in Cuba to 169, including three more Uighurs who officials are eager to resettle in a third country.

"Hopefully more nations will follow by opening their doors to the other men at Guantanamo who are cleared for release but cannot safely be repatriated," said Seema Saifee, an attorney for Razakah.

Uighurs at Guantanamo posed a huge diplomatic headache for the U.S. government. Twenty-two of them were captured at the start of the Afghanistan war and shipped to the base in Cuba because officials suspected they had links to al-Qaida. But it turned out they were not terrorists and had merely fled their homeland in search of opportunities and freedom abroad.

Officials determined they posed no threat and could be released but could not send them to back China because American law forbids extraditing people to countries where they could face persecution and torture. China, which has been fighting the Uighur separatist movement in largely Muslim western Xinjiang province, wanted the men send back there and pressured other countries not to accept them as refugees.

U.S. courts and officials blocked efforts to settle the men in the U.S. and the prisoners were left in limbo. Through painstaking diplomatic efforts, Uighur prisoners from have settled in Albania, Bermuda, Switzerland, the Pacific island of Palau and elsewhere.

Eric Tirschwell, another lawyer for Razakah, said all those released to date are "living peaceful, productive lives and many have been reunited with or started families."

Memet, 33, and Razakah , who is in his mid-30s, are the first Guantanamo prisoners to be released or transferred in more than a year as a result of new restrictions imposed by Congress. Those restrictions did not apply to the men because a U.S. federal judge had ordered their release because they had not been determined to be "enemy combatants" who can be detained at the U.S. base in Cuba.

_____

Associated Press correspondent Marcos Aleman in El Salvador contributed to this report.