Before offering prayers and other particular acts of worship, one must be in a state of ritual purity. It is necessary therein to wash the parts of the body that are generally exposed to dirt or other impurities. This cleansing is called Wudhoo’ (Ablution) and is performed as follows:
1. Have the intention that the act is for the purpose of worship and purification. Then, begin by saying ‘Bismillaah’ (ie, ‘I begin in the Name of Allah’).
2. Wash your hands up to the wrists, three times starting with the right hand.
3. Rinse your mouth with water, three times.
4. At the same time, cleanse your nostrils by sniffing water and expelling it, three times.
5. Wash your whole face three times with both hands, if possible, from the top of the forehead to the bottom of the chin and from ear to ear.
6. Wash your right arm three times up to the far end of the elbow, and then do the same with the left arm.
7. Wipe the whole head, or any part of it, with a wet hand from the front to the back, once.
8. Wipe the inner sides of your ears with the forefingers and their outer sides with the thumbs. This should be done with wet fingers once.
9. Wash your two feet up to the ankles, three times, beginning with the right foot.
The following acts render ablution null and void:

Natural Bodily Discharges
These include urine, stools, gas from behind, etc. Concerning the cases which necessitate ablution, Allaah Almighty Says (what means): “… or (if) one of you comes from the place of relieving himself…” [Qur’an 5:6] This proves that such an act obligates new purification.
Abu Hurayrah  who was one of the outstanding Companions, reported that the Messenger of Allaah  said: “Allaah does not accept the prayer of a person who has released gas until he performs a new ablution.” A person from Hadhramawt (in Yemen) asked Abu Hurayrah : “What does releasing gas mean?” He answered: “Passing wind, with or without sound.” [Al-Bukhari & Muslim]
He also narrated that the Prophet sallallaahu ‘alaihi wa sallam said: “If one of you finds a disturbance in his abdomen and is not certain if he released any gas or not, he should not leave the mosque (i.e., quit his prayer) unless he hears its sound or smells its odour.” [Muslim]
Hearing the escaping gas or smelling it is not the condition that nullifies the ablution, but the certainty that passing gas has occurred. As for a discharge of Al-Mathi (prostatic fluid), the Prophet sallallaahu ‘alaihi wa sallam said: “Perform ablution.” Concerning Al-Mani (sperm), Ibn ‘Abbaas who was another outstanding Companion, said: “It requires Ghusl (ritual bathing) and for Al-Mathi and Al-Wadi (which is secreted from the sexual organ due to sickness or fatigue), wash your sexual organs and perform ablution.” [Al-Bayhaqi]

Deep Sleep that Makes a Person Completely Unaware of his Surroundings
If the person did not keep his buttocks firmly seated on the floor while sleeping, he must make a new ablution.  Safwaan Ibn ‘Asal  said: “The Prophet sallallaahu ‘alaihi wa sallam used to order us while we were travelling not to take our socks off unless we were in post-sex impurity (i.e. not for defecation, urination or sleep).”
If one’s buttocks remained firmly on the floor during his sleep, no new ablution is necessary. This is implied by the narration of Anas who said: “The companions of the Prophet sallallaahu ‘alaihi wa sallam were waiting for the delayed ‘Ishaa’ prayer until their heads began nodding up and down (from drowsiness and sleep). They would then pray without performing ablution.” [Muslim, Ash-Shafi’ee, Abu Daawood & At-Tirmithi]
The wording that At-Tirmithi recorded from the chain of Shu’bah is: “I have seen the companions of the Prophet sallallaahu ‘alaihi wa sallam sleeping to the extent that one could hear some of them snoring, but, they would stand for prayer without a new ablution.” Imaam Ibn Al-Mubaarak  said: “In our view, this happened when they were sitting.”

Loss of Consciousness
This nullifies the ablution, regardless of whether it was due to insanity, fainting, drunkenness, or medication. It also does not matter if one was unconscious for a short or long period of time, or if one was sitting, or fell to the ground, and so on. The aspect of unawareness here is greater than that of sleeping.  The scholars all agree on this point.

Touching the Sexual Organ without Any ‘Barrier’ (clothing, and so on) between the Hand and the Organ
Busrah Ibnt Safwaan (a female companion) narrated that the Prophet sallallaahu ‘alaihi wa sallam said: “Whoever touches his sexual organ cannot pray until he performs ablution.” [Maalik, Ash-Shafi’ee, Ahmad & Others]
Imaam Abu Daawood  said: “I asked Ahmad : ‘Is the Hadith (prophetic narration) of Busrah authentic?’ He replied: ‘Certainly it is authentic.’” In the narration of Imaams Ahmad and An-Nasaa’i  Busrah heard the Prophet saying: “Ablution is to be made by the one who touches his sexual organ.”  
This is general and encompasses touching one’s own sexual organs or touching anyone else’s. Abu Hurairah  reported the Prophet as saying: “Whoever touches his sexual organ without any covering (over it) must perform ablution.” [Ahmad, Ibn Hibbaan & Al-Haakim]
Imaam Ibn As-Sakan  who was a Hadeeth scholar, said: “This Hadith is from the best of what has been related on this topic,” Imaam Ash-Shaafi’ee  related: “Any man who touches his penis must perform ablution. Any woman who touches her vagina must perform ablution.”  
The scholars of the Hanafi school are of the opinion, based on the following Hadith, that touching the sexual organ does not nullify the ablution: “A man asked the Prophet sallallaahu ‘alaihi wa sallam if a man who touches his penis has to perform ablution. The Prophet sallallaahu ‘alaihi wa sallam replied: “No, it is just a part of you.”
In addition to this issue (touching the sexual organ), there are other issues that are also controversial in this regard among Muslim scholars, such as excretion of pus or blood, vomiting and eating camel meat.
Article source: http://www.islamweb.net/emainpage/