In 1169 the Fatimids were crushed by the armies of Saladin already flush with victories in Palestine and Syria who established the Ayyubid Dynasty and created the fortified citadel to protect Cairo.
The Fatimids were crushed by the Saladin armies.