if the prescribed time of Zhuhr (Noon) Prayer comes while a ship was returning to port, but the prescribed time of `Asr (Afternoon) Prayer would come before reaching the port, will it be better to combine between Zhuhr and 'Asr Prayers and pray them together
at the time of Zhuhr while shortening the prayer? Or will it be better to only pray Zhuhr on board then `Asr on their arrival at the port either in two or four Rak`ahs (units of Prayer)? Is it permissible for those on board to postpone the performance of both Zhuhr and `Asr until they enter the port and then pray them there in congregation or at home as Jam` Ta'khir (Combining two Prayers in the time of the latter)? If this is permissible, are they allowed to shorten these two prayers?
Regarding the case mentioned in the question, it is better to do Jam` Ta'khir (combining two Prayers in the time of the latter) so as to follow the example of the Prophet (peace be upon him). It is narrated that whenever the Prophet (peace be upon him) started a journey before noon, he (peace be upon him) would postpone Zhuhr and pray it with `Asr; and whenever he started a journey before sunset, he would postpone Maghrib (Sunset) Prayer and pray it with `Isha' (Night) Prayer. Residents, who are allowed to combine the Prayers, should take the easier option whether Jam' Taqdim (combining two Prayers in the time of the former) or Jam` Ta'khir along with shortening the Prayers. However, if the port is inside the country, they work at the port, or they intend to stay there for more than four days; they are not allowed to shorten the Salah while they are in the port. Moreover, they are permitted to pray the shortened Zhuhr on time on board and then postpone `Asr to be performed when they reach the port.