The source of this information will always be the flight manual for the plane, as procedures will differ from type to type a little.
In very general: On the ground, for a piston engine carburettor fire, keep cranking to try to pull the fire through, then shut down for inspection and turn off the fuel. In flight, keep flying the plane and turn off the fuel, and electrical as appropriate.