Sahih Bukhari | Volume 1 | Hadith Number 720
Narrated by Ibn 'Umar
The Prophet saw expectoration in the direction of the Qibla of the mosque while he was leading the prayer, and scratched it off. After finishing the prayer, he said, "Whenever any of you is in prayer he should know that Allah is in front of him. So none should spit in front of him in the prayer."