Jami` at-Tirmidhi #1043
The Book on Jana''iz (Funerals) 10:79
Abu Sa'eed Al-Khudri narrated that:
The Messenger of Allah said: "Whenever you see a funeral (procession), stand up (for it). Whoever follows it, then do not sit down until it is put down."