getSectionTitle()

Application Version - OJS 3.1.2
Hi i want to use getSectionTitle() function in article.tpl to show current article section Title and i getting Null,
{$article->getSectionTitle()}
its wierd because when i use {$article->getSectionId()} i getting id.
Can someone tell me what i miss in panel or what can i do to show title of section?

Hi @Kossal,

Weird, it should work. Can you confirm that the section title is in the section_settings table?

sure Zrzut ekranu z 2020-08-27 12-24-22 Zrzut ekranu z 2020-08-27 12-24-11 Zrzut ekranu z 2020-08-27 12-19-55

Can’t reproduce it with the version specified. Annotation of the article.tpl says that it’s an Article object, so the method should work. It’s hard to say what’s happening here. It’s localized setting, I would check just in case if the section title is present for the locale you are working with. E.g., if the section id is 1 and locale is English you can find the section in the database with:

SELECT setting_value FROM section_settings WHERE section_id = '1' AND locale = 'en_US' AND setting_name = 'title'

If it return setting_value, I’m not sure where to find the cause without some debugging.