Jerusalem is a holy city to three religions, judaism, islam, and christianity. The Moslems contend that Mohammed ascended to Paradise from the city, the Jews' Temple was built in the city, and the Christians look to it as the center of the the lands where Christ lived.
Based on this contentious history, one would guess (correctly) that Jerusalem has been the center of conflict for centuries. It was the object of the Crusades, one of Saladin's conquests, and even to present day, is the object of desire for many groups.
Under the Roman Empire, Jerusalem was sacked, and subsequent to Simon Bar Kokhba's revolt (132-135CE) the Jews were forbidden to enter the city on all but one day a year, when they were allowed to gather at the only remaining section of the wall of the Second Temple to weep for the destruction of their city.
Later, with the onset of Christianity in the Empire, the emperor Constantine was to build the Church of the Holy Sepulchre over and around the tomb in which Christ was said to have been layed, and city became a Christian centre of worship.
In 638CE the Muslims conquered the city, and the Dome of the Rock was completed 60 years later. The Muslims ruled the city with religious tolerance, allowing the Jews back and allowing Christians to worship. However, in the 11th century, a Caliph of the Egyptian Fatimids reversed this policy and it was (in part) this which set off the First Crusade.
Between 1089 and 1187 Jerusalem was a Christian city, capital of the Kingdom of Jerusalem. Saladin then recaptured it for Islam and this was the position for the remainder of period, although in 1517 it passed from the Egyptian to the Ottoman Muslims, who began rebuilding its structure, and allowed religious tolerance once more.