Detonation is when the fuel/air mixture burns all at once in the cylinder as opposed to slowly starting from the spark plug. It can occur when the engine is running too hot, when running low octane fuel, or when running too high a manifold pressure for the RPM. The symptom are engine roughness, vibration, or loss of power.
Pre-ingnition is when the fuel/air mixture is igniting before the spark plug sparks. This usually happens when small accumulations of lead or carbon build up on the piston head, or commonly, on the spark plug. These accumulations heat up and ignite the fuel/air mixture out of sequence, usually during the compression stroke. The symptoms are lack of power and engine roughness.