I believe the answer is: "The United States invaded and ended the rule of the Taliban, but U.S. troops have remained for years due to continued attacks from Taliban supporters"
United states wanted to wiped out Taliban from Afghanistan, but Taliban supporters choose to help them and hide the Taliban troops within the civilian neighbourhood . This made united states troops unable to progress their operation and forced to remained for years.