 Naval conflicts with Western powers earlier in the 19th century such as the First and Second Opium Wars, during which European warships decisively defeated China's traditional junk fleets, prompted a major rearmament program that began in the 1880s under the Viceroy of Zhili province, Li Hongzhang.Advisers from the British Royal Navy assisted the program, and the first group of ships—several ironclad gunboats and two small cruisers—were bought from British shipyards.Following a dispute with Japan over the island of Formosa, the Chinese Navy decided to buy large ironclad battleships to match the Imperial Japanese Navy ironclads of the and es then under construction.