عن جابر رضي الله عنه قال: «كان رسول الله صلى الله عليه وسلم يُصلِّي على راحِلَته، حيث تَوَجَّهَت فإذا أراد الفَرِيضة نَزل فاسْتَقبل القِبْلة».
[صحيح] - [رواه البخاري]
المزيــد ...
Jābir (may Allah be pleased with him) reported: The Messenger of Allah (may Allah's peace and blessings be upon him) used to pray on his riding animal, regardless of the direction it was facing. When he wanted to perform an obligatory prayer, he would dismount and face the Qiblah.
[Authentic hadith] - [Narrated by Bukhari]
While on a journey, the Prophet (may Allah's peace and blessings be upon him) would not dismount from his riding animal (to pray), rather he used to pray while mounted. This is supported by what Ibn ‘Umar and others narrated; that the Prophet (may Allah's peace and blessings be upon him) used to pray atop his riding animal, regardless of the direction it was facing, during his travels [Al-Bukhāri]. So when he was seated on his riding animal, he would pray in whatever direction he was riding, regardless of whether he was facing the Qiblah or not. When it came to an obligatory prayer – the five daily prayers – he would dismount from his animal and pray on the ground while facing the Qiblah. In the Hadīth of Ibn ‘Umar (may Allah be pleased with him): "And he would not do this – performing the prayer on his riding animal – in the obligatory prayers." The obligatory prayers must be performed on the ground, except in case of a Shariah-approved excuse, such as rain or fear of the enemy. In this case, it is not a problem to perform them on one's riding animal; or in case of illness, one prays them on his bed while sitting, especially if one fears the passing of its time. This is supported by proofs that indicate facilitation, alleviation, and removal of blame from this nation, as Allah, the Exalted, says: {Allah burdens not a person beyond his scope} [Sūrat al-Baqarah: 286], and the Prophet (may Allah's peace and blessings be upon him) said: "If I commanded you with something, then you should fulfill it to the best of your ability."