The answer to this is found in Chapter 9. In that chapter, the animals gather to, they think, say goodbye to Boxer because he is going to be going to the animal hospital. But we know that he is really going to be taken to the knackers.
The one who figures this out is the donkey, Benjamin. He points out to all the other animals what is written on the side of the van. He shows them that it actually says it belongs to a horse slaughterer.
The animals try to get Boxer to get out, but he is too weak to kick the van apart like he once could have.
In Ch.9 we read that Boxer has collapsed when he was carrying a load of stones for constructing the new windmill:
two pigeons came racing in with the news; "Boxer has fallen!
He is lying on his side and can't get up!"
Squealer is informed and after takng a quick look at the bleeding Boxer he announces that Napoleon had ordered that Boxer should be treated at the hospital at Willingdon. For the next two days Boxer remained in his stall. He was lovingly cared for by Benjamin the donkey. However, when Benjamin and others were at work a van came to take Boxer away but Benjamin had correctly identified that the van belonged to "'Alfred Simmonds, Horse Slaughterer and Glue Boiler, Willingdon. Dealer in Hides and Bone-Meal. Kennels Supplied.' " He knew that Boxer was being sent to his death and not the vet as Squealer had promised them.
All the animals led by Benjamin the donkiey tried to prevent Boxer from being taken to the "knacker's!" But it was of no use.