The chaps in the Electrical Engineering will know more about this than me, but a bridge rectifier is used. As you know, AC usually takes the form of a sine wave. The bridge rectifier uses the directional property of diodes to convert the troughs of the sine waves to peaks, so that the current is now only moving in one direction. A capacitor is then often used to 'smooth' the resulting waveform.
A mechanical analogy might be a network of check valves to make water always flow in a single direction, with a bucket (capacitor!) used to reduce the 'pulses' in flow.
Thanks brewnog the link is really helpful. I did think there has to be something with diods somwhere in ther but I never thought there are 2 peres of them. The othere plans on the link are also interesting. Thanks agein!!