Summary

Yosef Karo Translation:Shulchan Aruch — Orach Chaim 688…

If they intended to return only after the time of the reading, they read with the people of the place where they are currently. Rem"a: And if one is in the desert or on a boat, one reads on the 14th like the rest of the world (Kol Bo) .
סעיף ה
בן עיר שהלך לכרך או בן כרך שהלך לעיר אם היה דעתו לחזור למקומו בזמן קריאה ונתעכב ולא חזר קורא כמקומו ואם לא היה בדעתו לחזור אלא לאחר זמן הקריאה קורא עם אנשי המקום שהוא שם: הגה ואם הוא במדבר או בספינה קורא ביום י"ד כמו רוב העולם [כל בו] :
688:6 If the 15th falls on Shabbat, we do not read the Megillah on Shabbat.
Source: Wikisource

Yosef Karo Translation:Shulchan Aruch — Orach Chaim 688…

Shulchan Aruch Orach Chaim 688 The law for cities which were surrounded by a wall in the days of Yehoshua Bin Nun
דין כרכים המוקפים חומה מימות יהושע בן נון
688:1 Cities that had a wall surrounding it at the time of Yehoshua Bin Nun, even if they currently do not have a wall surrounding them, read the Megillah on the 15th of Adar, even if they are outside the Land of Israel, and even if they do not have ten batlanim (meaning people who are unemployed and who busy themselves with the needs of the congregation) .
Source: Wikisource

Yosef Karo Translation:Shulchan Aruch — Orach Chaim 688…

The same applies to villages that are visible to them even though they are not adjacent to them, e.g. they are on a mountain, or [to cities that are] adjacent to them even though they are not visible to them. e.g. they are in a valley. This assumes that they are not farther than a mil. And Shushan, even though it was not surrounded by a wall from the days of Joshua, reads on the 15th [of Adar] since this is where the miracle occurred.
Source: Wikisource

Get perspective with Kwize: daily news enlightened by great literature