Pakistani soldiers closed in on Tuesday on a Taliban headquarters in Swat, the military said, as the United Nations called for help for hundreds of thousands of people displaced by the fighting.