The most significant of these actions were in the course of the War of the Spanish Succession (1701-13, Britain not involved until 1702), as the European powers jostled for control of the Spanish empire following the death of the last Spanish Habsburg king, Charles II, in 1700. On July 23rd, 1704, British naval forces captured Gibraltar and held out against Franco-Spanish attempts to regain it, while a few weeks later on August 13th, John Churchill, then Earl of Marlborough, heavily defeated a Franco-Bavarian army at Blenheim in Bavaria