 The mosque is an irregular rectangle with four arcades that surround the courtyard . As with the Ibn Tulun mosque , the arches are pointed and rest on brick piers . It resembles the al @-@ Azhar mosque in having three domes along the qibla wall , one at each corner and one over the mihrab . Also like al @-@ Azhar , the prayer hall is crossed by a transept at right angles to the qibla . This wide and tall central aisle leading to the prayer niche borrows from the Mahdiya mosque 's design . The al @-@ Hakim mosque differs from the al @-@ Azhar and Ibn Tulun mosques in having two stone minarets at the corners of the stone façade , which has a monumental projecting portal like the Mosque of Mahdiya . 
