How have American counterinsurgency tactics in Iraq and Afghanistan improved from earlier counterinsurgency struggles?
US counterinsurgency tactics today are much different than they were 100+ years ago when we fought in the Philippines and are even somewhat different than they were in Vietnam. Whether those differences are sufficient to allow the US to win in Afghanistan is very much yet to be seen.
In the Philippines, the US simply tried to win through brutality. There were no attempts at cultural awareness or winning "hearts and minds." By the time of the Vietnam War, there were those who were trying to implement mdoern tactics, but those tactics were not as widely used as they are now. In Vietnam, the US still tried to rely much more on military tactics. They tried to win, for the most part, not by living with the Vietnamese and helping them, but more by trying to go out hunting the insurgents. The US did things like the strategic hamlets program that completely turned the Vietnamese against them.
In Iraq and Afghanistan, tactics have changed greatly. Americans are now taught to try to provide security for the native population. The US strategy is to "clear, hold, and build." This focuses on providing a better life for people in a given area by clearing the area of insurgents, holding it with manpower, and then building its economy and society back up. This is a strategy that is focused much more on helping the local population than on military activity.
Again, these are ideas that were not unknown in the Vietnam Era. The real difference is that now they are the doctrine embraced by the highest levels of command whereas in Vietnam they were fringe ideas that were not supported with sufficient resources.