How to change the browser tabe title in OJS 3

how to change the browser tabe title to be the name of the website in OJS 3

Hi @Abd_El-Nasser_Gharee,

My Firefox browser takes the page title (the contents of the HTML <title> element) to be the title of the tab. I presume yours behaves the same way.

If you want to change the HTML <title> element in order to fix it to a certain value, you’ll need to edit the template files. I’d suggest searching the template files – particularly everything in templates/frontend – for <title>.

Regards,
Alec Smecher
Public Knowledge Project Team

Dear @asmecher

I am not expert in php and searched for the file that need modification but failed. I wish you specify the files that I must modify it and what will the modification be?

Regards

Hi @Abd_El-Nasser_Gharee,

To modify the <title> tag on the reader frontend, you would edit this file:

To modify the <title> tag in the editorial backend, you would edit this file:

https://github.com/pkp/pkp-lib/blob/master/templates/common/headerHead.tpl#L13

1 Like

Dear @asmecher

Now I know the target files but I don’t know which sentence I should correct and what I should write?!!

Hi @Abd_El-Nasser_Gharee,

Whatever you put between <title> and </title> will appear as the title of the tab. The current {$pageTitleTranslated|strip_tags} is Smarty code.

Regards,
Alec Smecher
Public Knowledge Project Team

1 Like

I modified the mentioned file…The problem now that this modification make the tabe title is the same for all pages. I wish the title change from page to another.

Hi @Abd_El-Nasser_Gharee,

You’ll need some PHP and/or Smarty expertise in order to do this – I can’t guide you through modifications in detail, but if you get stuck on something specific, I may be able to provide limited guidance.

Regards,
Alec Smecher
Public Knowledge Project Team