Sahih Bukhari | Volume 1 | Hadith Number 403

Narrated by Abd Huraira and Abu Sa'id
Allah's Apostle saw some expectoration on the wall of the mosque; he took gravel and scraped it off and said, "If anyone of you wanted to spit, he should neither spit in front of him nor on his right but could spit either on his left or under his left foot."