Bug reports Found a bug? Post it here please.
Version 5.x > Bug reports > Title prefix no longer working after 5.5 upgrade View modes: 
User avatar
Member
Member
greg.herrell-bitwisesolutions - 5/20/2010 4:09:14 PM
   
Title prefix no longer working after 5.5 upgrade
After upgrading to 5.5 the page title's no long render with the page title prefix despite being properly configured as follows:

Page title format: {%pagetitle_orelse_name%} | {%prefix%}
Page title prefix: Anything in here.

An additional check of trying to do this manually by using this bit of code fails with an empty string...

string prefix = CMS.SettingsProvider.SettingsKeyProvider.GetStringValue(CMS.CMSHelper.CMSContext.CurrentSiteName + ".CMSPageTitlePrefix")

Any help would be appreciated.

Thanks!

User avatar
Kentico Developer
Kentico Developer
kentico_martind - 5/23/2010 1:28:14 PM
   
RE:Title prefix no longer working after 5.5 upgrade
Hello,

Regrettably, I was unable to reproduce this issue.

Could you please try to debug your code and check if CMS.CMSHelper.CMSContext.CurrentSiteName returns name of site you have set the prefix for? Could you please also check what value is stored in CMS_SettingsKey for record with 'KeyName' = 'CMSPageTitlePrefix' and 'SiteID' = 'ID of site you have set prefix for'?

Could you please also try to restart application to clear the cache and avoid some caching issue?

Best Regards,

Martin Dobsicek

User avatar
Member
Member
gph - 5/24/2010 2:27:19 PM
   
RE:Title prefix no longer working after 5.5 upgrade
Thanks,
There was a new entry in the CMS_SettingsKey table....

The original record which contained my prefix had the SiteID set to NULL. The second record which contained my SiteID had a KeyDefautValue of 'My Site' and a KeyValue of empty string.

I switched the SiteID values and everything works as expected. It's an easy fix, but I have no idea how it ended up in this state.




User avatar
Kentico Developer
Kentico Developer
kentico_martind - 5/25/2010 6:33:25 AM
   
RE:Title prefix no longer working after 5.5 upgrade
Hi Greg,

Well, the record with NULL in SiteID is global setting, while the record with some ID in SiteID is setting for particular site. Maybe you have set the value for global setting instead of site setting by mistake or forgot to inherit the setting (there should be NULL in KeyValue field for site setting that should inherit from global settings).

Best Regards,

Martin Dobsicek

User avatar
Member
Member
gph - 5/25/2010 7:50:50 AM
   
RE:Title prefix no longer working after 5.5 upgrade
Odd that it worked before I upgraded, but obviously not a bug. Thanks for your support!