On a daily basis, hundreds of people put the wrong fuel in their car. Many cars have a cap fitted inside the fuel tank opening that will not allow certain nozzles to be inserted (making it virtually impossible to fill up with the wrong fuel type) but others do not have this therefore making it very easy to accidentally put petrol in a diesel or diesel in a petrol car.
Doing this can cause great damage to the car and often it will need to be towed to a garage to repair it. If you realise that you have put the wrong fuel in your car as soon as you have done it, then do NOT start the engine. Often if the engine has not been started the fuel can be siphoned off and then the correct fuel added.
If you have only put a very small amount in before you have realised, some people say that you can then fill your tank up with the correct fuel and it will dilute it enough to not do any harm. This can be a risky option and I would recommend calling your Breakdown Company or local garage.