کتاب مقدس آنلاین: تفاوت میان نسخهها
ظاهر
بدون خلاصۀ ویرایش |
بدون خلاصۀ ویرایش |
||
| (۲۶ نسخهٔ میانیِ ایجادشده توسط همین کاربر نشان داده نشد) | |||
| خط ۳۰: | خط ۳۰: | ||
padding: 0; | padding: 0; | ||
margin: 0; | margin: 0; | ||
} | |||
/* مخفی کردن هدرهای اضافی ویکی */ | |||
body > header:first-child, | |||
.wiki-header, | |||
.mw-header, | |||
#mw-header, | |||
#header, | |||
.header { | |||
display: none !important; | |||
} | } | ||
| خط ۵۵: | خط ۶۵: | ||
gap: 8px; | gap: 8px; | ||
margin-bottom: 12px; | margin-bottom: 12px; | ||
font-size: | font-size: 1.1rem; | ||
color: var(--dark-color); | color: var(--dark-color); | ||
direction: rtl; | direction: rtl; | ||
| خط ۹۲: | خط ۱۰۲: | ||
.description { | .description { | ||
color: | color:#808080; | ||
font-size: 1rem; | font-size:1rem; | ||
font-style: italic; | font-style: italic; | ||
margin-top: 5px; | margin-top: 5px; | ||
| خط ۱۷۳: | خط ۱۸۳: | ||
.content-display { | .content-display { | ||
width: 100%; | width: 100%; | ||
height: 650px; | |||
border: 1px solid var(--border-color); | border: 1px solid var(--border-color); | ||
border-radius: 6px; | border-radius: 6px; | ||
background: white; | background: white; | ||
} | } | ||
| خط ۲۶۷: | خط ۲۳۴: | ||
gap: 8px; | gap: 8px; | ||
padding: 12px 20px; | padding: 12px 20px; | ||
background-color: | background-color: #87CEEB; | ||
color: | color: #000000; | ||
text-decoration: none; | text-decoration: none; | ||
border-radius: 6px; | border-radius: 6px; | ||
| خط ۳۰۸: | خط ۲۷۵: | ||
margin-bottom: 15px; | margin-bottom: 15px; | ||
font-size: 1.5rem; | font-size: 1.5rem; | ||
} | |||
.info-message { | |||
text-align: center; | |||
padding: 10px; | |||
background: #e7f3ff; | |||
border-radius: 5px; | |||
margin-top: 10px; | |||
font-size: 0.9rem; | |||
color: #0066cc; | |||
} | } | ||
| خط ۳۵۳: | خط ۳۳۰: | ||
.content-display { | .content-display { | ||
height: 500px; | |||
} | } | ||
| خط ۳۷۱: | خط ۳۴۶: | ||
@media (max-width: 480px) { | @media (max-width: 480px) { | ||
.content-display { | .content-display { | ||
height: 450px; | |||
} | } | ||
| خط ۴۲۶: | خط ۴۰۰: | ||
<span class="breadcrumb-current">کتاب مقدس</span> | <span class="breadcrumb-current">کتاب مقدس</span> | ||
</nav> | </nav> | ||
<h1>کتاب مقدس</h1> | <h1>کتاب مقدس آنلاین</h1> | ||
<p class="description">مطالعه | <p class="description">مطالعه ترجمههای مختلف بصورت کاربردی با واژه نامه تخصصی<br> | ||
ترجمهٔ هزارهٔ نو و مژده هماکنون قابل مطالعهاند و عهد جدید کامل شده است. واژهنامهها بهصورت روزانه و با دقت در حال اتصال و بهروزرسانی هستند تا خدمتی ماندگار برای نسل حال و آیندگان در خداوند بهجا بگذاریم.</p> | |||
</div> | </div> | ||
| خط ۴۴۷: | خط ۴۲۲: | ||
function isDomainAllowed() { | function isDomainAllowed() { | ||
const currentDomain = window.location.hostname; | const currentDomain = window.location.hostname; | ||
console.log('🔍 بررسی دامنه:', currentDomain); | |||
// اگر روی فایل محلی هستیم، اجازه بده | |||
if (!currentDomain || currentDomain === '' || currentDomain === 'null') { | if (!currentDomain || currentDomain === '' || currentDomain === 'null') { | ||
console.log('✅ فایل محلی - مجاز'); | |||
return true; | return true; | ||
} | } | ||
const isAllowed = ALLOWED_DOMAINS.some(domain => { | |||
const match = currentDomain === domain || currentDomain.endsWith('.' + domain); | |||
if (match) { | |||
console.log(`✅ دامنه ${currentDomain} مجاز است`); | |||
} | |||
return match; | |||
}); | }); | ||
if (!isAllowed) { | |||
console.log(`❌ دامنه ${currentDomain} غیرمجاز است`); | |||
} | |||
return isAllowed; | |||
} | } | ||
| خط ۴۶۸: | خط ۴۵۶: | ||
</div> | </div> | ||
`; | `; | ||
} | |||
// تابع اصلی بارگذاری برنامه | |||
function loadApplication() { | |||
console.log('🚀 شروع بارگذاری با بررسی امنیتی...'); | |||
if (!isDomainAllowed()) { | |||
console.log('❌ دسترسی غیرمجاز - نمایش پیام خطا'); | |||
showAccessDenied(); | |||
return; | |||
} | |||
console.log('✅ دامنه مجاز - بارگذاری برنامه اصلی'); | |||
// اگر دامنه مجاز باشد، برنامه اصلی بارگذاری میشود | |||
initializeBibleApp(); | |||
} | } | ||
| خط ۵۱۸: | خط ۵۲۱: | ||
{ name: "لوقا", chapters: 24, displayName: "انجیل به قلم لوقا" }, | { name: "لوقا", chapters: 24, displayName: "انجیل به قلم لوقا" }, | ||
{ name: "یوحنا", chapters: 21, displayName: "انجیل به قلم یوحنا" }, | { name: "یوحنا", chapters: 21, displayName: "انجیل به قلم یوحنا" }, | ||
{ name: "اعمال", chapters: 28, displayName: "اعمال" }, | { name: "اعمال ", chapters: 28, displayName: "اعمال " }, | ||
{ name: "رومیان", chapters: 16, displayName: "رساله به رومیان" }, | { name: "رومیان", chapters: 16, displayName: "رساله به رومیان" }, | ||
{ name: "اول قرنتیان", chapters: 16, displayName: "رساله اول به قرنتیان" }, | { name: "اول قرنتیان", chapters: 16, displayName: "رساله اول به قرنتیان" }, | ||
| خط ۵۴۰: | خط ۵۴۳: | ||
{ name: "سوم یوحنا", chapters: 1, displayName: "رساله سوم یوحنا" }, | { name: "سوم یوحنا", chapters: 1, displayName: "رساله سوم یوحنا" }, | ||
{ name: "یهودا", chapters: 1, displayName: "رساله یهودا" }, | { name: "یهودا", chapters: 1, displayName: "رساله یهودا" }, | ||
{ name: "کتاب مکاشفه", chapters: 22, displayName: "کتاب مکاشفه" } | { name: "کتاب مکاشفه", chapters: 22, displayName: "کتاب مکاشفه " } | ||
] | ] | ||
}; | }; | ||
| خط ۵۹۶: | خط ۵۹۹: | ||
</div> | </div> | ||
</div> | </div> | ||
</div> | |||
<div class="info-message"> | |||
<i class="fas fa-info-circle"></i> | |||
واژه ها در همین پنجره نمایش داده میشوند. برای تجربه بهتر مطالعه واژه در تب جدید: راست کلیک → Open in new tab | |||
</div> | </div> | ||
| خط ۷۴۳: | خط ۷۵۱: | ||
if (currentChapter) { | if (currentChapter) { | ||
displayChapterWithIframe(); | |||
} else { | } else { | ||
resetContent(); | resetContent(); | ||
| خط ۷۴۹: | خط ۷۵۷: | ||
}); | }); | ||
// نمایش فصل با | // نمایش فصل با iframe - فقط محتوای اصلی | ||
function displayChapterWithIframe() { | |||
const bookIndex = parseInt(currentBook); | const bookIndex = parseInt(currentBook); | ||
const bookData = bibleBooks[currentTestament][bookIndex]; | const bookData = bibleBooks[currentTestament][bookIndex]; | ||
| خط ۷۵۹: | خط ۷۶۷: | ||
chapterTitle.textContent = `${translationName} - ${bookName} - فصل ${currentChapter}`; | chapterTitle.textContent = `${translationName} - ${bookName} - فصل ${currentChapter}`; | ||
const pageTitle = translations[currentTranslation].getPageTitle(bookDisplayName, currentChapter); | |||
const contentUrl = `${translations[currentTranslation].baseUrl}${encodeURIComponent(pageTitle)}&action=render`; | |||
versesContainer.innerHTML = ` | versesContainer.innerHTML = ` | ||
< | <iframe | ||
id="content-iframe" | |||
src="${contentUrl}" | |||
</ | class="content-display" | ||
frameborder="0" | |||
loading="lazy" | |||
sandbox="allow-scripts allow-same-origin allow-forms allow-popups" | |||
allowfullscreen> | |||
</iframe> | |||
`; | `; | ||
// | // اضافه کردن sandbox به iframe برای امنیت بیشتر | ||
const iframe = document.getElementById('content-iframe'); | |||
wikiPageLink.href = `${translations[currentTranslation].baseUrl}${encodeURIComponent(pageTitle)}`; | wikiPageLink.href = `${translations[currentTranslation].baseUrl}${encodeURIComponent(pageTitle)}`; | ||
wikiPageLink.style.display = 'flex'; | wikiPageLink.style.display = 'flex'; | ||
updateNavigationButtons(); | updateNavigationButtons(); | ||
} | } | ||
| خط ۹۱۲: | خط ۸۰۲: | ||
currentChapter--; | currentChapter--; | ||
chapterSelect.value = currentChapter; | chapterSelect.value = currentChapter; | ||
displayChapterWithIframe(); | |||
} | } | ||
}); | }); | ||
| خط ۹۲۳: | خط ۸۱۳: | ||
currentChapter++; | currentChapter++; | ||
chapterSelect.value = currentChapter; | chapterSelect.value = currentChapter; | ||
displayChapterWithIframe(); | |||
} | } | ||
}); | }); | ||
| خط ۹۴۴: | خط ۸۳۴: | ||
function resetAll() { | function resetAll() { | ||
testamentSelect.disabled = true; | testamentSelect.disabled = true; | ||
testamentSelect.value = | testamentSelect.innerHTML = '<option value="">انتخاب عهد</option>'; | ||
bookSelect.disabled = true; | bookSelect.disabled = true; | ||
bookSelect.innerHTML = '<option value="">انتخاب کتاب</option>'; | bookSelect.innerHTML = '<option value="">انتخاب کتاب</option>'; | ||
| خط ۹۵۱: | خط ۸۴۱: | ||
resetContent(); | resetContent(); | ||
} | } | ||
console.log('✅ برنامه کتاب مقدس روی دامنه مجاز بارگذاری شد'); | |||
} | } | ||
// شروع برنامه | // 🔒 شروع برنامه با بررسی امنیتی | ||
document.addEventListener('DOMContentLoaded', function() { | document.addEventListener('DOMContentLoaded', function() { | ||
console.log('🚀 شروع بارگذاری با بررسی امنیتی...'); | |||
loadApplication(); | |||
}); | |||
// 🔒 جلوگیری از دسترسی به توابع از کنسول | |||
Object.defineProperty(window, 'translations', { | |||
value: null, | |||
writable: false, | |||
configurable: false | |||
}); | }); | ||
</script> | </script> | ||
</body> | </body> | ||
</html> | </html> | ||
نسخهٔ کنونی تا ۱۱ اکتبر ۲۰۲۵، ساعت ۲۲:۰۹
کتاب مقدس آنلاین
مطالعه ترجمههای مختلف بصورت کاربردی با واژه نامه تخصصی
ترجمهٔ هزارهٔ نو و مژده هماکنون قابل مطالعهاند و عهد جدید کامل شده است. واژهنامهها بهصورت روزانه و با دقت در حال اتصال و بهروزرسانی هستند تا خدمتی ماندگار برای نسل حال و آیندگان در خداوند بهجا بگذاریم.