The Messenger of Allah ﷺ saw some phlegm on the qiblah wall of the mosque. He turned to the people and said, "What is the matter with one of you that he stands facing his Lord and then spits phlegm in front of Him? Would any of you like to be faced and have someone spit phlegm in his face? When one of you needs to spit phlegm, let him spit to his left, or under his foot. If he cannot, then let him spit into his garment like this."Qasim then demonstrated by spitting into his garment and rubbing one part of it against the other.
حدثنا إسماعيل حدثني القاسم بن مهران عن أبي رافع
أن رسول الله ﷺ رأى نخامة في قبلة المسجد فأقبل على الناس فقال ما بال أحدكم يقوم مستقبل ربه فيتنخع أمامه أيحب أحدكم أن يستقبل فيتنخع في وجهه إذا تنخع أحدكم فليتنخع عن يساره أو تحت قدمه فإن لم يجد فليتفل هكذا في ثوبه فوصف القاسم فتفل في ثوبه ثم مسح بعضه ببعض
Its isnad is sahih. Qasim bin Mihran, the freed slave of Banu Qays bin Thalaba, is trustworthy, and Ibn Main and others rated him trustworthy. Bukhari wrote his biography in al-Kabir 1/166–167/4, and so did Ibn Abu Hatim 3/2/120, and he has no narration in the Six Books except this hadith. Abu Rafi is the goldsmith of Madinah, whose name was Nufay bin Rafi.This hadith will come again at 9355, from the narration of Shuba, from Qasim bin Mihran, with the same wording. Muslim 1/154 narrated it from Abu Bakr bin Abu Shayba and Zuhayr bin Harb, both from Ibn Ulaya, with this isnad. Ibn Majah 1022 likewise narrated it from Abu Bakr bin Abu Shayba, from Ibn Ulaya, and Muslim narrated it after that as well, through the route of Shuba too. See also 6306."Yatanakhkha" comes from "nukhaaa," with the noon vowelled with a damma. Ibn Athir said, it is the phlegm that comes out from the base of the mouth, from what is connected to the base of the spinal cord.