heat was unbearable and the army was exhausted and needed a rest, but there was not enough time and so Bonaparte drew up his 25,000 troops for battle approximately from the Pyramids of Giza. He is said to have shown his army the pyramids behind the enemy's left flank and at the moment of ordering the attack shouted "Soldiers, see the tops of the Pyramids" – in accounts written long afterwards, this phrase was altered into "Soldiers, remember that from the top of these pyramids, 40 centuries of history contemplate you." This was the start of the so-called Battle of the Pyramids, a French victory over an enemy force of about 21,000 Mamluks. (Around 40,000 Mamluk soldiers stayed away from the battle.) The French defeated the Mamluk cavalry with a giant infantry square, with cannons and supplies safely on the inside. In all 300 French and approximately 6,000 Mamluks were killed. The battle gave rise to dozens of stories and drawings. Dupuy's brigade pursued the routed enemy and at night entered Cairo, which had been abandoned by the beys Mourad and Ibrahim. On 4 Thermidor (22 July), the notables of Cairo came to Giza to meet Bonaparte and offered to hand over the city to him. Three days later, he moved his main headquarters there. Desaix was ordered to follow Mourad, who had set off for Upper Egypt. An observation corps was put in place at Elkanka to keep an eye on the movements of Ibrahim, who was heading towards Syria. Bonaparte personally led the pursuit of Ibrahim, beat him at Salahie and pushed him completely out of Egypt. The transports had sailed back to France, but the battle fleet stayed and supported the army along the coast. The British fleet under the command of Horatio Nelson had been searching in vain for the French fleet for weeks. The British fleet had not found it in time to prevent the landings in Egypt, but on 1 August Nelson discovered the French warships anchored in a strong defensive position in the Bay of Abukir. The French believed that they were open to attack only on one side, the other side being protected by the shore. During the Battle of the Nile the arriving British fleet under Horatio Nelson managed to slip half of their ships in between the land and the French line, thus attacking from both sides. In a few