پرش به محتوا

کتاب مقدس آنلاین: تفاوت میان نسخه‌ها

از دانشنامه کتاب مقدس
بدون خلاصۀ ویرایش
بدون خلاصۀ ویرایش
خط ۲۸۱: خط ۲۸۱:
                 padding: 8px 10px;
                 padding: 8px 10px;
             }
             }
           
             .app-header {
             .app-header {
                 margin-bottom: 15px;
                 margin-bottom: 15px;
                 padding: 12px 15px;
                 padding: 12px 15px;
             }
             }
           
             .breadcrumb {
             .breadcrumb {
                 font-size: 0.85rem;
                 font-size: 0.85rem;
                 margin-bottom: 10px;
                 margin-bottom: 10px;
             }
             }
           
             .app-header h1 {
             .app-header h1 {
                 font-size: 1.5rem;
                 font-size: 1.5rem;
                 margin-bottom: 6px;
                 margin-bottom: 6px;
             }
             }
           
             .description {
             .description {
                 font-size: 0.9rem;
                 font-size: 0.9rem;
             }
             }
           
             .selector-container {
             .selector-container {
                 grid-template-columns: 1fr;
                 grid-template-columns: 1fr;
خط ۳۰۷: خط ۳۰۲:
                 padding: 15px;
                 padding: 15px;
             }
             }
           
             .bible-content {
             .bible-content {
                 padding: 15px;
                 padding: 15px;
                 min-height: 450px;
                 min-height: 450px;
             }
             }
           
             .chapter-title {
             .chapter-title {
                 font-size: 1.3rem;
                 font-size: 1.3rem;
                 margin-bottom: 15px;
                 margin-bottom: 15px;
             }
             }
           
             .content-display {
             .content-display {
                 height: 500px;
                 height: 500px;
             }
             }
           
             .navigation {
             .navigation {
                 flex-direction: column;
                 flex-direction: column;
                 gap: 10px;
                 gap: 10px;
             }
             }
           
             .nav-btn, .wiki-link {
             .nav-btn, .wiki-link {
                 width: 100%;
                 width: 100%;
خط ۳۳۷: خط ۳۲۷:
                 height: 450px;
                 height: 450px;
             }
             }
           
             .nav-btn, .wiki-link {
             .nav-btn, .wiki-link {
                 padding: 10px 15px;
                 padding: 10px 15px;
                 font-size: 0.9rem;
                 font-size: 0.9rem;
             }
             }
           
             .instructions {
             .instructions {
                 padding: 30px 15px;
                 padding: 30px 15px;
                 font-size: 1rem;
                 font-size: 1rem;
             }
             }
           
             .app-header {
             .app-header {
                 padding: 10px 12px;
                 padding: 10px 12px;
             }
             }
           
             .app-header h1 {
             .app-header h1 {
                 font-size: 1.3rem;
                 font-size: 1.3rem;
خط ۳۹۷: خط ۳۸۳:


     <script>
     <script>
        // 🔒 سیستم حفاظتی - بررسی دامنه مجاز
         const ALLOWED_DOMAINS = [
         const ALLOWED_DOMAINS = [
             'pediabible.com',
             'pediabible.com',
خط ۴۰۷: خط ۳۹۲:
         function isDomainAllowed() {
         function isDomainAllowed() {
             const currentDomain = window.location.hostname;
             const currentDomain = window.location.hostname;
             if (!currentDomain || currentDomain === '' || currentDomain === 'null') {
             if (!currentDomain || currentDomain === '' || currentDomain === 'null') return true;
                return true;
            }
             return ALLOWED_DOMAINS.some(domain =>  
             return ALLOWED_DOMAINS.some(domain =>  
                 currentDomain === domain || currentDomain.endsWith('.' + domain)
                 currentDomain === domain || currentDomain.endsWith('.' + domain)
خط ۵۱۱: خط ۴۹۴:
                     if (!href) return;
                     if (!href) return;


                    // فقط لینک‌های داخلی به pediabible.com را هدف قرار بده
                     if (href.startsWith('/') || href.includes('pediabible.com')) {
                     if (href.startsWith('/') || href.includes('pediabible.com')) {
                         link.addEventListener('click', function(e) {
                         link.addEventListener('click', function(e) {
خط ۵۲۴: خط ۵۰۶:
                             let title = url.searchParams.get('title');
                             let title = url.searchParams.get('title');
                             if (!title) {
                             if (!title) {
                                // پشتیبانی از /index.php/عنوان
                                 const path = url.pathname;
                                 const path = url.pathname;
                                 if (path.includes('/index.php/')) {
                                 if (path.includes('/index.php/')) {
خط ۵۴۳: خط ۵۲۴:
                 });
                 });
             } catch (err) {
             } catch (err) {
                // اگر دسترسی نبود (مثلاً CORS)، خطا نده — فقط لاگ کن
                 console.debug('دسترسی به iframe محدود شد:', err.message);
                 console.debug('دسترسی به iframe محدود شد (غیرضروری):', err.message);
             }
             }
         }
         }
خط ۶۲۳: خط ۶۰۳:
                     name: 'ترجمه قدیم',
                     name: 'ترجمه قدیم',
                     baseUrl: 'https://www.pediabible.com/index.php?title=',
                     baseUrl: 'https://www.pediabible.com/index.php?title=',
                     getPageTitle: function(bookDisplayName, chapter) {
                     getPageTitle: (bookDisplayName, chapter) => `${bookDisplayName} فصل ${chapter}`
                        return `${bookDisplayName} فصل ${chapter}`;
                    }
                 },
                 },
                 'hejre_nou': {
                 'hejre_nou': {
                     name: 'هزاره نو',
                     name: 'هزاره نو',
                     baseUrl: 'https://www.pediabible.com/index.php?title=',
                     baseUrl: 'https://www.pediabible.com/index.php?title=',
                     getPageTitle: function(bookDisplayName, chapter) {
                     getPageTitle: (bookDisplayName, chapter) => `${bookDisplayName} هزاره نو فصل ${chapter}`
                        return `${bookDisplayName} هزاره نو فصل ${chapter}`;
                    }
                 },
                 },
                 'mozde': {
                 'mozde': {
                     name: 'مژده',
                     name: 'مژده',
                     baseUrl: 'https://www.pediabible.com/index.php?title=',
                     baseUrl: 'https://www.pediabible.com/index.php?title=',
                     getPageTitle: function(bookDisplayName, chapter) {
                     getPageTitle: (bookDisplayName, chapter) => `${bookDisplayName} مژده فصل ${chapter}`
                        return `${bookDisplayName} مژده فصل ${chapter}`;
                    }
                 },
                 },
                 'daneshname': {
                 'daneshname': {
                     name: 'دانشنامه',  
                     name: 'دانشنامه',  
                     baseUrl: 'https://www.pediabible.com/index.php?title=',
                     baseUrl: 'https://www.pediabible.com/index.php?title=',
                     getPageTitle: function(bookDisplayName, chapter) {
                     getPageTitle: (bookDisplayName, chapter) => `${bookDisplayName} دانشنامه فصل ${chapter}`
                        return `${bookDisplayName} دانشنامه فصل ${chapter}`;
                    }
                 }
                 }
             };
             };
خط ۶۹۷: خط ۶۶۹:
             }
             }


            // ✅ نمایش فصل با iframe + فعال‌سازی لینک‌های هوشمند
             function displayChapterWithIframe() {
             function displayChapterWithIframe() {
                 const bookIndex = parseInt(currentBook);
                 const bookIndex = parseInt(currentBook);
خط ۷۲۵: خط ۶۹۶:
                 updateNavigationButtons();
                 updateNavigationButtons();


                // ✅ فعال‌سازی لینک‌های داخلی بعد از بارگذاری iframe
                 const iframe = document.getElementById('content-iframe');
                 const iframe = document.getElementById('content-iframe');
                 iframe.onload = function() {
                 iframe.onload = function() {
خط ۷۳۲: خط ۷۰۲:
             }
             }


            // ✅ اصلاح: در اینجا باید resetAll() فراخوانی شود
             translationSelect.addEventListener('change', function() {
             translationSelect.addEventListener('change', function() {
                 currentTranslation = this.value;
                 currentTranslation = this.value;
خط ۷۳۷: خط ۷۰۸:
                     testamentSelect.disabled = false;
                     testamentSelect.disabled = false;
                     testamentSelect.value = '';
                     testamentSelect.value = '';
                     resetAll();
                     bookSelect.disabled = true;
                    bookSelect.innerHTML = '<option value="">انتخاب کتاب</option>';
                    chapterSelect.disabled = true;
                    chapterSelect.innerHTML = '<option value="">انتخاب فصل</option>';
                    resetContent();
                 } else {
                 } else {
                     resetAll();
                     resetAll();
خط ۸۱۱: خط ۷۸۶:
                 }
                 }
             });
             });
            console.log('✅ برنامه کتاب مقدس روی دامنه مجاز بارگذاری شد');
         }
         }


خط ۸۲۳: خط ۷۹۶:
         }
         }


         document.addEventListener('DOMContentLoaded', function() {
         document.addEventListener('DOMContentLoaded', loadApplication);
            loadApplication();
        });


         Object.defineProperty(window, 'translations', {
         Object.defineProperty(window, 'translations', { value: null, writable: false, configurable: false });
            value: null,
            writable: false,
            configurable: false
        });
     </script>
     </script>
</body>
</body>
</html>
</html>

نسخهٔ ‏۹ اکتبر ۲۰۲۵، ساعت ۱۷:۳۸

کتاب مقدس - مطالعه آنلاین

کتاب مقدس

مطالعه کتاب مقدس با ترجمه‌های مختلف