Custom footer
Post here questions and problems related to editing and publishing DITA content.
-
- Posts: 2
- Joined: Fri Mar 28, 2025 9:57 am
Custom footer
Post by natalia_carrilo »
Hi!
I have created an .xhtml footer file to be added to webhelp.fragment.footer. I would like the publication number and review to be displayed in the footer. Is there any way to extract the information from the publication map? I tried adding topicmeta and adding a new parameter in the transformation scenario, but it didn't work.
Thank you!
Natalia
I have created an .xhtml footer file to be added to webhelp.fragment.footer. I would like the publication number and review to be displayed in the footer. Is there any way to extract the information from the publication map? I tried adding topicmeta and adding a new parameter in the transformation scenario, but it didn't work.
Thank you!
Natalia
-
- Posts: 665
- Joined: Wed Oct 16, 2019 3:47 pm
Re: Custom footer
Post by julien_lacour »
Hello Natalia,
You can extract information from the publication map by using the map-xpath WebHelp Macro directly in the footer fragment, something like:
Regards,
Julien
You can extract information from the publication map by using the map-xpath WebHelp Macro directly in the footer fragment, something like:
Code: Select all
<whc:macro value="${map-xpath(/bookmap/bookmeta//reviewed/person)}" xmlns:whc="http://www.oxygenxml.com/webhelp/components"/>
Julien
-
- Posts: 2
- Joined: Fri Mar 28, 2025 9:57 am
Re: Custom footer
Post by natalia_carrilo »
Hi Julien, thanks for the reply.
Actually, I created the xhtml file because I want a footer structured in two lines. It should be something like this:
Thank you in advance!
Natalia
Actually, I created the xhtml file because I want a footer structured in two lines. It should be something like this:
Can I still use map-xpath? Also, since I'm working on a ditamap, should I use the topicmeta element?Publication X - Issue X - Date X
Copyright (with link to the page)
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" />
<title>Footer Template</title>
<style type="text/css">
/* Styling for the footer */
.wh_footer {
background-color: rgb(61, 61, 61);
padding: 4em 0em;
color: #ffffff;
text-align: center;
}</style>
</head>
<body>
<!-- Footer Section -->
<div class="wh_footer" id="custom-footer">
<div>
<!-- Display Publication Number -->
<p>Publication: X - Iss 0 - Date: 26-03-2025</p>
<p>© "Company name". All rights reserved. | <a
href="${path(oxygen-webhelp-output-dir)}/c_copyright.html">Copyright</a></p>
</div>
</div>
</body>
</html>
Natalia
-
- Posts: 665
- Joined: Wed Oct 16, 2019 3:47 pm
Re: Custom footer
Post by julien_lacour »
Hello Natalia,
Of course you can use map-xpath in a ditamap, you can have this for example:
Regards,
Julien
Of course you can use map-xpath in a ditamap, you can have this for example:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" />
<title>Footer Template</title>
<style type="text/css">
/* Styling for the footer */
.wh_footer {
background-color: rgb(61, 61, 61);
padding: 4em 0em;
color: #ffffff;
text-align: center;
}</style>
</head>
<body>
<!-- Footer Section -->
<div class="wh_footer" id="custom-footer">
<div>
<!-- Display Publication Number -->
<p>Publication: <whc:macro value="${map-xpath(/map/topicmeta/author)}" xmlns:whc="http://www.oxygenxml.com/webhelp/components"/>
- Iss 0
- Date: <whc:macro value="${map-xpath(/map/topicmeta/critdates/revised/@modified)}" xmlns:whc="http://www.oxygenxml.com/webhelp/components"/></p>
<p>© "Company name". All rights reserved. | <a href="${path(oxygen-webhelp-output-dir)}/c_copyright.html">Copyright</a></p>
</div>
</div>
</body>
</html>
Julien
Return to “DITA (Editing and Publishing DITA Content)”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service