Madison's presidency was dominated by the effects of the ongoing Napoleonic Wars. Initially, American merchants had benefited from the war in Europe since it allowed them to increase their shipping activities, but both the British and French began attacking American ships in an attempt to cut off trade. In response to persistent British attacks on American shipping and the British practice of impressment, the United States declared war on Britain, beginning the War of 1812. The war was an administrative morass, as the United States had neither a strong army nor financial system, and the United States failed to conquer Canada. In 1814, the British entered Washington and set fire to the White House and the Capitol. However, the United States won several notable naval victories and crushed the resistance of British-allied Native Americans in the West. Shortly after the American triumph at the Battle of New Orleans, the war ended with the ratification of the Treaty of Ghent, in which neither party made major concessions. Despite the lack of gains in the war, the timing of the treaty convinced many Americans that the United States had won a great victory in the war, and Madison's popularity grew. The Federalists collapsed as a national party in the aftermath of the war, which they had strongly opposed.