Page 1 of 1

Header element Customisation on page with specific topic id

Posted: Sat Aug 09, 2025 11:54 am
by sudhe
Hi Folks,
I have been trying to customise the header element with below xsl expression

Code: Select all

*[contains(@class, 'wh_header') and not(contains(@class, 'wh_header_flex_container'))]
which is modifying the header element on all the topic pages.


As topic id cascading to body id in html, i tried the xsl expression

Code: Select all

html[body[contains-token(@id, 'custumID')]][contains(@class, 'wh_header') and not(contains(@class, 'wh_header_flex_container'))]
but is not working.
Please suggest what went wrong here.

Thanks & Regards,
Sudhe

Re: Header element Customisation on page with specific topic id

Posted: Mon Aug 11, 2025 5:33 pm
by julien_lacour
Hello,

The default processing for wh_header is using mode="copy_template", if you add it, your template will be used:

Code: Select all

<xsl:template match="*[contains(@class, 'wh_header') and not(contains(@class, 'wh_header_flex_container'))]" mode="copy_template">
You can find an example in our GitHub page: https://github.com/oxygenxml/oxygen-pub ... -in-header

Could you indicate which version of Oxygen you are using and what you are trying to achieve?

Regards,
Julien