In the first year of the 20th century the Ottoman sultan ordered the start of building work on the Hejaz railway to allow easier access for pilgrims to the holy places.
When Ottoman Sultan, Selim I appeared, with an army, at the gates of Jerusalem in 1517 he was welcomed by the Ulama who peacefully presented him with the keys to the city