Add product name to <title> for each generated doc page

Topics: Developer Forum
Apr 13, 2010 at 11:15 PM
Edited Apr 13, 2010 at 11:17 PM

Hi Eric,

Thanks for releasing and maintaining SHFB; it has been used to build the documentation for the AWS SDK for .NET in conjunction with the Hana stylesheet.

I was wondering how I could add the product's name (AWS SDK for .NET) to the title of every page generated as part of the product's documentation. For example, this page: http://docs.amazonwebservices.com/sdkfornet/latest/apidocs/html/M_Amazon_S3_AmazonS3_ListObjects.htm, has the title, "ListObjects method"; I want the title to be, "ListObjects method - (AWS SDK for .NET)".

The product's name is "AWS SDK for .NET Documentation"; I am also fine with this being appended to the current title instead of the shorter "AWS SDK for .NET".

Thanks!
Manoj

Coordinator
Apr 14, 2010 at 2:11 AM

To get the title to appear, you've have to modify the Sandcastle XSL transformation files.  You'd need to track down where it generates the title section and add a bit that also writes out an '<include item="productTitle" />' element to get it to pull the title value in from the shared content resource file.

Eric

 

Apr 14, 2010 at 7:13 PM

Hey Eric,

Thanks for the quick response. I tried to edit a few xsl files that contained the tags titleDecorated, titlePlain, etc to no avail. I'll keep trying to get this done. Too bad Sandcastle documentation is so threadbare. 

Manoj