Referencing the HTML fragment using a publishing template
- If you haven't already created a Publishing Template, see Working with publishing templates.
- Insert the HTML content in a well-formed XML file (for example, custom-html.html).
- Using the Project view, copy your custom HTML fragment in a folder inside publishing the template root folder (for example, in the custom_footer_template/html-fragments folder).
-
Open the template descriptor file associated with your publishing template and
add a reference to the custom HTML fragment in the html-fragments
section.
<publishing-template> ... <webhelp> ... <html-fragments> <fragment file="html-fragments/custom-html.html" placeholder="webhelp.fragment.head"/>
Note: If you want to insert the content in another location within the output document, you can reference the XML file from any other HTML fragment extension points. - Open the DITA Map WebHelp Responsive transformation scenario.
- Click the Choose Custom Publishing Template link and select your template.
- Click OK to save the changes to the transformation scenario.
- Run the transformation scenario.
head
element of your output document.