You have an accident on your carpet and want to get it up. I do not recommend using something you buy from the store. These products tend to leave a residue that will attract dirt. Also, if it does not remove the spot, it could actually set the stain so a professional cannot get it out. I recommend using white vinegar and water. Mix around 1/3 white vinegar to 2/3 water in a spritz bottle, then spritz the spot and blot it up with a white rag.
Here is a link to a video that will show this process. Spotcleaning video
For more information, visit my website at www.graysoncleans.com