Al-Gamali was governor of Acre in 1074 when the Fatimid caliph, Al-Mustansir, called him to put down the revolt of the Turkish military commanders and their troops. After summarily executing the rebels, Al-Gamali's first task was to reinforce the defenses of Al-Qahira (Cairo) and rebuild Gawhar's brick wall, which had collapsed. He did so with stone, which marked the beginning of a newly cultivated taste for stone in Cairo. However, it should be realized that a considerable amount of stone that he used originated in the Giza necropolis, and so this also marks the destruction of many of those pharaonic monuments around Cairo
Prior to about 1087, Cairo was not really much of a fortified city with its sun dried brick walls built by Gawhar, though this weakness had demonstrated itself on occasions. That year, Badr ad-Din el-Gamali, employed three Christian Syrian monks (one named John the Monk) from Edessa to build the three main gateways of the Fatimid wall made of stone which was to provide fortification. These massive gates are called Bab el-Futuh (Gate of Conquest), Bab al-Nasr (Gate of Victory) and Bab Zuwaila, and they mark the southern and northern boundaries of the ancient city.
The present Bab Al-Nasr replaced the original one, built by Gawhar a little to the south. Badr named it Bab Al-Izz (Gate of Glory) but the tradition of the people prevailed and its name was never actually changed.
Bab al-Nasr is the only one of the three major gates of ancient Cairo composed of two rectangular towers Those of both Bab el-Futuh and Bab Zuwaila have rounded towers. Bab al-Nasr towers are solid stone up to the second level. This tower is perhaps the least decorated of the three. The inscription over the entrance gives the name of Badr al-Gamali and the date, and reads, "By the power of Allha, the powerful and the strong, Islam is protected, fortresses and walls are raised up.
" Here, the entrance vestibule is cross vaulted and a pair of shallow domes on spherical pendentives cover the upper level of the towers. At Bab el-Futuh, the arrangement is the opposite, with the entrance vestibule having a shallow dome and the towers each with a cross vault with a carved medallion at the intersection. Above the entrance arch an inscription slab in Kufic carries the shahada with the Shi'a reference to 'Ali.
In fact, like the other gates, this one features architectural and iconographic features hitherto unknown in Muslim Egypt. For example, spherical-triangle pendentives are employed to carry the dome over the room which occupies the upper part of each tower at Bab al-Naser, and there are intersecting, rising tunnel vaults in the staircase that leads to the platform of this gate, and in the small staircase descending from the same platform to the rampart walk.
The projecting towers enabled the defenders to deliver flanking fire against attackers trying to scale the wall between the towers. The defenders could move from tower to tower under complete cover, and guard rooms, living quarters and supply points made each section of the wall a fortress in itself.
A very significant feature of decoration at Bab al-Nasr are the shields and swords that Creswell identifies as Byzantine in shape. Some point downward while others are circular. They no doubt are symbolic of the protection that the walls afford against invaders. The name, "Gate of Victory," like Bab el-Futuh, "Gate of Conquest," should also be understood as talismanic. Interestingly, these fine walls, really initially built to protect Cairo from the Seljuk Turks, were never challenged by invaders. Indeed, by the late medieval period, they were so encroached upon by other buildings that travelers often reported that Cairo had no fortification at all.
During the reign of the Caliph al-Amir, his vizier, al-Ma'mum al-Bata'ihi, who built the al-Aqmar mosque, transferred the observatory, originally built by al-Hakim, from the Muqattam hill and established it at Bab al-Nasr. The transportation of the heavy metal observatory was an extremely difficult task that needed scaffolds and wheels, a large team of workers and an architectural structure to support it. Al-Ma'mun, however, fell into disgrace before the observatory could be used, and the angry Caliph ordered it to be dismounted because it had been named al-rasad al-ma'muni, which attributed it to the vizier rather than to the Caliph.
Bonaparte's troops used Bab al-Nasr to protect themselves from the rebellious Cairo population. The Husayniyya quarter, where it was located at the time, was famous for its untamed and violent character. It was not easy to subdue, but after a French officer of Polish origin, Schulkowky, was killed by a Husayniyya resident, the French troops bombarded the Husayniyya from these walls and entirely demolished the district. Afterwards, it posed no problem at all.
French officers' names can still be seen carved near the upper level of the gates. The French blocked up the crenellations at the top and enlarged the arrow slits for canon holes. As with the other towers of the northern wall, Napoleon's troops renamed the eastern tower Tour Corbin and the western one Tour Julien, after two of his aides-de-camp. Of course, these names left with the French.
Creswell also attributes the machicoulis at Bab al-Nasr, a protruding structure used to spill burning liquids on attackers, to the French. It was not until the 20th century that the walls were cleared of various obstructions including more modern buildings and made visible again.
Apart from being great representatives of Islamic military architecture, all three of these gates are particularly important for being among the very few examples of military work predating the Crusades.