I agree with Matt - water gets down on to the contacts in the gas ignition switch when cleaning round the cooker. The switch pulls out with the plastic cover/seal. Turn off the cooker main switch first (should be the one on the wall), remove the switch, clean round the cover/seal to make sure there is no gunge round the metal of the hob or round the groove in the seal/cover, then replace it, and turn on the cooker main switch. If it still sparks it is still damp, and you don't have a hair dryer, but have an oven below, put that on to dry out the switch - it might take some time.
robert, December 2007