Never approach a victim of electric shock if there is any risk of being shocked yourself. If he is still touching the electric source, cut off the power - if this is a low-voltage source, such as the frayed lead of an iron or electric fire, switch it off at the plug; otherwise, switch off at the mains.
If the person is still holding or touching the source, get a broom handle or other long length of dry wood, stand on a dry rubber mat or pile of newspapers and use the wood to move him away from the source.
Once he is out of harm's way, douse burning clothes with a towel, blanket or fire blanket. If he is unconscious on the ground, check his breathing. If this has stopped, apply artificial respiration and, if necessary and you know how, chest compression. When he starts breathing, lay him in the recovery position.
Check the casualty for burns. Treat these with cold water and cover them with sterile dressings. Call an ambulance.