Just tossing body parts into a rampless hole (preferably a fairly deep one) is a decent solution and easy to set up, but it should be a temporary one. Later, you should arrange a magma bath for the inhabitants of that pit, then let them path over a large number of traps to re-kill and incinerate them. Just magma won't kill undead, as heat kills by causing massive bleeding on all tissues but undead don't bleed to death, but flaming undead will usually become flaming corpses when re-killed, which quickly destroy themselves.
In the longer term, you should either dig a chute to the magma sea and dump refuse down it, or set up an atom smasher with a fairly fast repeat rate and throw refuse into it. Items are destroyed by either, so reanimatable body parts won't with such a setup.
Bones, that is not skeletal limbs or anything but items of the "bone" type, will not reanimate, so if you slaughter an animal, the only things that can reanimate from it are the skin and hair. Tan or dispose of these quickly (probably dispose, as it's faster) and you can keep the rest. Shells are more problematic, as fish shells will reanimate and are usually present in vast numbers if they are at all, so you're probably better off just letting any shell-requiring moody dwarves die.