Dynamic Page Titles in Service Portal not working in New York after upgrade from Kingston

agamjitbawa
Kilo Explorer

Hello NOW Community!

Since our instance upgraded from Kingston to NewYork version, the Dynamic Page Titles set for a Service Portal page is not working anymore.

In Earlier version(Kingston) it was displaying the browser page title as the Category of the knowledge article that was viewed by the user.

The line of code written is as follows: %kb_name

%kb_name is the name of the Dynamic Title Page variable defined for the page which references the Category field of the Knowledge Article.

 

Appreciate the help! 

Regards,
Agamjit

 

 

3 REPLIES 3

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

Can you share the screenshot or any script for this?

Regards

Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Marek Stepien
Tera Expert

Hi,

We run into the same problem. The setting "Dynamic page title" at the kb_article_view is not respected, to the contrary what the ServiceNow documentation says.  The issue is in both New York and Orlando release.

Looking into the code of the "Knowledge Article Content" widget, the title is hardcoded in 'Server Script' at line 466:

    title = knowledgeRecord.kb_knowledge_base.getDisplayValue() + " - " + data.shortDesc; // kb name - kb short_desc

However, if you go to "Client Script" and comment out line 116:

   // setting default page title for supporting km seo
  $window.document.title = c.data.page_title;

then you remove the hardcoding, and the title is set by "Dynamic page title" at the kb_article_view page instead.


The note says:
   // setting default page title for supporting km seo
In other words, ServiceNow thinks that hardcoding will make SEO better. Rather the contrary.


This is a bug or confusion on the part of SN developers.

 

Sumedh Kharode1
Kilo Expert

Hi,

please check that Dynamic page title variables "%kb_name" is pointing to the same page , you can go to "sp_page_title_variable" this table to check that.

Also please check below link this might help you

https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0748307

 

Regards

Sumedh Kharode

+919834925664