کتاب مقدس آنلاین: تفاوت میان نسخهها
ظاهر
بدون خلاصۀ ویرایش |
بدون خلاصۀ ویرایش |
||
خط ۵۳۷: | خط ۵۳۷: | ||
'old': { | 'old': { | ||
name: 'ترجمه قدیم', | name: 'ترجمه قدیم', | ||
baseUrl: 'https://www.pediabible.com/index.php?title=' | baseUrl: 'https://www.pediabible.com/index.php?title=', | ||
// برای ترجمه قدیم از الگوی ساده استفاده میکنیم | |||
getPageTitle: function(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) { | |||
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) { | |||
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) { | |||
return `${bookDisplayName} دانشنامه فصل ${chapter}`; | |||
} | |||
} | } | ||
}; | }; | ||
خط ۶۶۳: | خط ۶۷۷: | ||
chapterTitle.textContent = `${translationName} - ${bookName} - فصل ${currentChapter}`; | chapterTitle.textContent = `${translationName} - ${bookName} - فصل ${currentChapter}`; | ||
const pageTitle = | // استفاده از الگوی مناسب برای هر ترجمه | ||
const pageTitle = translations[currentTranslation].getPageTitle(bookDisplayName, currentChapter); | |||
// استفاده از action=render برای نمایش فقط محتوای اصلی | // استفاده از action=render برای نمایش فقط محتوای اصلی | ||
const contentUrl = `${translations[currentTranslation].baseUrl}${encodeURIComponent(pageTitle)}&action=render`; | const contentUrl = `${translations[currentTranslation].baseUrl}${encodeURIComponent(pageTitle)}&action=render`; |
نسخهٔ ۸ اکتبر ۲۰۲۵، ساعت ۰۴:۵۲
کتاب مقدس - مطالعه آنلاین
مطالعه کتاب مقدس با ترجمههای مختلف