it says:
Glory to (Allah) Who did take His servant for a Journey by night from the Sacred Mosque ,b>to the farthest Mosque, whose precincts We did bless,- in order that We might show him some of Our Signs: for He is the One Who heareth and seeth (all things).It just said "the farthest mosque". It never mentioned Jerusalem. And THERE WAS NO MOSQUE in Jerusalem until well after Mohammad died.
Hey, Maybe Allah was using the flying she-horse to give him a glimpse of the future.... :)
Speaking more generally, the name "Jerusalem" never occurs in the Koran, and neither does any alternate name for that city.