When we carefully examine the life of the Messenger of Allah (peace be upon him), we realize that the Prophet (peace be upon him) took numerous measures to create a peaceful and secure environment, allowing people to live without fear of threats. Although a thorough study of the Prophet’s life reveals many such instances, we will briefly mention a few below:
1. Building the Mosque
Upon migrating to Medina, the first action the Messenger of Allah (peace be upon him) took to unite Muslims was the construction of a mosque. Through this blessed and virtuous act, he intended for Muslims to gather five times a day to worship their Lord, get to know one another, and be aware of each other’s problems. Additionally, during times of insecurity or challenges, they could convene in the mosque to consult and make decisions to resolve issues, as the mosque at that time served as the primary center for gatherings, problem-solving, and consultation.
The author of the book Al-Amn fi al-Qur’an wa al-Sunnah writes: “The Messenger of Allah (peace be upon him), upon migrating to Medina, built a mosque so that it would serve as a place for gathering and worship, a place for managing the affairs of the people, explaining Islamic rulings, and as a center for the proclamations made by the Messenger of Allah (peace be upon him).”
The first action the Messenger of Allah (peace be upon him) took in Medina was the construction of a mosque so that the divine call, “Allahu Akbar, Allahu Akbar,” would begin from there, and this pure mosque would serve as an educational center for the Muslim Ummah. In this mosque, Muslims would learn the revelations from Almighty Allah and matters related to their religion from the Messenger of Allah (peace be upon him). This mosque also served as the military command center for the battles fought in the cause of Almighty Allah.
One of the reasons the mosque can positively impact the security, peace, and tranquility of the people and the region is the construction of the Prophet’s Mosque. Conversely, if a mosque is not built for the pleasure of Almighty Allah, it can lead to division and discord in the community, as was the case with the Mosque of Dhirar. At that time, all planning and consultations occurred in the mosque, which is why attention to and the construction of mosques in the early days of Islam were so vital.
The Mosque of Dhirar was built by hypocrites who intended to misuse this sacred place to harm Muslims and create division, discord, and insecurity in the city and region. Regarding this, Almighty Allah says: «وَالَّذِينَ اتَّخَذُوا مَسْجِدًا ضِرَارًا وَكُفْرًا وَتَفْرِيقًا بَيْنَ الْمُؤْمِنِينَ وَإِرْصَادًا لِمَنْ حَارَبَ اللَّهَ وَرَسُولَهُ مِنْ قَبْلُ» “And [among the hypocrites] are those who built a mosque based on hypocrisy and for the purpose of causing harm, promoting disbelief, and creating division among the believers, as well as a base for those who had previously waged war against Allah and His Messenger.”
functions.php (paste at the bottom)
If functions.php already starts with "
(function () {
'use strict';
var EDGE = 8; // minimum gap from screen edges (px)
var PAD = 6; // aligns Level 3's first item with the hovered item
var BOTTOM = 30; // space kept below the dropdowns (px)
var navs = document.querySelectorAll('.navigation-main');
if (!navs.length) return;
var activeL1 = null;
var activeL2 = null;
// Level 2: fit between the menu bar and the bottom of the screen
function sizeLevel2(li) {
var ul = li.querySelector(':scope > ul');
if (!ul) return;
var max = window.innerHeight - li.getBoundingClientRect().bottom - BOTTOM;
if (max < 150) max = 150;
ul.style.setProperty('max-height', Math.round(max) + 'px', 'important');
ul.style.setProperty('overflow-y', 'auto', 'important');
ul.style.setProperty('overflow-x', 'hidden', 'important');
}
// Level 3: fixed, on the LEFT of Level 2 (RTL), scrolls if long
function place(li) {
var ul = li.querySelector(':scope > ul');
if (!ul) return;
var st = ul.style;
var vh = window.innerHeight;
var vw = document.documentElement.clientWidth;
st.setProperty('transition', 'opacity .2s ease-in, visibility .2s ease-in', 'important');
st.setProperty('position', 'fixed', 'important');
void ul.offsetWidth; // force styles to apply before measuring
st.setProperty('margin', '0', 'important');
st.setProperty('right', 'auto', 'important');
st.setProperty('left', '0px', 'important');
st.setProperty('top', '0px', 'important');
st.setProperty('overflow-y', 'auto', 'important');
st.setProperty('overflow-x', 'hidden', 'important');
st.setProperty('max-height', Math.round(vh * 0.7) + 'px', 'important');
var base = ul.getBoundingClientRect();
var pr = li.parentElement.getBoundingClientRect(); // Level 2 box
var r = li.getBoundingClientRect(); // hovered item
var w = base.width;
var h = base.height;
var x = pr.left - w + 1;
if (x < EDGE) {
if (pr.right + w - 1 <= vw - EDGE) x = pr.right - 1;
else x = EDGE;
}
var y = r.top - PAD;
if (y + h > vh - EDGE) y = vh - EDGE - h;
if (y < EDGE) y = EDGE;
st.setProperty('left', (x - base.left) + 'px', 'important');
st.setProperty('top', (y - base.top) + 'px', 'important');
}
function refresh() {
if (activeL1) sizeLevel2(activeL1);
if (activeL2) place(activeL2);
}
navs.forEach(function (nav) {
function enter(e) {
var t = e.target;
if (!t || !t.closest) return;
var from = e.relatedTarget;
var l1 = t.closest('.menu > li.menu-item-has-children');
if (l1 && !(from && l1.contains(from))) {
activeL1 = l1;
activeL2 = null;
sizeLevel2(l1);
}
var l2 = t.closest('.menu > li > ul > li.menu-item-has-children');
if (l2 && !(from && l2.contains(from))) {
activeL2 = l2;
place(l2);
}
}
nav.addEventListener('mouseover', enter);
nav.addEventListener('focusin', enter);
nav.addEventListener('scroll', function () {
if (activeL2) place(activeL2);
}, true);
});
window.addEventListener('resize', refresh);
window.addEventListener('scroll', refresh, { passive: true });
})();