General Zachary Taylor (1784-1850) commanded the northern campaign in the Mexican-American War and later became the twelfth president of the United States. President Polk ordered General Taylor to approach the Rio Grande after the U.S. annexed Texas in late 1845. In April 1846, Mexican soldiers intercepted a small patrol of Taylor's soldiers, killing sixteen Americans. The incident became Polk's justification for sending a war bill to Congress.
Taylor had enormous military successes against the Mexicans at Palo Alto and subsequently at Resaca de la Palma. His forces then surrounded the Mexican stronghold at Monterrey, forcing General Pedro Ampudia to surrender. Infuriated by Taylor's lenient treatment of those Mexican forces, Polk transferred Taylor's forces to join Gen. Winfield Scott's invasion of central Mexico at Veracruz. To capitalize on the resulting upheaval in troop assignments, Mexican General Antonio Lopez de Santa Anna headed north from San Luis Potosí with an army of 20,000 men and attacked, but Taylor's reserves under Colonel Jefferson Davis—later to become the President of the Confederacy—successfully stalled Mexican forces. Late in February 1847, Taylor ordered a counter-attack that halted the Mexican offensive by nightfall. This victory at Buena Vista made Taylor a popular hero, much to Polk's chagrin, and Taylor was nominated for President on the Whig ticket in 1848. He was elected and assumed office in 1849.