The Prophet ﷺ said, "The rider travels behind the funeral procession, while the one on foot may walk behind it, in front of it, to its right, or to its left, staying close to it. The miscarried child is prayed over, and forgiveness and mercy are invoked for its parents."
أن النبي ﷺ قال: الراكب يسير خلف الجنازة، والماشي يمشي خلفها وأمامها، وعن يمينها وعن يسارها قريبا منها، والسقط يصلى عليه، ويدعى لوالديه بالمغفرة والرحمة.
Abu Dawud (3180), Tirmidhi (1031), Ibn Majah (1481, 1507), and Nasai (1943) all narrated it through various routes from Ziyad bin Jubayr bin Hiya, from his father, from Mughira bin Shuba, as mentioned, with the wording being that of Abu Dawud. Tirmidhi said, "hasan sahih." I say, it is as he said. Ibn Hibban (3049) graded it sahih, as did Hakim (1/355, 363), who said, "sahih according to the criterion of Bukhari." However, Daraqutni included it in Al-Ilal (7/134-135) and said, "Yunus bin Ubayd narrated it from Ziyad bin Jubayr, but there is disagreement about his narration. Abdullah bin Bakr Muzani raised it to the Prophet from Yunus, while Qabisa narrated it from Thawri, from Yunus, but was uncertain about raising it. The rest narrated it from Yunus as stopping at the companion level, except that Ibn Ulaya and Anbasah bin Abdul-Wahid both said, from Yunus, and Ziyad's family members raise it to the Prophet. Yunus said, as for me, I do not recall raising it to the Prophet."I say, certainty is not removed by doubt, and moreover Ziyad's family knows better than others. Yunus said, and I think that Ziyad's family informed me that he raised it to the Prophet ﷺ. This is how Abu Dawud mentioned it in his Sunan, and Bayhaqi (8/4) narrated it from him. Then Bayhaqi narrated it from his teacher Hakim, who reported that Ahmad bin Sulayman bin Hasan the jurist told him, Hasan bin Mukrim told us, Rawh bin Ubada told us, Saeed bin Ubaydullah bin Jubayr bin Hiya told us, saying, my uncle Ziyad bin Jubayr bin Hiya told me, saying, my father Jubayr bin Hiya Thaqafi told me, that he heard Mughira bin Shuba say, and he mentioned the hadith.In summary, the hadith is sahih as a raised narration (marfu), and the doubt of some narrators about its being raised does not harm it. However, it is preferable to walk if the cemetery is a short distance away, since it has not been established in sahih reports that the Prophet ﷺ rode while going to the cemetery.As for what is reported from Jabir bin Samura, who said, "I saw the Messenger of Allah ﷺ go out with the funeral of Thabit bin Dahdah on a white-blazed, white-socked horse that he loved, without a saddle on it, with the people accompanying him, gathered around him. He said, the Messenger of Allah ﷺ then dismounted and prayed over him, then sat until he was finished with him, then he said, he then sat on his horse, and set off, with the men walking around him," this is very daif.Abdullah narrated it in his additions to his father's Musnad (20944) from Abu Qasim Zuhri Abdullah bin Saad, who said, my father and my uncle said, our father told us, from Ibn Ishaq, Umar bin Musa bin Wajih told me, from Simak bin Harb, from Jabir bin Samura, and he mentioned the hadith. Umar bin Musa bin Wajih is very daif. Ibn Hibban said, "He was among those who narrated obscure reports from well-known narrators, and when his narrations from reliable narrators, containing things unlike the hadiths of trustworthy narrators, became numerous, he fell outside the bounds of integrity, and thus deserved to be abandoned" (Al-Majruhin, 637). Hafiz also spoke harshly of him in Al-Tajil, because the sahih and established narration, as will come, is that he returned riding.It is also reported from Ibn Umar, who said, "I saw the Prophet ﷺ, Abu Bakr, and Umar walking in front of the funeral." Abu Dawud (3179), Tirmidhi (1007), Nasai (1944), and Ibn Majah (1482) all narrated it through various routes from Sufyan, from Zuhri, from Salim, from his father, as mentioned. Its chain is sahih, but most scholars of hadith preferred the mursal (unconnected) version, including Ibn Mubarak, Ahmad, Bukhari, Nasai, and others.Tirmidhi said, "The hadith of Ibn Umar was narrated in this way by Ibn Jurayj, Ziyad bin Saad, and more than one other from Zuhri, from Salim, from his father, similar to the hadith of Ibn Uyayna. But Mamar, Yunus bin Yazid, Malik, and more than one of the memorizers of hadith narrated from Zuhri that the Prophet ﷺ used to walk in front of funerals. Zuhri said, and Salim informed me that his father used to walk in front of the funeral. The scholars of hadith all consider the mursal hadith on this matter to be more sahih." Tirmidhi said, "I heard Yahya bin Musa say, Abdul-Razzaq said, Ibn Mubarak said, the mursal hadith of Zuhri on this is more sahih than the hadith of Ibn Uyayna." Ibn Mubarak said, and I think Ibn Jurayj took it from Ibn Uyayna.Tirmidhi said, "Hammam bin Yahya narrated this hadith from Ziyad bin Saad, Mansur, Bakr, and Sufyan, from Zuhri, from Salim, from his father, but it is actually Sufyan bin Uyayna from whom Hammam narrated." Nasai likewise confirmed this, saying, "Sufyan, Mansur, Ziyad, and Bakr, who is Ibn Waail, all mentioned that they heard Zuhri narrate that Salim informed him that his father informed him, that he saw the Prophet ﷺ, Abu Bakr, Umar, and Uthman walking ahead of the funeral, though Bakr alone did not mention Uthman." Nasai said, "This is an error, and the correct version is the mursal one."However, Ibn Hibban narrated in his Sahih (3047) something that confirms the connected (musnad) status of this hadith, from Hasan bin Sufyan, who said, Yaqub bin Sufyan Farsi told us, who said, Humaydi told us, who said, Sufyan told us, who said, Zuhri told us more than once, I bear witness to it against him, who said, Salim bin Abdullah informed me, from his father, who said, "I saw the Messenger of Allah ﷺ, Abu Bakr, and Umar walking in front of the funeral." Sufyan was then asked, "Does it include Uthman?" He said, "I do not recall that." He was told, "Some people only say it from Salim." He said, "Zuhri narrated it to us more than once, I bear witness to it against him." He was also told, "Ibn Jurayj says as you say, but adds Uthman in it." Sufyan said, "I did not hear it, and Uthman was mentioned." End of quote.Then Ibn Hibban narrated it (3048) from another route agreeing with Sufyan's narration, from Muhammad bin Ubaydullah bin Fadl Kalai in Hims, who said, Amr bin Uthman bin Saeed informed us, who said, my father told us, who said, Shuayb bin Abu Hamza told us, from Zuhri, from Salim bin Abdullah, that Abdullah bin Umar bin Khattab used to walk in front of the funeral. He said, and indeed the Messenger of Allah ﷺ used to walk in front of it, along with Abu Bakr, Umar, and Uthman. Zuhri said, and that is the sunnah. End of quote.Bayhaqi (24/4) said, after mentioning the disagreement of the narrators regarding Zuhri, "Whoever connected it, and remained consistent in connecting it, without any disagreement occurring about him in it, namely Sufyan bin Uyayna, is a reliable authority." In Bayhaqi's statement there is an indication that the one who connected it, without disagreement occurring about him, is Ibn Uyayna alone, while the rest have disagreement occurring about them. Then the scholars stated clearly that Ibn Uyayna erred in it, and confusion entered upon him, as Nasai said in Al-Kubra (632/1), because Mamar, Yunus, and Malik narrated it from Zuhri as mursal.Nasai reported from Ibn Mubarak that he said, "The memorizers from Ibn Shihab are three, Malik, Mamar, and Ibn Uyayna. So if two of them agree on a statement, we take it and leave the statement of the other." Nasai said, "Ibn Mubarak mentioned this statement from the scholars of hadith." End of quote.On this subject there is also a report from Anas bin Malik, that the Prophet ﷺ, Abu Bakr, Umar, and Uthman used to walk in front of the funeral. Tirmidhi (1010) and Ibn Majah (1483) both narrated it through the route of Muhammad bin Bakr Barsani, who said, Yunus bin Yazid Ayli informed us, from Zuhri, from Anas bin Malik, as mentioned. Tirmidhi said, "I asked Muhammad, meaning Bukhari, about this hadith, and he said, this hadith is an error, Muhammad bin Bakr erred in it, and this hadith is actually narrated from Yunus, from Zuhri, that the Prophet ﷺ, Abu Bakr, and Umar used to walk in front of the funeral. Zuhri said, and Salim informed me that his father used to walk in front of the funeral. Muhammad, Bukhari, said, this is more sahih." And Allah, exalted, knows best what is correct.Likewise, what is reported from Ibn Masud is not sahih, that he said, "We asked our Prophet ﷺ about walking with the funeral, and he said, 'Nothing beyond a light trot, if it is good, then hasten to it, and if it is otherwise, then let the people of hell be further away, and the funeral is followed, it is not followed, none should walk ahead of it.'" Abu Dawud (3184), Tirmidhi (1011), and Ibn Majah (1484) all narrated it through various routes from Yahya bin Abdullah Taymi, from Abu Majida, or Majid, from Ibn Masud, as mentioned, with the wording being that of Abu Dawud, and Tirmidhi's wording is close to it. As for Ibn Majah, he abridged it to his statement, "The funeral is followed, and it is not a follower, none should walk ahead of it."Abu Dawud said, "It is daif, he is Yahya bin Abdullah, who is Yahya Jabir." Abu Dawud said, "This one is Kufan, while Abu Majida is Basran." Abu Dawud said, "This Abu Majida is unknown." End of quote. Tirmidhi said, "This hadith is not known from the hadith of Abdullah bin Masud except through this route." He said, "I heard Muhammad bin Ismail weaken this hadith of Abu Majid." Muhammad said, "Humaydi said, Ibn Uyayna said, Yahya was asked, who is this Abu Majid? He said, a bird that flew away and then narrated to us." End of quote. More than one of the scholars have said that this Abu Majid is an unknown man. The meaning of "a bird that flew away" is, an unknown man whom we do not concern ourselves with.