Help to get the site collection name with C# in SP onprem

Highlighted
Regular Contributor

Hi

I got a question regarding site collection names. The company is running 2 systems, EpiServer and Sharepoint on prem. EPiServer is used to show information as a typicall webpage and it has a module that shows the title of the SharePoint site collections. I got the row that get the site collection names and it looks like this: 

Title= rootWeb.Title

This is working as long the administrator don't change the site collection name. If he does it Epi still show the original name since is getting it from rootWeb.Title. 

So my question is how can I get the site collection name (the one that the admin can update) and show it in EpiServer. Is there another property beside Title that I can use to get that title?

 

Best regards

Americo

1 Reply
Highlighted

This is an update:

 

I have created a lokal SharePoint isntallation and tested the name change in a site collection. 

The original name was My site and in the central administration I could see the same name in the Title property. 

Then I updated the name by going to Site settings -> Title and description and I changed it to My new site collection. Once again in the central administration the Title property updated to the new name without any problems.

I did the same test in the scarp SP on prem but the title property in the central administration didn't update.

 

What can be wrong in the scarp SP? is there any setting that should be changed? 

Best regards

Americo