Relative linking for header logo in individual pages of classic webhelp not working

prateek_satpathy
Posts: 1

Relative linking for header logo in individual pages of classic webhelp not working

Wed Oct 10, 2018 9:21 am

Hi,
I am trying to generate classic webhelp output with a header logo for all pages.I have used a custom CSS where the logo is mentioned and the path for the logo is the root folder.

h1.before{
content : url("./logo.png");
}

But the issue is for the immediate concepts and task folder it is able to fetch and display the logo,not for the sub folders. So relative linking is not working. Please help

Thanks
ionela
Posts: 243

Re: Relative linking for header logo in individual pages of classic webhelp not working

Thu Oct 11, 2018 4:20 pm

Hello,

I've tested and you could achieve this using a custom CSS file with the following CSS code:

Code: Select all

h1:before{
   content: url('logo.png');
}

More information about how to use a custom CSS can be found in our user manual: Referencing the Custom CSS
Taking into account that the image URL should be relative to the custom CSS file, and the CSS file will be copied to the root directory of the generated output you also need to use the webhelp.custom.resources parameter to point to a directory that contains only your logo.png file. This way, the png file (and all the resources located in that directory) will be copied to the root directory of the published output. Given this it is recommended to create a directory that contains only the logo file.
You can find here more details about webhelp.custom.resources parameter: Copying Additional Resources to Output Directory

Regards,
Ionela
Ionela Istodor
oXygen XML Editor and Author Support

Return to “DITA (Editing and Publishing DITA Content)”

Who is online

Users browsing this forum: No registered users and 2 guests