Spanish–Moro conflict
The Spanish initiated the conflict by conquering the Philippines and invading Moro territory in an effort to subjugate the region to their rule since the 1500s. When the Spanish conquered the Muslim Kingdom of Maynila, a vassal of the Sultanate of Brunei, the Islamic rajah, Rajah Sulayman resisted the Spanish. Manila then became the capital of the Spanish Philippines after the conquest, with the Spanish forcibly converting people to Catholicism. The Spanish–Moro Wars started with the Castille War, a war between Spaniards and the Sultanate of Brunei. (The term "Moro" at this time included Muslim Tagalogs who were ruled by the Sultanate of Brunei).
List of countries where Spanish is an official language
Spanish was an official language of the Philippines from the beginning of the Hispanic period in 1565 and through independence until a constitutional change in 1973. 
However, President Ferdinand Marcos had Spanish redesigned as an official language under Presidential Decree No. 156, dated 15 March 1973 and Spanish remained official until 1987, when it was re-designated as a voluntary and optional auxiliary language.