Mexican–American War from the war of independence (1810–1821) as a weak and divided force. Before the war with the United States, the military faced both internal and foreign challenges. The Spanish still occupied the coastal fortress of San Juan de Ulúa, and Spain did not recognize Mexico's independence, so that the new nation was at risk for invasion. In 1829, the Spanish attempted to reconquer their former colony and Antonio López de Santa Anna became a national hero defending the homeland. The army had a set of privileges ("fueros"), established in the colonial era, that gave it jurisdiction over many aspects of
Spanish conquest of the Aztec Empire "The Aztecs Under Spanish Rule: A History of the Indians of the Valley of Mexico, 1519–1810" (1964) were central in reshaping the historiography of the indigenous and their communities from the Spanish Conquest to the 1810 Mexican independence era. Scholars who were part of a branch of Mesoamerican ethnohistory, more recently called the New Philology have, using indigenous texts in the indigenous languages, been able to examine in considerable detail how the indigenous lived during the era of Spanish colonial rule. A major work that utilizes colonial-era indigenous texts as its main source is James Lockhart's "The Nahuas After the