Updated

The Afghan government took official control of the southern Taliban stronghold of Marjah on Thursday, installing an administrator and raising the national flag while U.S.-led troops rooted out final pockets of militants.

The ceremony occurred in a central market as U.S. Marines and Afghan troops slogged through bomb-laden fields in northern parts of the town. Some 700 residents gathered to see Abdul Zahir Aryan formally appointed as the top government official in Marjah, according to U.S. officials at the event.

SLIDESHOW: U.S.-Led Forces Launch Attack on Taliban Stronghold

"It's a very historical day, a new beginning," Brigadier General Larry Nicholson, the commander of the U.S. Marines in southern Afghanistan, told the crowd as U.S. snipers stationed on the roofs of surrounding buildings watched over.

In what had characteristics of a victory celebration, Nicholson said of the assembly: "I am so moved by this, so very thrilled by the turnout ... They are voting with their eyes, and they believe there is a fresh start for Marjah under the government of Afghanistan."

Aryan and a team of advisers held their first meeting in the town Monday and have been staying overnight in a building there since Tuesday, said Marlin Harbinger, the senior U.S. government representative for Helmand province, which contains Marjah.

"Today's event was the civilian Afghan government re-establishing itself officially in front of the local residents," Harbinger said. The Afghan army had previously raised the country's green-and-red flag nearby, but that was only a claim of military control over that neighborhood, he said.

The ceremony opened with a reading from the Quran, and then Aryan and the Helmand governor pledged to those gathered that they were ready to listen to their needs and eager to provide them with basic services that they didn't have under the Taliban.

After the ceremony, the generals and high-level officials departed in helicopters, but Aryan remained.

The mass assault in southern Helmand province, with 15,000 NATO and Afghan troops, is the largest military operation in Afghanistan since the U.S.-led ouster of the Taliban regime in 2001.

NATO's strategy is to rout Taliban militants from the town, which had served as a logistical base and drug trafficking hub, restore the Afghan government's presence, and rush in public services in a bid to win over the confidence of local communities.

In the north Thursday, the Marines' progress was slowed by difficult terrain with no roads, few tracks and many hidden mines, but there was no gunfire by midmorning. Several armored vehicles fell into irrigation canals while others were damaged by roadside bombs.

About 100 fighters are believed to have regrouped into the 28-square mile area known as Kareze, according to commanders with the 3rd Battalion, 6th Marines Regiment. The Marines and their Afghan partners are working to secure the area, believed to be the last significant pocket of Taliban insurgents in town.

The last few days have been relatively calm throughout Marjah, with limited engagement by insurgents, as troops secured areas they had already taken and moved into position to tackle the final insurgent holdouts.

NATO said in a statement that while there are still occasional gunfights in the town, the number of residents returning has increased in recent days and shops have opened to sell telephones and computers alongside fresh fruits and vegetables.

In a sign that NATO's push to win over the population may be gaining traction, bomb tips from residents have increased by nearly 50 percent, the alliance said.

As the offensive closes in on its second week, 13 NATO troops and three Afghan soldiers have been killed, according to military officials. Eighty NATO troops have been wounded, along with eight Afghans.

At least 28 civilians have been killed, including 13 children, according to the Afghan human rights commission.

The civilian toll has raised fears that NATO may lose the support of the population even as it drives out the Taliban. The deaths come even though NATO has said its priority is protecting the civilian population and has adopted strict rules to prevent casualties.

A spokesman for the Afghan Defense Ministry said both the Afghan government and NATO troops realized they had to be realistic and accept that there would be civilian deaths.

"Preventing civilian casualties is our biggest challenge," Gen. Mohammad Zahir Azimi told reporters in Kabul. "You should not expect zero casualties, either from our side or from the international forces. That will only happen when the fighting is over. And we are all trying to make that happen."

NATO spokesman Brig. Gen. Eric Tremblay, speaking alongside Azimi, urged Afghans to recognize that international troops are putting themselves in greater danger in order to try to protect civilians.

"We are going beyond the laws of armed conflict by increasing our risk," Tremblay said.

The Associated Press contributed to this report.