All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger.
According to the agreement of the jurists the Friday prayer is an individual obligation upon every man who is free, able to go to perform it, and free from every other excuse. The same thing is applicable to the congregational (five daily) prayers, according to the preponderant view of the scholars . So, it is not permitted to miss any of these prayers without a sound excuse.
After discussing the matter with professional doctors, we came to the conclusion that the excuses mentioned in the question are not among those which make missing either the Friday or daily congregational prayers permissible, since the harm caused by such diseases is not that serious.
Imaam An-Nawawi said: "Our companions (scholars from the Shaafi'i school) said that the disease which lifts the obligation of performing the Friday prayer is that which makes that obligation considerably and unbearably hard to do."
Some scholars made the severity of leprosy and its being harmful to others a condition for being exempt from performing those obligations.
Minah Al-Jaleel (which is one of the books of the Maaliki School) reads: "The high degree of leprosy is an excuse, while simple cases are not." Besides, At-Tawdheeh (a book of the same School) reads: "Leprosy is a controversial issue. Sahnoon said that 'it is an excuse' while Ibn Habeeb said 'it is not', for the difference between the leprosy that causes bad smell and that which does not."
There is no doubt that leprosy is more serious than the diseases mentioned in the question or any other serious diseases. Therefore, they should not be taken as excuses for not performing the Friday prayer and other obligatory prayers in congregation.
Finally, we would like to advise our fellow Muslims to turn off their mobiles whenever they enter the mosque so as not to disturb the concentration of others during their prayers or when they recite the Quran.
Allaah Knows best.