hips were able to evade the attack, and stray rafts set Canton's waterfront on fire, illuminating the river and foiling the night attack. Downriver at Whampoa the Chinese attacked the British vessels at anchor there and attempted to prevent ships from reaching Canton. Having suspected an attack, (and as a consequence delaying his own offensive) Major General Gough consolidated the British forces at Hong Kong and ordered a rapid advance upriver to Canton. These reinforcements arrived on 25 May, and the British counter-attacked, taking the last four Qing forts above Canton and bombarding the city. The Qing army fled in panic when the city heights were taken, and the British pursued them into the countryside. On 29 May a crowd of around 20,000 Cantonese villagers and townspeople attacked and defeated a company of 60 Indian sepoys in what became known as the Sanyuanli Incident, and Gough ordered a retreat back to the river. The fighting subsided on 30 May 1841 and Canton came fully under British occupation. Following the capture of Canton the British command and the governor-general of Canton agreed to a cease-fire in the region. Under the terms of the limited peace (later widely referred to as "The Ransom of Canton"), the British were paid to withdraw beyond the Bogue forts, an action they completed by 31 May. The peace treaty was signed by Elliot without consulting the British army or Navy, an act which displeased General Gough.
The defense of Canton was declared a diplomatic success by Yishan. In a letter to the Emperor, he wrote that the barbarians had begged "the chief general that he would implore the great Emperor in their behalf, that he would have mercy upon them, and cause their debts to be repaid them, and graciously permit them to carry on their commerce, when they would immediately withdraw their ships from the Bocca Tigris, and never dare again to raise any disturbance." However, General Yang Fang was reprimanded by the Emperor for his agreeing to a truce rather than forcefully resisting the British. The Emperor was not informed the British expedition had not been defeated and was very much intact. The imperial court continued to debate China's next course of action for the war, as the Daoguang Emperor wanted Hong Kong retaken.
Following their withdraw from Canton, the British relocated the expeditionary force to Hong Kong. Just as with the Chinese commanders, the British leaders debated how the war should be continued. Elliot wanted to cease military operations and reopen trade, while Major General Gough wanted to capture the city of Amoy and blockade the Yangtze River. In July a typhoon struck Hong Kong, damaging British ships in the harbor and destroying some of the facilities the expedition was building on the island. The situation changed when on 29 July Elliot was informed that he had been replaced as Superintendent by Henry Pottinger, who arrived in Hong Kong on 10 August to begin his administration. Pottinger wanted to negotiate terms with the Qing for the entire country of China, rather than just the Pearl River, and so he turned away Chinese envoys from Canton and gave permission for the expeditionary force to proceed with its war plans. Admiral Sir William Parker also arrived in Hong Kong to replace Humphrey Fleming Senhouse (who had died of a fever on 29 June) as the commander of the British naval forces in China. It was agreed by the British commanders that combat operations should be moved north to put pressure on Peking, and on 21 August the fleet sailed for Amoy.
On 25 August the British fleet entered the Jiulong River estuary and arrived at Amoy. The city was prepared for a naval assault, as Qing military engineers had built several artillery batteries into the granite cliffs overlooking the river. A purely naval assault was considered too risky by Parker, prompting Gough to order a combined naval and ground attack on the defenses. On 26 August British marines and regular infantry (under the covering fire of the Royal Navy) flanked and destroyed the Chinese defenses guarding the river. Several 