Explanation
The sun eclipsed during the lifetime of the Prophet (may Allah’s peace and blessings be upon him). As that was something unfamiliar to the people, he led them in a prayer that was also unfamiliar in its appearance and its manner. The Prophet (may Allah's peace and blessings be upon him) stood for a long time, bowed for a long time, and then he raised his back up and his recitation was long, but not as long as his first recitation. Then he bowed again, but this time it was shorter than the first time and then he prostrated and prolonged the prostration. He repeated the same thing in the second Rak‘ah, even though it was a little shorter. Every pillar of the prayer was shorter than what preceded it, until he completed bowing four times and performed four prostrations in two Rak‘ahs. Then he finished the prayer, and by that time the sun had appeared again. He delivered a sermon to the people, as he usually would on special occasions. He started by praising Allah and glorifying Him. It happened that the day on which the eclipse occurred was the same day as his son Ibrahīm died. So some of the people said: “The sun eclipsed because Ibrahīm died”, as in the pre-Islamic era they had thought that the sun only eclipsed due to the death or birth of a great person. The Prophet (may Allah's peace and blessings be upon him) intended to remove such superstitions from their minds and benefit the people through his advice and sincerity in conveying his message, as those beliefs were not based upon authentic textual proofs or sound logic. He wanted to clarify the wisdom behind the eclipse of the sun and the moon, so he said during his sermon: “The sun and the moon are two of the signs of Allah; they do not eclipse on the death or life of anyone”, rather Allah, the Almighty, makes these things occur by His omnipotence to scare His Servants and remind them of His blessings. So if you see an eclipse, turn to Allah, the Almighty, in repentance, supplicate to Him, say Takbīr, pray, and give charity, as such acts can repel anticipated affliction and descending punishment. he then started to explain in detail some of the grave major sins, such as fornication, that cause corruption in society and morals, and necessitate the Wrath and punishment of Allah. He, swore in this sermon, and he is the truthful one, saying: “O followers of Muhammad, by Allah! No one gets more jealously protective than Allah when His male or female servant commits adultery.” The Prophet explained that they knew only a little about the punishment of Allah, and if they knew what he knew, they would be obsessed by fear, they would only laugh a little and cry a lot, and they would be filled with grief. However, Allah has concealed this from them, out of His wisdom.