Problem of cell phones ringing in the mosque
Question

                Cell phone while they are good but when people bring them to the mosque and do not turn them off, start ringing during the prayers. It is very anoying and distracting. Please provide an Islamic ruling on this matter.
Praise be to Allah.Islam is keen 
    that the Muslim’s prayer should be perfect in terms of focus and humility, 
    far removed from anything that may distract a person from prayer. Among the 
    things to which Islam pays attention in this regard are the following: 
1 – It was 
    narrated that Anas ibn Maalik (may Allaah be pleased with him) said: “We 
    used to pray with the Prophet  (peace and blessings of Allaah be upon 
    him) when it was intensely hot. When one of us could not bear to press his 
    face to the ground (because of the heat), he would spread his garment and 
    prostrate on it.”
(Narrated by 
    al-Bukhaari, 1150; Muslim, 620). 
Al-Haafiz ibn 
    Hajar said: 
The apparent 
    meaning is that they did that in order to remove the distraction caused by 
    the ground being too hot. 
Fath 
    al-Baari, 1/493 
2 – It was narrated from 
    ‘Aa’ishah that the Prophet  (peace and blessings of Allaah be upon him) 
    prayed in a shirt on which there were designs, and when he finished praying 
    he said, “Take this shirt of mine to Abu Jahm and bring me the inbijaaniyyah 
    (a woollen garment that was plain, with no designs) of Abu Jahm, for it 
    distracted me from my prayer.” Haashim ibn ‘Urwah narrated from his father 
    from ‘Aa’ishah that the Prophet  (peace and blessings of Allaah be upon 
    him) said: “I used to look at its designs whilst I was praying and I was 
    afraid that it would distract me.” 
(Narrated by 
    al-Bukhaari, 366; Muslim, 556) 
3 – It was 
    narrated from ‘Aa’ishah that the Prophet  (peace and blessings of Allaah 
    be upon him) said: “If the iqaamah for ‘Isha’ prayer is given and dinner is 
    ready, then start with dinner.” 
(Narrated by 
    al-Bukhaari, 5148; Muslim, 558) 
al-Haafiz 
    said: 
al-Faakihaani said: This 
    should be interpreted in general terms, applicable to any situation where 
    there is a distraction that may lead to a person not being sufficiently 
    humble and focused (in prayer). 
Fath 
    al-Baari, 2/160 
4 – It was 
    narrated that Abu Saalih al-Sammaan said: I saw Abu Sa’eed al-Khudri on a 
    Friday, praying facing something that screened him from the people. A young 
    man from among Bani Abi Mu’eet wanted to pass in front of him, and Abu 
    Sa’eed pushed him in the chest. The young man looked and could not find any 
    way to pass except in front of him, so he tried again, and Abu Sa’eed pushed 
    him more strongly than the first time. The young man insulted Abu Sa’eed and 
    entered upon Marwaan, and complained to him about what Abu Sa’eed had done 
    to him. Abu Sa’eed came in behind him, and Marwaan said to him, “What is the 
    matter with you and your brother’s son, O Abu Sa’eed?” He said, “I heard the 
    Messenger of Allaah  (peace and blessings of Allaah be upon him) say, 
    ‘If any one of you is praying facing something that is screening him from 
    the people, and someone wants to pass in front of him, let him push him 
    back, and if he insists then let him fight him, for he is a devil.’”
(Narrated by 
    al-Bukhaari, 487; Muslim, 505) 
Al-Zarqaani 
    said: The phrase “for he is a devil” means that he is doing the actions of 
    the Shaytaan, because he is insisting on disturbing someone who is praying. 
(Sharh 
    al-Zarqaani, 1/442). 
5 – It was narrated that 
    Abu Sa’eed said: The Messenger of Allaah  (peace and blessings of Allaah 
    be upon him) went into i’tikaaf (retreat) in the mosque, and he heard them 
    reciting Qur’aan out loud. He drew back the curtain and said, “Each of you 
    is conversing privately with his Lord, so do not disturb one another or 
    raise your voices above one another when reading Qur’aan – or he said, when 
    praying.” 
(Narrated by 
    Abu Dawood, 1332) 
We should 
    note in this last hadeeth that the Messenger  (peace and blessings of 
    Allaah be upon him) forbade the people to distract one another from prayer 
    by their prayer or Qur’aan-reading. He forbade people to distract others 
    from prayer by their prayer or Qur’aan-reading. He did not like the prayer 
    or Qur’aan-reading of one person to distract another person from his prayer.
 In 
    conclusion: Islam encourages focus and humility in prayer, and encourages us 
    to persist in that. What we see of these mobile phones in the situation you 
    mention is something that causes people to lose the proper focus and 
    humility in prayer, because it is a disturbance that affects the spirit and 
    tranquility of prayer.
 We advise 
    our brothers who own these phones not to leave them switched on at the time 
    of prayer, rather they should turn off the ringer.