The Muslim fixation and clamor on Jerusalem is actually a very recent historical development, a product of political conflict, not historical truth.
Jerusalem rates not a single mention in the Quran and Muslims face Mecca in prayer.
In the seventh century, the Damascus-based Umayyad rulers built up Jerusalem as a counter-weight and hajj pilgrimage alternative to Mecca, where their political rivals were. This is when the important Muslim shrines, the Dome of the Rock (691 CE) and, later, the Al-Aqsa Mosque (705 CE), were intentionally built on the site of the destroyed biblical Jewish temples –– a time-honored practice to physically signal the predominance of Islam.
However, references in the Quran and hadith to Muhammad’s night journey to heaven on his steed Buraq from the ‘farthest mosque’ couldn’t mean Jerusalem because the Quran refers to Palestine as the “nearest” place. And it couldn’t have been a reference to the Al-Aqsa (‘Furtherest’) Mosque, for the simple reason that the Al-Aqsa Mosque didn’t exist in Muhammad’s day.
With the demise of the Umayyad dynasty and the shift of the caliphate to Baghdad, Jerusalem fell into a long decline, scarcely interrupted by occasional bursts of Muslim interest in the city during the Crusader period and the Ottoman conquest. Mark Twain, visiting in 1867, described it as a “pauper village.”
It did, however, become a majority Jewish city during the nineteenth century. The 1907 Baedekers Travel Guide lists Jerusalem with a population of 40,000 Jews, 13,000 Muslims and 7,000 Christians.
So little did Jerusalem mean to the Ottomans that, during the First World War, they abandoned it to the British without a fight and even contemplated entirely destroying the city before pulling out.