L.
This "recipe" comes from a carpet cleaning guy...I love it and use it on EVERYTHING!
3-4 Tbsp. white vinegar
1-2 drops dish washing liquid
Put in a 16 oz. spray bottle and fill the rest up with water
Spray on stain and dab with a clean white cloth or towel. Repeat until stain is gone. Sometimes you may need to saturate the spot and then apply pressure to "soak up" the stain (like stand on the cloth). The less rubbing the better, as rubbing wil breakdown the fibers of the carpet.
It has gotten out everything from my kids vomit (on my mother-in-laws NEW sofa!) to chocolate and blood on my white sofa. The key is to catch it right away, but I've used it after it's dried and it still works.
Spot Shot is also a great stain remover, especially for those old stains or ones that you have no idea what they are. We've used it to remove stains that were on the carpet when we moved into our house.