and Solomon—peace be upon them both—upon that foundation. I say: It may be argued that what Shem—peace be upon him—founded must have stood upon the structure of the qiblah, in light of the preceding hadith. For it is related from al-Azraqī, on the authority of Mujāhid—may Allah have mercy on him—who said:
“Allah indeed created the earth two thousand years earlier, and its foundations lie in the seventh, lowest earth.”
He then related from ʿAlī ibn al-Husayn—may Allah have mercy on him—that the Sacred House was built by the angels—peace be upon them.
He then related from Ibn ʿAbbās—may Allah be pleased with them both—that Adam—peace be upon him—was the first to lay its foundations, pray in it, and circumambulate it. The site of the House was then effaced by the Flood, until Allah sent Abraham and Ishmael, who raised its foundations. If that was the case, and forty years separated it from al-Aqsā Mosque, then the beginnings of al-Aqsā Mosque must have preceded Shem—peace be upon him. For it is stated in al-Mughnī fī Gharīb al-Muhadhdhab that there were one thousand one hundred years between Adam and Noah—peace be upon them both.
Imam al-Khattābī pointed out in his book al-Aʿlām that the mosque had been built by some of Allah Most High’s pious servants before David and Solomon—peace be upon them both. David and Solomon subsequently built it, added a dome, and enlarged it, so its construction was attributed to them both. And Allah Most High knows best.